Class: OoxmlParser::ChartStyleEntry
- Inherits:
-
OOXMLDocumentObject
- Object
- OOXMLDocumentObject
- OoxmlParser::ChartStyleEntry
- Defined in:
- lib/ooxml_parser/common_parser/common_data/alternate_content/chart/chart/chart_style_file/chart_style_entry.rb
Overview
Class for parsing Chart Style entry
Instance Attribute Summary collapse
-
#body_properties ⇒ OOXMLShapeBodyProperties
readonly
Body properties.
-
#default_run_properties ⇒ RunProperties
readonly
Default run properties.
-
#effect_reference ⇒ FillReference
readonly
Effect reference.
-
#fill_reference ⇒ FillReference
readonly
Fill reference.
-
#font_reference ⇒ FontReference
readonly
Font reference.
-
#line_style_reference ⇒ StyleMatrixReference
readonly
Line style reference.
-
#shape_properties ⇒ StyleMatrixReference
readonly
Shape properties.
Attributes inherited from OOXMLDocumentObject
Instance Method Summary collapse
-
#parse(node) ⇒ ChartStyleEntry
Parse Chart style entry.
Methods inherited from OOXMLDocumentObject
#==, #boolean_attribute_value, #initialize, #parse_xml, #with_data?
Methods included from OoxmlObjectAttributeHelper
#attribute_enabled?, #option_enabled?
Methods included from OoxmlDocumentObjectHelper
Constructor Details
This class inherits a constructor from OoxmlParser::OOXMLDocumentObject
Instance Attribute Details
#body_properties ⇒ OOXMLShapeBodyProperties (readonly)
Returns body properties.
7 8 9 |
# File 'lib/ooxml_parser/common_parser/common_data/alternate_content/chart/chart/chart_style_file/chart_style_entry.rb', line 7 def body_properties @body_properties end |
#default_run_properties ⇒ RunProperties (readonly)
Returns default run properties.
9 10 11 |
# File 'lib/ooxml_parser/common_parser/common_data/alternate_content/chart/chart/chart_style_file/chart_style_entry.rb', line 9 def default_run_properties @default_run_properties end |
#effect_reference ⇒ FillReference (readonly)
Returns effect reference.
11 12 13 |
# File 'lib/ooxml_parser/common_parser/common_data/alternate_content/chart/chart/chart_style_file/chart_style_entry.rb', line 11 def effect_reference @effect_reference end |
#fill_reference ⇒ FillReference (readonly)
Returns fill reference.
13 14 15 |
# File 'lib/ooxml_parser/common_parser/common_data/alternate_content/chart/chart/chart_style_file/chart_style_entry.rb', line 13 def fill_reference @fill_reference end |
#font_reference ⇒ FontReference (readonly)
Returns font reference.
15 16 17 |
# File 'lib/ooxml_parser/common_parser/common_data/alternate_content/chart/chart/chart_style_file/chart_style_entry.rb', line 15 def font_reference @font_reference end |
#line_style_reference ⇒ StyleMatrixReference (readonly)
Returns line style reference.
17 18 19 |
# File 'lib/ooxml_parser/common_parser/common_data/alternate_content/chart/chart/chart_style_file/chart_style_entry.rb', line 17 def line_style_reference @line_style_reference end |
#shape_properties ⇒ StyleMatrixReference (readonly)
Returns shape properties.
19 20 21 |
# File 'lib/ooxml_parser/common_parser/common_data/alternate_content/chart/chart/chart_style_file/chart_style_entry.rb', line 19 def shape_properties @shape_properties end |
Instance Method Details
#parse(node) ⇒ ChartStyleEntry
Parse Chart style entry
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
# File 'lib/ooxml_parser/common_parser/common_data/alternate_content/chart/chart/chart_style_file/chart_style_entry.rb', line 24 def parse(node) node.xpath('*').each do |node_child| case node_child.name when 'bodyPr' @body_properties = OOXMLShapeBodyProperties.new(parent: self).parse(node_child) when 'defRPr' @default_run_properties = RunProperties.new(parent: self).parse(node_child) when 'effectRef' @effect_reference = StyleMatrixReference.new(parent: self).parse(node_child) when 'fillRef' @fill_reference = StyleMatrixReference.new(parent: self).parse(node_child) when 'fontRef' @font_reference = FontReference.new(parent: self).parse(node_child) when 'lnRef' @line_style_reference = StyleMatrixReference.new(parent: self).parse(node_child) when 'spPr' @shape_properties = DocxShapeProperties.new(parent: self).parse(node_child) end end self end |