Class RubyProf::FlatPrinter
In: lib/ruby-prof/flat_printer.rb
Parent: AbstractPrinter

Generates flat profile reports as text. To use the flat printer:

  result = RubyProf.profile do
    [code to profile]
  end

  printer = RubyProf::FlatPrinter.new(result)
  printer.print(STDOUT, 0)

Methods

print  

Public Instance methods

Print a flat profile report to the provided output.

output - Any IO oject, including STDOUT or a file. The default value is STDOUT.

options - Hash of print options. See setup_options

          for more information.

[Source]

    # File lib/ruby-prof/flat_printer.rb, line 23
23:     def print(output = STDOUT, options = {})
24:       @output = output
25:       setup_options(options)
26:       print_threads
27:     end

[Validate]