Module: SmartCore::Container::Mixin::ClassMethods Private
- Defined in:
- lib/smart_core/container/mixin.rb
Overview
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Instance Method Summary collapse
Instance Method Details
#container ⇒ SmartCore::Container
72 73 74 75 76 |
# File 'lib/smart_core/container/mixin.rb', line 72 def container @__smart_core_container_access_lock__.read_sync do @__smart_core_container__ ||= @__smart_core_container_klass__.new end end |
#dependencies(freeze_state: false, &block) ⇒ void
This method returns an undefined value.
60 61 62 63 64 65 |
# File 'lib/smart_core/container/mixin.rb', line 60 def dependencies(freeze_state: false, &block) @__smart_core_container_access_lock__.write_sync do @__smart_core_container_klass__.instance_eval(&block) if block_given? @__smart_core_container_klass__.instance_eval { freeze_state! } if freeze_state end end |