Sha256: 68ee8b5db80c0b540fe5f49ca138c210e6557e8fa28b8a22c063533b8ebe4b6c

Contents?: true

Size: 542 Bytes

Versions: 17

Compression:

Stored size: 542 Bytes

Contents

# For Magic Panels
module Rack::Insight
  class DefaultInvocation < Struct.new :method, :time, :arguments, :result, :backtrace
    attr_accessor :method, :time, :arguments, :result, :backtrace

    include Rack::Insight::FilteredBacktrace
    include Rack::Insight::MagicInsight

    def initialize(*args)
      @method = args[0]
      @time = [args[1].duration, args[1].delta_t]
      @arguments = args[2]
      @result = args[3]
      @backtrace = args[4]
    end

    def human_time
      "%.2fms" % (self.time * 1_000)
    end

  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
rack-insight-0.6.4 lib/rack/insight/default_invocation.rb
rack-insight-0.6.3 lib/rack/insight/default_invocation.rb
rack-insight-0.6.2 lib/rack/insight/default_invocation.rb
rack-insight-0.5.30 lib/rack/insight/default_invocation.rb
rack-insight-0.5.29 lib/rack/insight/default_invocation.rb
rack-insight-0.5.28 lib/rack/insight/default_invocation.rb
rack-insight-0.5.27 lib/rack/insight/default_invocation.rb
rack-insight-0.5.26 lib/rack/insight/default_invocation.rb
rack-insight-0.5.25 lib/rack/insight/default_invocation.rb
rack-insight-0.5.24 lib/rack/insight/default_invocation.rb
rack-insight-0.5.23 lib/rack/insight/default_invocation.rb
rack-insight-0.5.22 lib/rack/insight/default_invocation.rb
rack-insight-0.5.21 lib/rack/insight/default_invocation.rb
rack-insight-0.5.20 lib/rack/insight/default_invocation.rb
rack-insight-0.5.19 lib/rack/insight/default_invocation.rb
rack-insight-0.5.18 lib/rack/insight/default_invocation.rb
rack-insight-0.5.17 lib/rack/insight/default_invocation.rb