1 #ifndef BABELTRACE2_TRACE_IR_TRACE_CLASS_H
2#define BABELTRACE2_TRACE_IR_TRACE_CLASS_H
26#ifndef __BT_IN_BABELTRACE_H
27# error "Please include <babeltrace2/babeltrace.h> instead."
32#include <babeltrace2/types.h>
326 bt_bool assigns_automatic_stream_class_id);
624#define BT_TRACE_CLASS_PUT_REF_AND_RESET(_trace_class) \
626 bt_trace_class_put_ref(_trace_class); \
627 (_trace_class) = NULL; \
655#define BT_TRACE_CLASS_MOVE_REF(_dst, _src) \
657 bt_trace_class_put_ref(_dst); \
uint64_t bt_listener_id
Numeric ID which identifies a user listener function.
Definition types.h:150
int bt_bool
Babeltrace 2 boolean type.
Definition types.h:140
struct bt_self_component bt_self_component
Self component.
Definition types.h:85
struct bt_stream_class bt_stream_class
Stream class.
Definition types.h:104
bt_trace_class_remove_listener_status bt_trace_class_remove_destruction_listener(const bt_trace_class *trace_class, bt_listener_id listener_id)
Removes the destruction listener having the ID listener_id from the trace class trace_class.
const bt_stream_class * bt_trace_class_borrow_stream_class_by_id_const(const bt_trace_class *trace_class, uint64_t id)
Borrows the stream class having the numeric ID id from the trace class trace_class (const version).
bt_bool bt_trace_class_assigns_automatic_stream_class_id(const bt_trace_class *trace_class)
Returns whether or not the trace class trace_class automatically assigns a numeric ID to a stream cla...
const bt_value * bt_trace_class_borrow_user_attributes_const(const bt_trace_class *trace_class)
Borrows the user attributes of the trace class trace_class (const version).
void bt_trace_class_put_ref(const bt_trace_class *trace_class)
Decrements the reference count of the trace class trace_class.
const bt_stream_class * bt_trace_class_borrow_stream_class_by_index_const(const bt_trace_class *trace_class, uint64_t index)
Borrows the stream class at index index from the trace class trace_class (const version).
void bt_trace_class_get_ref(const bt_trace_class *trace_class)
Increments the reference count of the trace class trace_class.
bt_stream_class * bt_trace_class_borrow_stream_class_by_id(bt_trace_class *trace_class, uint64_t id)
Borrows the stream class having the numeric ID id from the trace class trace_class.
bt_stream_class * bt_trace_class_borrow_stream_class_by_index(bt_trace_class *trace_class, uint64_t index)
Borrows the stream class at index index from the trace class trace_class.
bt_trace_class_add_listener_status
Status codes for bt_trace_class_add_destruction_listener().
Definition trace-class.h:459
void(* bt_trace_class_destruction_listener_func)(const bt_trace_class *trace_class, void *user_data)
User function for bt_trace_class_add_destruction_listener().
Definition trace-class.h:452
void bt_trace_class_set_assigns_automatic_stream_class_id(bt_trace_class *trace_class, bt_bool assigns_automatic_stream_class_id)
Sets whether or not the trace class trace_class automatically assigns a numeric ID to a stream class ...
bt_value * bt_trace_class_borrow_user_attributes(bt_trace_class *trace_class)
Borrows the user attributes of the trace class trace_class.
bt_trace_class * bt_trace_class_create(bt_self_component *self_component)
Creates a default trace class from the self component self_component.
void bt_trace_class_set_user_attributes(bt_trace_class *trace_class, const bt_value *user_attributes)
Sets the user attributes of the trace class trace_class to user_attributes.
bt_trace_class_remove_listener_status
Status codes for bt_trace_class_remove_destruction_listener().
Definition trace-class.h:521
struct bt_trace_class bt_trace_class
Trace class.
Definition types.h:106
bt_trace_class_add_listener_status bt_trace_class_add_destruction_listener(const bt_trace_class *trace_class, bt_trace_class_destruction_listener_func user_func, void *user_data, bt_listener_id *listener_id)
Adds a destruction listener having the function user_func to the trace class trace_class.
uint64_t bt_trace_class_get_stream_class_count(const bt_trace_class *trace_class)
Returns the number of stream classes contained in the trace class trace_class.
@ BT_TRACE_CLASS_ADD_LISTENER_STATUS_OK
Success.
Definition trace-class.h:464
@ BT_TRACE_CLASS_ADD_LISTENER_STATUS_MEMORY_ERROR
Out of memory.
Definition trace-class.h:470
@ BT_TRACE_CLASS_REMOVE_LISTENER_STATUS_MEMORY_ERROR
Out of memory.
Definition trace-class.h:532
@ BT_TRACE_CLASS_REMOVE_LISTENER_STATUS_OK
Success.
Definition trace-class.h:526
struct bt_value bt_value
Value.
Definition types.h:107