Class: SeeingIsBelieving::EventStream::Handlers::Debug
- Inherits:
-
Object
- Object
- SeeingIsBelieving::EventStream::Handlers::Debug
- Defined in:
- lib/seeing_is_believing/event_stream/handlers/debug.rb
Overview
Even though the debugger can be disabled, which would push the decision of whether to report or not into the debugger where it belongs, you should still avoid using this class if you don’t need it since it is expensive and there could be tens of millions of events, eg github.com/JoshCheek/seeing_is_believing/issues/12
Instance Method Summary collapse
- #call(event) ⇒ Object
-
#initialize(debugger, handler) ⇒ Debug
constructor
A new instance of Debug.
Constructor Details
#initialize(debugger, handler) ⇒ Debug
Returns a new instance of Debug.
9 10 11 12 13 14 15 16 |
# File 'lib/seeing_is_believing/event_stream/handlers/debug.rb', line 9 def initialize(debugger, handler) @debugger = debugger @handler = handler @seen = "" @line_width = 150 # debugger is basically for me, so giving it a nice wide width @name_width = 20 @attr_width = @line_width - @name_width end |