Class: Kreuzberg::Result::DocumentNode
- Inherits:
-
Object
- Object
- Kreuzberg::Result::DocumentNode
- Defined in:
- lib/kreuzberg/document_structure.rb
Overview
Single node in the document structure tree.
Represents a logical unit of content with deterministic ID, content, tree structure information, and metadata.
Instance Attribute Summary collapse
-
#annotations ⇒ Object
readonly
Returns the value of attribute annotations.
-
#bbox ⇒ Object
readonly
Returns the value of attribute bbox.
-
#children ⇒ Object
readonly
Returns the value of attribute children.
-
#content ⇒ Object
readonly
Returns the value of attribute content.
-
#content_layer ⇒ Object
readonly
Returns the value of attribute content_layer.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#page ⇒ Object
readonly
Returns the value of attribute page.
-
#page_end ⇒ Object
readonly
Returns the value of attribute page_end.
-
#parent ⇒ Object
readonly
Returns the value of attribute parent.
Instance Method Summary collapse
-
#initialize(hash) ⇒ DocumentNode
constructor
A new instance of DocumentNode.
Constructor Details
#initialize(hash) ⇒ DocumentNode
Returns a new instance of DocumentNode.
49 50 51 52 53 |
# File 'lib/kreuzberg/document_structure.rb', line 49 def initialize(hash) assign_core_fields(hash) assign_tree_fields(hash) (hash) end |
Instance Attribute Details
#annotations ⇒ Object (readonly)
Returns the value of attribute annotations.
47 48 49 |
# File 'lib/kreuzberg/document_structure.rb', line 47 def annotations @annotations end |
#bbox ⇒ Object (readonly)
Returns the value of attribute bbox.
47 48 49 |
# File 'lib/kreuzberg/document_structure.rb', line 47 def bbox @bbox end |
#children ⇒ Object (readonly)
Returns the value of attribute children.
47 48 49 |
# File 'lib/kreuzberg/document_structure.rb', line 47 def children @children end |
#content ⇒ Object (readonly)
Returns the value of attribute content.
47 48 49 |
# File 'lib/kreuzberg/document_structure.rb', line 47 def content @content end |
#content_layer ⇒ Object (readonly)
Returns the value of attribute content_layer.
47 48 49 |
# File 'lib/kreuzberg/document_structure.rb', line 47 def content_layer @content_layer end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
47 48 49 |
# File 'lib/kreuzberg/document_structure.rb', line 47 def id @id end |
#page ⇒ Object (readonly)
Returns the value of attribute page.
47 48 49 |
# File 'lib/kreuzberg/document_structure.rb', line 47 def page @page end |
#page_end ⇒ Object (readonly)
Returns the value of attribute page_end.
47 48 49 |
# File 'lib/kreuzberg/document_structure.rb', line 47 def page_end @page_end end |
#parent ⇒ Object (readonly)
Returns the value of attribute parent.
47 48 49 |
# File 'lib/kreuzberg/document_structure.rb', line 47 def parent @parent end |