Sha256: f78ae97ec4e9e54534a8171e04fc4f20659b8516bbad5c40df756ca770bffd72

Contents?: true

Size: 512 Bytes

Versions: 3

Compression:

Stored size: 512 Bytes

Contents

# frozen_string_literal: true

module OoxmlParser
  # Class for parsing `w:bookmarkEnd` tags
  class BookmarkEnd < OOXMLDocumentObject
    # @return [Integer] id of bookmark
    attr_reader :id

    # Parse BookmarkStart object
    # @param node [Nokogiri::XML:Element] node to parse
    # @return [BookmarkEnd] result of parsing
    def parse(node)
      node.attributes.each do |key, value|
        case key
        when 'id'
          @id = value.value.to_i
        end
      end
      self
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ooxml_parser-0.6.0 lib/ooxml_parser/docx_parser/docx_data/document_structure/docx_paragraph/bookmark_end.rb
ooxml_parser-0.5.1 lib/ooxml_parser/docx_parser/docx_data/document_structure/docx_paragraph/bookmark_end.rb
ooxml_parser-0.5.0 lib/ooxml_parser/docx_parser/docx_data/document_structure/docx_paragraph/bookmark_end.rb