Class: Momo::MappingRow

Inherits:
MomoScope show all
Defined in:
lib/momo/mapping.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from MomoScope

#call, #lookup, #ref

Constructor Details

#initialize(&block) ⇒ MappingRow

Returns a new instance of MappingRow.



7
8
9
10
# File 'lib/momo/mapping.rb', line 7

def initialize(&block)
	@values = {}
	instance_eval(&block)
end

Instance Attribute Details

#valuesObject

Returns the value of attribute values.



5
6
7
# File 'lib/momo/mapping.rb', line 5

def values
  @values
end

Instance Method Details

#item(name, value) ⇒ Object



12
13
14
# File 'lib/momo/mapping.rb', line 12

def item(name, value)
	@values[name] = value
end