class OoxmlParser::SDTProperties
Class for parsing ‘w:sdtPr` tags
Attributes
alias[R]
@return [ValuedChild] alias value
checkbox[R]
@return [CheckBox] checkbox
combobox[R]
@return [ComboBox] combobox
dropdown_list[R]
@return [DropdownList] dropdown list
form_properties[R]
@return [FormProperties] form properties
form_text_properties[R]
@return [FormTextProperties] properties of text in form
lock[R]
@return [ValuedChild] Locking Setting
tag[R]
@return [ValuedChild] tag value
Public Instance Methods
parse(node)
click to toggle source
Parse SDTProperties
object @param node [Nokogiri::XML:Element] node to parse @return [SDTProperties] result of parsing
# File lib/ooxml_parser/docx_parser/document_structure/docx_paragraph/sdt/sdt_properties.rb, line 31 def parse(node) node.xpath('*').each do |node_child| case node_child.name when 'alias' @alias = ValuedChild.new(:string, parent: self).parse(node_child) when 'tag' @tag = ValuedChild.new(:string, parent: self).parse(node_child) when 'lock' @lock = ValuedChild.new(:symbol, parent: self).parse(node_child) when 'comboBox' @combobox = ComboBox.new(parent: self).parse(node_child) when 'dropDownList' @dropdown_list = DropdownList.new(parent: self).parse(node_child) when 'checkbox' @checkbox = CheckBox.new(parent: self).parse(node_child) when 'formPr' @form_properties = FormProperties.new(parent: self).parse(node_child) when 'textFormPr' @form_text_properties = FormTextProperties.new(parent: self).parse(node_child) end end self end