Class: NewRelic::TransactionSample::CompositeSegment
- Defined in:
- lib/new_relic/transaction_sample.rb
Instance Attribute Summary collapse
-
#detail_segments ⇒ Object
Returns the value of attribute detail_segments.
Attributes inherited from Segment
#entry_timestamp, #exit_timestamp, #metric_name, #parent_segment, #segment_id
Instance Method Summary collapse
-
#initialize(segments) ⇒ CompositeSegment
constructor
A new instance of CompositeSegment.
Methods inherited from Segment
#[], #[]=, #add_called_segment, #called_segments, #called_segments=, #count_segments, #duration, #each_segment, #end_trace, #exclusive_duration, #explain_sql, #find_segment, from_json, #handle_exception_in_explain, #obfuscated_sql, #params, #path_string, #to_debug_str, #to_json, #to_s, #to_s_compact, #truncate
Constructor Details
#initialize(segments) ⇒ CompositeSegment
Returns a new instance of CompositeSegment.
302 303 304 305 306 307 308 309 310 311 312 |
# File 'lib/new_relic/transaction_sample.rb', line 302 def initialize(segments) summary = SummarySegment.new(segments.first) super summary., "Repeating pattern (#{segments.length} repeats)", nil summary.end_trace(segments.last.) @detail_segments = segments.clone add_called_segment(summary) end_trace summary. end |
Instance Attribute Details
#detail_segments ⇒ Object
Returns the value of attribute detail_segments.
300 301 302 |
# File 'lib/new_relic/transaction_sample.rb', line 300 def detail_segments @detail_segments end |