ir: consolidate reference counting functions
[babeltrace.git] / include / babeltrace / ctf-ir / stream-class.h
index a78437b2dcc86f1feebde91bf2c30c921f4cf2ed..75be6b678f7f37b07aa19d5f14491abf45b5c5ad 100644 (file)
@@ -65,6 +65,16 @@ struct bt_ctf_clock;
  */
 extern struct bt_ctf_stream_class *bt_ctf_stream_class_create(const char *name);
 
+/*
+ * bt_ctf_stream_class_get_trace: Get a stream class' associated trace.
+ *
+ * @param stream_class Stream class.
+ *
+ * Returns the stream class' associated trace, NULL on error.
+ */
+extern struct bt_ctf_trace *bt_ctf_stream_class_get_trace(
+               struct bt_ctf_stream_class *stream_class);
+
 /*
  * bt_ctf_stream_class_get_name: Get a stream class' name.
  *
@@ -280,6 +290,8 @@ extern int bt_ctf_stream_class_set_event_context_type(
  * bt_ctf_stream_class_get and bt_ctf_stream_class_put: increment and
  * decrement the stream class' reference count.
  *
+ * You may also use bt_ctf_get() and bt_ctf_put() with stream class objects.
+ *
  * These functions ensure that the stream class won't be destroyed while it
  * is in use. The same number of get and put (plus one extra put to
  * release the initial reference done at creation) have to be done to
This page took 0.023566 seconds and 4 git commands to generate.