Class: OoxmlParser::XlsxDrawing
- Inherits:
-
OOXMLDocumentObject
- Object
- OOXMLDocumentObject
- OoxmlParser::XlsxDrawing
- Defined in:
- lib/ooxml_parser/xlsx_parser/workbook/worksheet/xlsx_drawing.rb
Overview
Data of spreadsheet drawing
Instance Attribute Summary collapse
-
#client_data ⇒ ClientData
Client data.
-
#from ⇒ XlsxDrawingPositionParameters
Position from.
-
#graphic_frame ⇒ GraphicFrame
Graphic frame.
-
#grouping ⇒ Object
Returns the value of attribute grouping.
-
#picture ⇒ Object
Returns the value of attribute picture.
-
#shape ⇒ Object
Returns the value of attribute shape.
-
#to ⇒ XlsxDrawingPositionParameters
Position to.
Attributes inherited from OOXMLDocumentObject
Instance Method Summary collapse
-
#parse(node) ⇒ XlsxDrawing
Parse XlsxDrawing object.
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
#client_data ⇒ ClientData
Returns client data.
16 17 18 |
# File 'lib/ooxml_parser/xlsx_parser/workbook/worksheet/xlsx_drawing.rb', line 16 def client_data @client_data end |
#from ⇒ XlsxDrawingPositionParameters
Returns position from.
10 11 12 |
# File 'lib/ooxml_parser/xlsx_parser/workbook/worksheet/xlsx_drawing.rb', line 10 def from @from end |
#graphic_frame ⇒ GraphicFrame
Returns graphic frame.
14 15 16 |
# File 'lib/ooxml_parser/xlsx_parser/workbook/worksheet/xlsx_drawing.rb', line 14 def graphic_frame @graphic_frame end |
#grouping ⇒ Object
Returns the value of attribute grouping.
8 9 10 |
# File 'lib/ooxml_parser/xlsx_parser/workbook/worksheet/xlsx_drawing.rb', line 8 def grouping @grouping end |
#picture ⇒ Object
Returns the value of attribute picture.
8 9 10 |
# File 'lib/ooxml_parser/xlsx_parser/workbook/worksheet/xlsx_drawing.rb', line 8 def picture @picture end |
#shape ⇒ Object
Returns the value of attribute shape.
8 9 10 |
# File 'lib/ooxml_parser/xlsx_parser/workbook/worksheet/xlsx_drawing.rb', line 8 def shape @shape end |
#to ⇒ XlsxDrawingPositionParameters
Returns position to.
12 13 14 |
# File 'lib/ooxml_parser/xlsx_parser/workbook/worksheet/xlsx_drawing.rb', line 12 def to @to end |
Instance Method Details
#parse(node) ⇒ XlsxDrawing
Parse XlsxDrawing object
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/ooxml_parser/xlsx_parser/workbook/worksheet/xlsx_drawing.rb', line 21 def parse(node) node.xpath('*').each do |child_node| case child_node.name when 'from' @from = XlsxDrawingPositionParameters.new(parent: self).parse(child_node) when 'to' @to = XlsxDrawingPositionParameters.new(parent: self).parse(child_node) when 'sp' @shape = DocxShape.new(parent: self).parse(child_node) when 'grpSp' @grouping = ShapesGrouping.new(parent: self).parse(child_node) when 'pic' @picture = DocxPicture.new(parent: self).parse(child_node) when 'graphicFrame' @graphic_frame = GraphicFrame.new(parent: self).parse(child_node) when 'cxnSp' @shape = ConnectionShape.new(parent: self).parse(child_node) when 'clientData' @client_data = ClientData.new(parent: self).parse(child_node) end end self end |