Class: Marker::VerbatimArea

Inherits:
RecursiveList show all
Defined in:
lib/marker/verbatim.rb

Instance Method Summary collapse

Methods inherited from RecursiveList

#r, #single?, #to_a

Methods inherited from Treetop::Runtime::SyntaxNode

#present?

Instance Method Details

#to_html(options = {}) ⇒ Object



11
12
13
14
15
16
17
# File 'lib/marker/verbatim.rb', line 11

def to_html( options = {} )
  "<pre>\n" +
  to_a.map { |l|
    l.to_html(options)
  }.join("\n") +
  "\n</pre>"
end

#to_s(options = {}) ⇒ Object



19
20
21
22
23
24
25
# File 'lib/marker/verbatim.rb', line 19

def to_s( options = {} )
  "-- \n" +
  to_a.map { |l|
    l.to_s(options)
  }.join("\n") +
  "\n-- "
end