Sha256: 5041a430d8ccb55b6d83d430030219abc6c275e0784d640e65273c7068fe15b8

Contents?: true

Size: 804 Bytes

Versions: 14

Compression:

Stored size: 804 Bytes

Contents

require 'rdoc/markup'
require 'rdoc/markup/formatter'

##
# This Markup outputter is used for testing purposes.

class RDoc::Markup::ToTest < RDoc::Markup::Formatter

  def start_accepting
    @res = []
  end

  def end_accepting
    @res
  end

  def accept_paragraph(am, fragment)
    @res << fragment.to_s
  end

  def accept_verbatim(am, fragment)
    @res << fragment.to_s
  end

  def accept_list_start(am, fragment)
    @res << fragment.to_s
  end

  def accept_list_end(am, fragment)
    @res << fragment.to_s
  end

  def accept_list_item(am, fragment)
    @res << fragment.to_s
  end

  def accept_blank_line(am, fragment)
    @res << fragment.to_s
  end

  def accept_heading(am, fragment)
    @res << fragment.to_s
  end

  def accept_rule(am, fragment)
    @res << fragment.to_s
  end

end

Version data entries

14 entries across 14 versions & 3 rubygems

Version Path
iownbey-rdoc-2.0.1 lib/rdoc/markup/to_test.rb
shoesgem-0.1514.0 shoes/ruby/lib/rdoc/markup/to_test.rb
shoesgem-0.1480.0 shoes/ruby/lib/rdoc/markup/to_test.rb
shoesgem-0.1469.0 shoes/ruby/lib/rdoc/markup/to_test.rb
shoesgem-0.1430.0 shoes/ruby/lib/rdoc/markup/to_test.rb
shoesgem-0.1429.0 shoes/ruby/lib/rdoc/markup/to_test.rb
shoesgem-0.1428.0 shoes/ruby/lib/rdoc/markup/to_test.rb
shoesgem-0.1426.0 shoes/ruby/lib/rdoc/markup/to_test.rb
shoesgem-0.1424.0 shoes/ruby/lib/rdoc/markup/to_test.rb
rdoc-2.0.0 lib/rdoc/markup/to_test.rb
rdoc-2.2.0 lib/rdoc/markup/to_test.rb
rdoc-2.3.0 lib/rdoc/markup/to_test.rb
rdoc-2.1.0 lib/rdoc/markup/to_test.rb
rdoc-2.2.1 lib/rdoc/markup/to_test.rb