X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=include%2Fbabeltrace%2Fctf-ir%2Fstream-class-internal.h;h=c88be91c02fa0ffe129938b3c941e60c38c56155;hb=29664b2a3a15c7233d916887d2f58fc42e18521e;hp=c53823d1beac5f4bca63bc963cd565759085740e;hpb=2f100782231d86cdaaadf7a8568c5b28583800f4;p=babeltrace.git diff --git a/include/babeltrace/ctf-ir/stream-class-internal.h b/include/babeltrace/ctf-ir/stream-class-internal.h index c53823d1..c88be91c 100644 --- a/include/babeltrace/ctf-ir/stream-class-internal.h +++ b/include/babeltrace/ctf-ir/stream-class-internal.h @@ -31,6 +31,7 @@ #include #include #include +#include #include #include #include @@ -44,13 +45,13 @@ struct bt_ctf_stream_class { uint32_t id; uint32_t next_event_id; uint32_t next_stream_id; - struct bt_ctf_field_type *event_header_type; - struct bt_ctf_field *event_header; + /* Weak reference; a stream class does not have ownership of a trace */ + struct bt_ctf_trace *trace; struct bt_ctf_field_type *packet_context_type; - struct bt_ctf_field *packet_context; + struct bt_ctf_field_type *event_header_type; struct bt_ctf_field_type *event_context_type; - struct bt_ctf_field *event_context; int frozen; + int byte_order; }; BT_HIDDEN @@ -64,4 +65,17 @@ BT_HIDDEN int bt_ctf_stream_class_set_byte_order(struct bt_ctf_stream_class *stream_class, enum bt_ctf_byte_order byte_order); +/* Set stream_class id without checking if the stream class is frozen */ +BT_HIDDEN +int _bt_ctf_stream_class_set_id(struct bt_ctf_stream_class *stream_class, + uint32_t id); + +BT_HIDDEN +int bt_ctf_stream_class_set_id_no_check( + struct bt_ctf_stream_class *stream_class, uint32_t id); + +BT_HIDDEN +int bt_ctf_stream_class_set_trace(struct bt_ctf_stream_class *stream_class, + struct bt_ctf_trace *trace); + #endif /* BABELTRACE_CTF_IR_STREAM_CLASS_INTERNAL_H */