Class: InstrumentAllTheThings::Context
- Inherits:
-
Struct
- Object
- Struct
- InstrumentAllTheThings::Context
- Defined in:
- lib/instrument_all_the_things/context.rb
Instance Attribute Summary collapse
-
#instance ⇒ Object
Returns the value of attribute instance.
-
#method_name ⇒ Object
Returns the value of attribute method_name.
-
#tags ⇒ Object
Returns the value of attribute tags.
Instance Method Summary collapse
Instance Attribute Details
#instance ⇒ Object
Returns the value of attribute instance
4 5 6 |
# File 'lib/instrument_all_the_things/context.rb', line 4 def instance @instance end |
#method_name ⇒ Object
Returns the value of attribute method_name
4 5 6 |
# File 'lib/instrument_all_the_things/context.rb', line 4 def method_name @method_name end |
#tags ⇒ Object
Returns the value of attribute tags
4 5 6 |
# File 'lib/instrument_all_the_things/context.rb', line 4 def @tags end |
Instance Method Details
#stats_name(klass_or_instance) ⇒ Object
5 6 7 8 9 10 11 |
# File 'lib/instrument_all_the_things/context.rb', line 5 def stats_name(klass_or_instance) @stats_name ||= [ class_name(klass_or_instance), "#{instance ? 'instance' : 'class'}_methods", method_name, ].join('.') end |
#trace_name(klass_or_instance) ⇒ Object
13 14 15 |
# File 'lib/instrument_all_the_things/context.rb', line 13 def trace_name(klass_or_instance) @trace_name ||= "#{class_name(klass_or_instance)}#{instance ? '.' : '#'}#{method_name}" end |