Class: Hometown::Trace
- Inherits:
-
Object
- Object
- Hometown::Trace
- Defined in:
- lib/hometown/trace.rb
Instance Attribute Summary collapse
-
#backtrace ⇒ Object
readonly
Returns the value of attribute backtrace.
-
#traced_class ⇒ Object
readonly
Returns the value of attribute traced_class.
Instance Method Summary collapse
- #eql?(b) ⇒ Boolean
- #hash ⇒ Object
-
#initialize(traced_class, backtrace) ⇒ Trace
constructor
A new instance of Trace.
Constructor Details
#initialize(traced_class, backtrace) ⇒ Trace
Returns a new instance of Trace.
5 6 7 8 |
# File 'lib/hometown/trace.rb', line 5 def initialize(traced_class, backtrace) @traced_class = traced_class @backtrace = backtrace end |
Instance Attribute Details
#backtrace ⇒ Object (readonly)
Returns the value of attribute backtrace.
3 4 5 |
# File 'lib/hometown/trace.rb', line 3 def backtrace @backtrace end |
#traced_class ⇒ Object (readonly)
Returns the value of attribute traced_class.
3 4 5 |
# File 'lib/hometown/trace.rb', line 3 def traced_class @traced_class end |
Instance Method Details
#eql?(b) ⇒ Boolean
10 11 12 13 |
# File 'lib/hometown/trace.rb', line 10 def eql?(b) @traced_class == b.traced_class && @backtrace == b.backtrace end |
#hash ⇒ Object
15 16 17 |
# File 'lib/hometown/trace.rb', line 15 def hash [@traced_class, @backtrace].hash end |