class OoxmlParser::CommonTiming
Class for data of CommonTiming
Attributes
Public Class Methods
Source
# File lib/ooxml_parser/pptx_parser/presentation/slide/slide/timing/time_node_list/time_node/common_timing.rb, line 9 def initialize(parent: nil) @children = [] @start_conditions = [] @end_conditions = [] super end
Calls superclass method
OoxmlParser::OOXMLDocumentObject::new
Public Instance Methods
Source
# File lib/ooxml_parser/pptx_parser/presentation/slide/slide/timing/time_node_list/time_node/common_timing.rb, line 19 def parse(node) node.attributes.each do |key, value| case key when 'dur' @duration = value.value when 'restart' @restart = value.value when 'id' @id = value.value end end node.xpath('*').each do |node_child| case node_child.name when 'stCondLst' @start_conditions = ConditionList.new(parent: self).parse(node_child) when 'endCondLst' @end_conditions = ConditionList.new(parent: self).parse(node_child) when 'childTnLst' @children = TimeNodeList.new(parent: self).parse(node_child).elements end end self end
Parse CommonTiming
object @param node [Nokogiri::XML:Element] node to parse @return [CommonTiming] result of parsing