Add stream_event_context accessors
[babeltrace.git] / include / babeltrace / ctf-ir / stream.h
index d9e2bc26e3a00b4b749801904ef3571acbfbc624..ab0a8c7e534b5d290f9d3c2f8064430095dc4edb 100644 (file)
@@ -109,6 +109,31 @@ extern int bt_ctf_stream_set_packet_context(
                struct bt_ctf_stream *stream,
                struct bt_ctf_field *packet_context);
 
+/*
+ * bt_ctf_stream_get_event_context: get a stream's event context.
+ *
+ * @param stream Stream instance.
+ *
+ * Returns a field instance on success, NULL on error.
+ */
+extern struct bt_ctf_field *bt_ctf_stream_get_event_context(
+               struct bt_ctf_stream *stream);
+
+/*
+ * bt_ctf_stream_set_event_context: set a stream's event context.
+ *
+ * The event context's type must match the stream class' event
+ * context type.
+ *
+ * @param stream Stream instance.
+ * @param event_context Event context field instance.
+ *
+ * Returns a field instance on success, NULL on error.
+ */
+extern int bt_ctf_stream_set_event_context(
+               struct bt_ctf_stream *stream,
+               struct bt_ctf_field *event_context);
+
 /*
  * bt_ctf_stream_flush: flush a stream.
  *
This page took 0.023057 seconds and 4 git commands to generate.