Class: Ziya::Maps::Support::Range
- Inherits:
-
Base
show all
- Defined in:
- lib/ziya/maps/support/range.rb
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Base
#to_comp_yaml
#dial, #dials, #gauge
#clazz, #indent
#==, attributes, #attributes_for, #configured?, has_attribute, #has_sub_components, #initialize, #merge, #options, #options_as_string
Class Method Details
.define_mappings(mappings) ⇒ Object
6
7
8
|
# File 'lib/ziya/maps/support/range.rb', line 6
def define_mappings( mappings )
@mappings = mappings
end
|
.mappings ⇒ Object
10
11
12
|
# File 'lib/ziya/maps/support/range.rb', line 10
def mappings
@mappings
end
|
Instance Method Details
#flatten(xml) ⇒ Object
18
19
20
21
22
|
# File 'lib/ziya/maps/support/range.rb', line 18
def flatten( xml )
xml.state( :id => to_component_id ) do
options.keys.sort { |a,b| a.to_s <=> b.to_s }.each { |k| self.class.module_eval "xml.#{find_key_for_attr(k)}( '#{options[k]}' )" }
end
end
|