Class: Tins::DynamicScope::Context

Inherits:
Hash show all
Defined in:
lib/tins/dslkit.rb

Overview

A specialized Hash subclass for dynamic scope contexts.

This class automatically converts string keys to symbols for more convenient variable access.

Instance Method Summary collapse

Methods inherited from Hash

#subhash!

Methods included from Subhash

#subhash

Instance Method Details

#[](name) ⇒ Object

Retrieves a value by symbolized key.



1078
1079
1080
# File 'lib/tins/dslkit.rb', line 1078

def [](name)
  super name.to_sym
end

#[]=(name, value) ⇒ Object

Sets a value with a symbolized key.



1083
1084
1085
# File 'lib/tins/dslkit.rb', line 1083

def []=(name, value)
  super name.to_sym, value
end