Class: RODF::DataStyle
Constant Summary
Constants inherited from Container
Instance Method Summary collapse
-
#initialize(name, type) ⇒ DataStyle
constructor
A new instance of DataStyle.
- #method_missing(name, *args) ⇒ Object
- #xml ⇒ Object
Methods inherited from Container
contains, create, module_for_stuff
Constructor Details
#initialize(name, type) ⇒ DataStyle
Returns a new instance of DataStyle.
12 13 14 15 16 |
# File 'lib/rodf/data_style.rb', line 12 def initialize(name, type) super @type, @name = type, name end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args) ⇒ Object
24 25 26 |
# File 'lib/rodf/data_style.rb', line 24 def method_missing(name, *args) section(name, *args) end |
Instance Method Details
#xml ⇒ Object
18 19 20 21 22 |
# File 'lib/rodf/data_style.rb', line 18 def xml Builder::XmlMarkup.new.tag! "number:#{@type}-style", 'style:name' => @name do |xml| xml << style_sections_xml end end |