82c402adbd2956070eb65c075ce511e7abcdc597
[babeltrace.git] / include / babeltrace2 / babeltrace.h
1 /*
2 * SPDX-License-Identifier: MIT
3 *
4 * Copyright (C) 2010-2019 EfficiOS Inc. and Linux Foundation
5 */
6
7 #ifndef BABELTRACE2_BABELTRACE_H
8 #define BABELTRACE2_BABELTRACE_H
9
10 /*
11 * Tell the specific headers that they are included from this header.
12 *
13 * Do NOT define `__BT_IN_BABELTRACE_H` in user code.
14 */
15 #ifndef __BT_IN_BABELTRACE_H
16 # define __BT_IN_BABELTRACE_H
17 #endif
18
19 /* Internal: needed by some of the following included headers */
20 #include <babeltrace2/func-status.h>
21
22 /* Internal: needed by some of the following included headers */
23 #ifdef __cplusplus
24 # define __BT_UPCAST(_type, _p) static_cast<_type *>(static_cast<void *>(_p))
25 # define __BT_UPCAST_CONST(_type, _p) static_cast<const _type *>(static_cast<const void *>(_p))
26 #else
27 # define __BT_UPCAST(_type, _p) ((_type *) (_p))
28 # define __BT_UPCAST_CONST(_type, _p) ((const _type *) (_p))
29 #endif
30
31 /*
32 * Internal: attribute suitable to tag functions as having printf()-like
33 * arguments.
34 *
35 * We always define `__USE_MINGW_ANSI_STDIO` when building with MinGW, so use
36 * `gnu_printf` directly rather than `__MINGW_PRINTF_FORMAT` (which would require
37 * including `stdio.h`).
38 */
39 #ifdef __MINGW32__
40 # define __BT_PRINTF_FORMAT gnu_printf
41 #else
42 # define __BT_PRINTF_FORMAT printf
43 #endif
44
45 #define __BT_ATTR_FORMAT_PRINTF(_string_index, _first_to_check) \
46 __attribute__((format(__BT_PRINTF_FORMAT, _string_index, _first_to_check)))
47
48 #include <babeltrace2/error-reporting.h>
49 #include <babeltrace2/graph/component-class-dev.h>
50 #include <babeltrace2/graph/component-class.h>
51 #include <babeltrace2/graph/component-descriptor-set.h>
52 #include <babeltrace2/graph/component.h>
53 #include <babeltrace2/graph/connection.h>
54 #include <babeltrace2/graph/graph.h>
55 #include <babeltrace2/graph/interrupter.h>
56 #include <babeltrace2/graph/message-iterator.h>
57 #include <babeltrace2/graph/message.h>
58 #include <babeltrace2/graph/port.h>
59 #include <babeltrace2/graph/private-query-executor.h>
60 #include <babeltrace2/graph/query-executor.h>
61 #include <babeltrace2/graph/self-component-class.h>
62 #include <babeltrace2/graph/self-component-port.h>
63 #include <babeltrace2/graph/self-component.h>
64 #include <babeltrace2/graph/self-message-iterator.h>
65 #include <babeltrace2/integer-range-set.h>
66 #include <babeltrace2/logging.h>
67 #include <babeltrace2/plugin/plugin-dev.h>
68 #include <babeltrace2/plugin/plugin-loading.h>
69 #include <babeltrace2/trace-ir/clock-class.h>
70 #include <babeltrace2/trace-ir/clock-snapshot.h>
71 #include <babeltrace2/trace-ir/event-class.h>
72 #include <babeltrace2/trace-ir/event.h>
73 #include <babeltrace2/trace-ir/field-class.h>
74 #include <babeltrace2/trace-ir/field-path.h>
75 #include <babeltrace2/trace-ir/field.h>
76 #include <babeltrace2/trace-ir/packet.h>
77 #include <babeltrace2/trace-ir/stream-class.h>
78 #include <babeltrace2/trace-ir/stream.h>
79 #include <babeltrace2/trace-ir/trace-class.h>
80 #include <babeltrace2/trace-ir/trace.h>
81 #include <babeltrace2/types.h>
82 #include <babeltrace2/util.h>
83 #include <babeltrace2/value.h>
84 #include <babeltrace2/version.h>
85
86 /* Cancel private definitions */
87 #undef __BT_FUNC_STATUS_AGAIN
88 #undef __BT_FUNC_STATUS_END
89 #undef __BT_FUNC_STATUS_ERROR
90 #undef __BT_FUNC_STATUS_INTERRUPTED
91 #undef __BT_FUNC_STATUS_UNKNOWN_OBJECT
92 #undef __BT_FUNC_STATUS_MEMORY_ERROR
93 #undef __BT_FUNC_STATUS_NOT_FOUND
94 #undef __BT_FUNC_STATUS_OK
95 #undef __BT_FUNC_STATUS_OVERFLOW_ERROR
96 #undef __BT_FUNC_STATUS_USER_ERROR
97 #undef __BT_IN_BABELTRACE_H
98 #undef __BT_UPCAST
99 #undef __BT_UPCAST_CONST
100 #undef __BT_LOGGING_LEVEL_TRACE
101 #undef __BT_LOGGING_LEVEL_DEBUG
102 #undef __BT_LOGGING_LEVEL_INFO
103 #undef __BT_LOGGING_LEVEL_WARNING
104 #undef __BT_LOGGING_LEVEL_ERROR
105 #undef __BT_LOGGING_LEVEL_FATAL
106 #undef __BT_LOGGING_LEVEL_NONE
107
108 #endif /* BABELTRACE2_BABELTRACE_H */
This page took 0.031029 seconds and 3 git commands to generate.