An IOTap is an easy way to send all top information to andy IO based object. Both profile and trace tap information can be captured This means you can send the events to STDOUT with:
db.profile_tap = db.trace_tap = Amalgalite::Taps::Stdout.new
# File lib/amalgalite/taps/io.rb, line 43 def dump_profile samplers.each_pair do |k,v| io.puts v.to_s end end
# File lib/amalgalite/taps/io.rb, line 39 def output_profile_event( msg, time ) io.puts "#{time} : #{msg}" end
need a profile method, it routes through the profile tap which calls back to output_profile_event
# File lib/amalgalite/taps/io.rb, line 35 def profile( msg, time ) @profile_tap.profile(msg, time) end
Generated with the Darkfish Rdoc Generator 2.