Class: ReVIEW::DlistNode

Inherits:
Node show all
Defined in:
lib/review/node.rb,
lib/review/compiler.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Node

#inspect, #to_json, #to_raw, #to_s_by

Constructor Details

#initialize(compiler, position, content) ⇒ DlistNode

Returns a new instance of DlistNode.



965
966
967
968
969
# File 'lib/review/compiler.rb', line 965

def initialize(compiler, position, content)
  @compiler = compiler
  @position = position
  @content = content
end

Instance Attribute Details

#compilerObject (readonly)

Returns the value of attribute compiler.



970
971
972
# File 'lib/review/compiler.rb', line 970

def compiler
  @compiler
end

#contentObject (readonly)

Returns the value of attribute content.



972
973
974
# File 'lib/review/compiler.rb', line 972

def content
  @content
end

#positionObject (readonly)

Returns the value of attribute position.



971
972
973
# File 'lib/review/compiler.rb', line 971

def position
  @position
end

Instance Method Details

#to_docObject



264
265
266
# File 'lib/review/node.rb', line 264

def to_doc
  @compiler.compile_dlist(@content)
end