cpp-common/bt2c/fmt.hpp: use `wise_enum::string_type` in `EnableIfIsWiseEnum` definition
[babeltrace.git] / src / plugins / text / details / obj-lifetime-mgmt.h
1 /*
2 * SPDX-License-Identifier: MIT
3 *
4 * Copyright 2019 Philippe Proulx <pproulx@efficios.com>
5 */
6
7 #ifndef BABELTRACE_PLUGINS_TEXT_DETAILS_OBJ_LIFETIME_MGMT_H
8 #define BABELTRACE_PLUGINS_TEXT_DETAILS_OBJ_LIFETIME_MGMT_H
9
10 #include <glib.h>
11 #include <babeltrace2/babeltrace.h>
12 #include <stdbool.h>
13
14 #include "details.h"
15 #include "write.h"
16
17 /*
18 * Returns whether or not stream class or event class `obj`, which
19 * belongs to `tc`, needs to be written.
20 */
21 bool details_need_to_write_meta_object(struct details_write_ctx *ctx,
22 const bt_trace_class *tc, const void *obj);
23
24 /*
25 * Marks stream class or event class `obj`, which belongs to `tc`, as
26 * written.
27 */
28 void details_did_write_meta_object(struct details_write_ctx *ctx,
29 const bt_trace_class *tc, const void *obj);
30
31 /*
32 * Returns whether or not trace class `tc` needs to be written.
33 */
34 bool details_need_to_write_trace_class(struct details_write_ctx *ctx,
35 const bt_trace_class *tc);
36
37 /*
38 * Marks trace class `tc` as written.
39 */
40 int details_did_write_trace_class(struct details_write_ctx *ctx,
41 const bt_trace_class *tc);
42
43 /*
44 * Writes the unique trace ID of `trace` to `*unique_id`, allocating a
45 * new unique ID if none exists.
46 */
47 int details_trace_unique_id(struct details_write_ctx *ctx,
48 const bt_trace *trace, uint64_t *unique_id);
49
50 #endif /* BABELTRACE_PLUGINS_TEXT_DETAILS_OBJ_LIFETIME_MGMT_H */
This page took 0.031062 seconds and 4 git commands to generate.