class OoxmlParser::BookmarkStart

Class for parsing ‘w:bookmarkStart` tags

Attributes

id[R]

@return [Integer] id of bookmark

name[R]

@return [String] name of bookmark

Public Instance Methods

parse(node) click to toggle source

Parse BookmarkStart object @param node [Nokogiri::XML:Element] node to parse @return [BookmarkStart] result of parsing

# File lib/ooxml_parser/docx_parser/document_structure/docx_paragraph/bookmark_start.rb, line 14
def parse(node)
  node.attributes.each do |key, value|
    case key
    when 'id'
      @id = value.value.to_i
    when 'name'
      @name = value.value
    end
  end
  self
end