class DTK::Client::CLI::Context::Attributes
Public Class Methods
new(context)
click to toggle source
# File lib/cli/context/attributes.rb, line 21 def initialize(context) @context = context # special_keys computed on demand @special_keys = {} end
Public Instance Methods
[](key)
click to toggle source
Calls superclass method
# File lib/cli/context/attributes.rb, line 28 def [](key) # special processing on demand case key when :module_ref, :service_instance value_from_base_dsl_file(key) else super end end
Private Instance Methods
value_from_base_dsl_file(key)
click to toggle source
# File lib/cli/context/attributes.rb, line 40 def value_from_base_dsl_file(key) if @special_keys.has_key?(key) @special_keys[key] = @context.value_from_base_dsl_file?(key) @special_keys[key] else @special_keys[key] = @context.value_from_base_dsl_file?(key) end end