Class: OOXML::Excel::Styles::NumFmt
- Inherits:
-
Object
- Object
- OOXML::Excel::Styles::NumFmt
- Defined in:
- lib/ooxml_excel/styles.rb
Instance Attribute Summary collapse
-
#code ⇒ Object
Returns the value of attribute code.
-
#id ⇒ Object
Returns the value of attribute id.
Class Method Summary collapse
Instance Attribute Details
#code ⇒ Object
Returns the value of attribute code.
81 82 83 |
# File 'lib/ooxml_excel/styles.rb', line 81 def code @code end |
#id ⇒ Object
Returns the value of attribute id.
81 82 83 |
# File 'lib/ooxml_excel/styles.rb', line 81 def id @id end |
Class Method Details
.load_from_node(num_fmt_node) ⇒ Object
82 83 84 85 86 87 |
# File 'lib/ooxml_excel/styles.rb', line 82 def self.load_from_node(num_fmt_node) new_format = self.new.tap do |number_format| number_format.id = num_fmt_node.attributes["numFmtId"].try(:value) number_format.code = num_fmt_node.attributes["formatCode"].try(:value) end end |