Class: Tamashii::Config::Attribute::Reference
- Inherits:
-
Object
- Object
- Tamashii::Config::Attribute::Reference
- Defined in:
- lib/tamashii/config/attribute.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#initialize(target, attribute) ⇒ Reference
constructor
A new instance of Reference.
- #sync(value) ⇒ Object
- #value ⇒ Object
Constructor Details
#initialize(target, attribute) ⇒ Reference
Returns a new instance of Reference.
21 22 23 24 |
# File 'lib/tamashii/config/attribute.rb', line 21 def initialize(target, attribute) @target = target @attribute = attribute end |
Instance Method Details
#sync(value) ⇒ Object
30 31 32 |
# File 'lib/tamashii/config/attribute.rb', line 30 def sync(value) @target[@attribute] = value end |
#value ⇒ Object
26 27 28 |
# File 'lib/tamashii/config/attribute.rb', line 26 def value @target[@attribute] end |