Class: Babeltrace2::BTMessage::Event
- Inherits:
-
Babeltrace2::BTMessage
- Object
- Babeltrace2::BTObject
- Babeltrace2::BTSharedObject
- Babeltrace2::BTMessage
- Babeltrace2::BTMessage::Event
- Defined in:
- lib/babeltrace2/graph/message.rb
Constant Summary
Constants inherited from Babeltrace2::BTMessage
StreamClockSnapshotState, Type
Instance Attribute Summary
Attributes inherited from Babeltrace2::BTObject
Instance Method Summary collapse
- #get_default_clock_snapshot ⇒ Object (also: #default_clock_snapshot)
- #get_event ⇒ Object (also: #event)
- #get_stream_class_default_clock_class ⇒ Object (also: #stream_class_default_clock_class)
-
#initialize(handle = nil, retain: true, auto_release: true, self_message_iterator: nil, event_class: nil, stream: nil, clock_snapshot_value: nil, packet: nil) ⇒ Event
constructor
A new instance of Event.
Methods inherited from Babeltrace2::BTMessage
Methods inherited from Babeltrace2::BTSharedObject
Methods inherited from Babeltrace2::BTObject
Constructor Details
#initialize(handle = nil, retain: true, auto_release: true, self_message_iterator: nil, event_class: nil, stream: nil, clock_snapshot_value: nil, packet: nil) ⇒ Event
269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 |
# File 'lib/babeltrace2/graph/message.rb', line 269 def initialize(handle = nil, retain: true, auto_release: true, self_message_iterator: nil, event_class: nil, stream: nil, clock_snapshot_value: nil, packet: nil) if handle super(handle, retain: retain, auto_release: auto_release) else handle = if clock_snapshot_value if packet Babeltrace2.( , event_class, packet, clock_snapshot_value) else Babeltrace2.( , event_class, stream, clock_snapshot_value) end else if packet Babeltrace2.( , event_class, packet) else Babeltrace2.( , event_class, stream) end end raise Babeltrace2.process_error if handle.null? super(handle) end end |
Instance Method Details
#get_default_clock_snapshot ⇒ Object Also known as: default_clock_snapshot
303 304 305 306 |
# File 'lib/babeltrace2/graph/message.rb', line 303 def get_default_clock_snapshot handle = Babeltrace2.(@handle) BTClockSnapshot.new(handle) end |
#get_event ⇒ Object Also known as: event
297 298 299 300 |
# File 'lib/babeltrace2/graph/message.rb', line 297 def get_event handle = Babeltrace2.(@handle) BTEvent.new(handle) end |
#get_stream_class_default_clock_class ⇒ Object Also known as: stream_class_default_clock_class
309 310 311 312 |
# File 'lib/babeltrace2/graph/message.rb', line 309 def get_stream_class_default_clock_class handle = Babeltrace2.(@handle) BTClockClass.new(handle, retain: true, auto_release: true) end |