2 * SPDX-License-Identifier: MIT
4 * Copyright 2016 Philippe Proulx <pproulx@efficios.com>
6 * The Common Trace Format (CTF) Specification is available at
7 * http://www.efficios.com/ctf
10 #ifndef BABELTRACE_CTF_WRITER_FIELD_PATH_H
11 #define BABELTRACE_CTF_WRITER_FIELD_PATH_H
13 #include "common/common.h"
14 #include "common/assert.h"
15 #include "common/macros.h"
16 #include <babeltrace2-ctf-writer/field-types.h>
21 struct bt_ctf_field_path
{
22 struct bt_ctf_object base
;
23 enum bt_ctf_scope root
;
26 * Array of integers (int) indicating the index in either
27 * structures, variants, arrays, or sequences that make up
28 * the path to a field type. -1 means the "current element
29 * of an array or sequence type".
34 struct bt_ctf_field_path
*bt_ctf_field_path_create(void);
36 void bt_ctf_field_path_clear(struct bt_ctf_field_path
*field_path
);
38 struct bt_ctf_field_path
*bt_ctf_field_path_copy(
39 struct bt_ctf_field_path
*path
);
41 enum bt_ctf_scope
bt_ctf_field_path_get_root_scope(
42 const struct bt_ctf_field_path
*field_path
);
44 int64_t bt_ctf_field_path_get_index_count(
45 const struct bt_ctf_field_path
*field_path
);
47 int bt_ctf_field_path_get_index(
48 const struct bt_ctf_field_path
*field_path
, uint64_t index
);
50 #endif /* BABELTRACE_CTF_WRITER_FIELD_PATH_H */
This page took 0.035012 seconds and 5 git commands to generate.