#include <babeltrace/ctf/events.h>
#include <glib.h>
-typedef void(*type_freeze_func)(struct bt_ctf_field_type *);
-typedef int(*type_serialize_func)(struct bt_ctf_field_type *,
+typedef void (*type_freeze_func)(struct bt_ctf_field_type *);
+typedef int (*type_serialize_func)(struct bt_ctf_field_type *,
struct metadata_context *);
struct bt_ctf_field_type {
struct bt_ctf_ref ref_count;
struct bt_declaration *declaration;
- GString *alias_name;
type_freeze_func freeze;
type_serialize_func serialize;
/*
struct bt_ctf_field_type_integer {
struct bt_ctf_field_type parent;
struct declaration_integer declaration;
+ struct bt_ctf_clock *mapped_clock;
};
struct enumeration_mapping {
struct bt_ctf_field_type parent;
GHashTable *field_name_to_index;
GPtrArray *fields; /* Array of pointers to struct structure_field */
- struct declaration_enum declaration;
+ struct declaration_struct declaration;
};
struct bt_ctf_field_type_variant {
BT_HIDDEN
void bt_ctf_field_type_set_native_byte_order(
struct bt_ctf_field_type *type, int byte_order);
+
+/* Deep copy a field type */
+BT_HIDDEN
+struct bt_ctf_field_type *bt_ctf_field_type_copy(
+ struct bt_ctf_field_type *type);
+
+
+BT_HIDDEN
+int bt_ctf_field_type_structure_get_field_name_index(
+ struct bt_ctf_field_type *structure, const char *name);
#endif /* BABELTRACE_CTF_IR_EVENT_TYPES_INTERNAL_H */