Module: Boson::Library::Namespacer
- Included in:
- Boson::Library
- Defined in:
- lib/boson/namespacer.rb
Overview
- :namespace
-
Boolean or string which namespaces a library. When true, the library is automatically namespaced to the library’s name. When a string, the library is namespaced to the string. Default is nil.
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#namespace_object ⇒ Object
The object a library uses for executing its commands.
Instance Attribute Details
#namespace(orig = @namespace) ⇒ Object
66 67 68 69 70 71 72 73 74 |
# File 'lib/boson/namespacer.rb', line 66 def namespace(orig=@namespace) @namespace = [String,FalseClass].include?(orig.class) ? orig : begin if (@namespace == true || (Boson.config[:auto_namespace] && !@index)) @namespace = clean_name else @namespace = false end end end |