Class: ReVIEW::DlistElementNode
- Defined in:
- lib/review/node.rb,
lib/review/compiler.rb
Instance Attribute Summary collapse
-
#compiler ⇒ Object
readonly
Returns the value of attribute compiler.
-
#content ⇒ Object
readonly
Returns the value of attribute content.
-
#position ⇒ Object
readonly
Returns the value of attribute position.
-
#text ⇒ Object
readonly
Returns the value of attribute text.
Instance Method Summary collapse
-
#initialize(compiler, position, text, content) ⇒ DlistElementNode
constructor
A new instance of DlistElementNode.
- #to_doc ⇒ Object
Methods inherited from Node
#inspect, #to_json, #to_raw, #to_s_by
Constructor Details
#initialize(compiler, position, text, content) ⇒ DlistElementNode
Returns a new instance of DlistElementNode.
975 976 977 978 979 980 |
# File 'lib/review/compiler.rb', line 975 def initialize(compiler, position, text, content) @compiler = compiler @position = position @text = text @content = content end |
Instance Attribute Details
#compiler ⇒ Object (readonly)
Returns the value of attribute compiler.
981 982 983 |
# File 'lib/review/compiler.rb', line 981 def compiler @compiler end |
#content ⇒ Object (readonly)
Returns the value of attribute content.
984 985 986 |
# File 'lib/review/compiler.rb', line 984 def content @content end |
#position ⇒ Object (readonly)
Returns the value of attribute position.
982 983 984 |
# File 'lib/review/compiler.rb', line 982 def position @position end |
#text ⇒ Object (readonly)
Returns the value of attribute text.
983 984 985 |
# File 'lib/review/compiler.rb', line 983 def text @text end |
Instance Method Details
#to_doc ⇒ Object
270 271 272 |
# File 'lib/review/node.rb', line 270 def to_doc @content.map(&:to_doc).join("") end |