Class: MarkdownExpander::Expander::Node

Inherits:
Object
  • Object
show all
Defined in:
lib/markdown-expander.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(parent, value) ⇒ Node

Returns a new instance of Node.



68
69
70
71
72
# File 'lib/markdown-expander.rb', line 68

def initialize parent, value
  @parent = parent
  @value = value
  @children = []
end

Instance Attribute Details

#childrenObject

Returns the value of attribute children.



66
67
68
# File 'lib/markdown-expander.rb', line 66

def children
  @children
end

#parentObject

Returns the value of attribute parent.



65
66
67
# File 'lib/markdown-expander.rb', line 65

def parent
  @parent
end

#valueObject

Returns the value of attribute value.



67
68
69
# File 'lib/markdown-expander.rb', line 67

def value
  @value
end