Class: OoxmlParser::FootnoteProperties
- Inherits:
-
OOXMLDocumentObject
- Object
- OOXMLDocumentObject
- OoxmlParser::FootnoteProperties
- Defined in:
- lib/ooxml_parser/docx_parser/docx_data/document_structure/page_properties/footnote_properties.rb
Overview
Class for parsing footnotePr tags
Instance Attribute Summary collapse
-
#numbering_format ⇒ NumberingFormat
Format of numbering.
-
#numbering_restart ⇒ ValuedChild
Type of numbering restart.
-
#numbering_start ⇒ ValuedChild
Value of numbering start.
-
#position ⇒ ValuedChild
Position of footnote.
Attributes inherited from OOXMLDocumentObject
Instance Method Summary collapse
-
#parse(node) ⇒ FootnoteProperties
Parse FootnoteProperties.
Methods inherited from OOXMLDocumentObject
#==, add_to_xmls_stack, copy_file_and_rename_to_zip, current_xml, dir, encrypted_file?, get_link_from_rels, #initialize, unzip_file, #with_data?
Methods included from OoxmlDocumentObjectHelper
Constructor Details
This class inherits a constructor from OoxmlParser::OOXMLDocumentObject
Instance Attribute Details
#numbering_format ⇒ NumberingFormat
Returns format of numbering.
5 6 7 |
# File 'lib/ooxml_parser/docx_parser/docx_data/document_structure/page_properties/footnote_properties.rb', line 5 def numbering_format @numbering_format end |
#numbering_restart ⇒ ValuedChild
Returns type of numbering restart.
7 8 9 |
# File 'lib/ooxml_parser/docx_parser/docx_data/document_structure/page_properties/footnote_properties.rb', line 7 def numbering_restart @numbering_restart end |
#numbering_start ⇒ ValuedChild
Returns value of numbering start.
9 10 11 |
# File 'lib/ooxml_parser/docx_parser/docx_data/document_structure/page_properties/footnote_properties.rb', line 9 def numbering_start @numbering_start end |
#position ⇒ ValuedChild
Returns position of footnote.
11 12 13 |
# File 'lib/ooxml_parser/docx_parser/docx_data/document_structure/page_properties/footnote_properties.rb', line 11 def position @position end |
Instance Method Details
#parse(node) ⇒ FootnoteProperties
Parse FootnoteProperties
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/ooxml_parser/docx_parser/docx_data/document_structure/page_properties/footnote_properties.rb', line 16 def parse(node) node.xpath('*').each do |node_child| case node_child.name when 'numFmt' @numbering_format = ValuedChild.new(:symbol, parent: self).parse(node_child) when 'numRestart' @numbering_restart = ValuedChild.new(:symbol, parent: self).parse(node_child) when 'numStart' @numbering_start = ValuedChild.new(:integer, parent: self).parse(node_child) when 'pos' @position = ValuedChild.new(:symbol, parent: self).parse(node_child) end end self end |