Class: SmartCore::Container::Commands::Namespace Private
- Defined in:
- lib/smart_core/container/commands/namespace.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Instance Attribute Summary collapse
- #namespace_name ⇒ String, Symbol readonly private
Instance Method Summary collapse
- #call(registry) ⇒ void private
- #dup ⇒ SmartCore::Container::Commands::Namespace private
- #initialize(namespace_name, dependency_definitions) ⇒ void constructor private
Constructor Details
#initialize(namespace_name, dependency_definitions) ⇒ void
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
21 22 23 24 25 26 |
# File 'lib/smart_core/container/commands/namespace.rb', line 21 def initialize(namespace_name, dependency_definitions) SmartCore::Container::KeyGuard.indifferently_accessable_key(namespace_name).tap do |name| @namespace_name = name @dependency_definitions = dependency_definitions end end |
Instance Attribute Details
#namespace_name ⇒ String, Symbol (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11 12 13 |
# File 'lib/smart_core/container/commands/namespace.rb', line 11 def namespace_name @namespace_name end |
Instance Method Details
#call(registry) ⇒ void
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
This method returns an undefined value.
33 34 35 |
# File 'lib/smart_core/container/commands/namespace.rb', line 33 def call(registry) registry.namespace(namespace_name, &dependency_definitions) end |
#dup ⇒ SmartCore::Container::Commands::Namespace
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
41 42 43 |
# File 'lib/smart_core/container/commands/namespace.rb', line 41 def dup self.class.new(namespace_name, dependency_definitions) end |