Class: OpenEHR::Parser::ArchetypeNode
- Inherits:
-
Object
- Object
- OpenEHR::Parser::ArchetypeNode
- Defined in:
- lib/openehr/parser/adl_helper.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
Returns the value of attribute id.
-
#parent ⇒ Object
readonly
Returns the value of attribute parent.
-
#path ⇒ Object
Returns the value of attribute path.
Instance Method Summary collapse
-
#initialize(parent = nil) ⇒ ArchetypeNode
constructor
A new instance of ArchetypeNode.
- #root? ⇒ Boolean
Constructor Details
#initialize(parent = nil) ⇒ ArchetypeNode
Returns a new instance of ArchetypeNode.
62 63 64 65 |
# File 'lib/openehr/parser/adl_helper.rb', line 62 def initialize(parent = nil) @parent = parent @path = '/' if parent.nil? end |
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id.
60 61 62 |
# File 'lib/openehr/parser/adl_helper.rb', line 60 def id @id end |
#parent ⇒ Object (readonly)
Returns the value of attribute parent.
59 60 61 |
# File 'lib/openehr/parser/adl_helper.rb', line 59 def parent @parent end |
#path ⇒ Object
Returns the value of attribute path.
60 61 62 |
# File 'lib/openehr/parser/adl_helper.rb', line 60 def path @path end |
Instance Method Details
#root? ⇒ Boolean
67 68 69 |
# File 'lib/openehr/parser/adl_helper.rb', line 67 def root? return parent.nil? end |