Class: Docxi::ContentTypes::Default
- Inherits:
-
Object
- Object
- Docxi::ContentTypes::Default
- Defined in:
- lib/docxi/content_types/default.rb
Instance Attribute Summary collapse
-
#content_type ⇒ Object
Returns the value of attribute content_type.
-
#extension ⇒ Object
Returns the value of attribute extension.
Instance Method Summary collapse
- #build(xml) ⇒ Object
-
#initialize(extension, content_type) ⇒ Default
constructor
A new instance of Default.
Constructor Details
#initialize(extension, content_type) ⇒ Default
Returns a new instance of Default.
7 8 9 10 |
# File 'lib/docxi/content_types/default.rb', line 7 def initialize(extension, content_type) @extension = extension @content_type = content_type end |
Instance Attribute Details
#content_type ⇒ Object
Returns the value of attribute content_type.
5 6 7 |
# File 'lib/docxi/content_types/default.rb', line 5 def content_type @content_type end |
#extension ⇒ Object
Returns the value of attribute extension.
5 6 7 |
# File 'lib/docxi/content_types/default.rb', line 5 def extension @extension end |
Instance Method Details
#build(xml) ⇒ Object
12 13 14 |
# File 'lib/docxi/content_types/default.rb', line 12 def build(xml) xml.Default('Extension' => @extension, 'ContentType' => @content_type) end |