Babeltrace 2 C API 2.0.7
Open-source trace manipulation framework
Loading...
Searching...
No Matches
plugin-dev.h
1#ifndef BABELTRACE2_PLUGIN_PLUGIN_DEV_H
2#define BABELTRACE2_PLUGIN_PLUGIN_DEV_H
3
4/*
5 * Copyright (c) 2010-2019 EfficiOS Inc. and Linux Foundation
6 *
7 * Permission is hereby granted, free of charge, to any person obtaining a copy
8 * of this software and associated documentation files (the "Software"), to deal
9 * in the Software without restriction, including without limitation the rights
10 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 * copies of the Software, and to permit persons to whom the Software is
12 * furnished to do so, subject to the following conditions:
13 *
14 * The above copyright notice and this permission notice shall be included in
15 * all copies or substantial portions of the Software.
16 *
17 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23 * SOFTWARE.
24 */
25
26#ifndef __BT_IN_BABELTRACE_H
27# error "Please include <babeltrace2/babeltrace.h> instead."
28#endif
29
30#include <stdint.h>
31
32#include <babeltrace2/graph/component-class-dev.h>
33#include <babeltrace2/graph/message-iterator-class.h>
34#include <babeltrace2/types.h>
35
36/*
37 * _BT_HIDDEN: set the hidden attribute for internal functions
38 * On Windows, symbols are local unless explicitly exported,
39 * see https://gcc.gnu.org/wiki/Visibility
40 */
41#if defined(_WIN32) || defined(__CYGWIN__)
42#define _BT_HIDDEN
43#else
44#define _BT_HIDDEN __attribute__((visibility("hidden")))
45#endif
46
47/*
48 * _BT_EXPORT: set the visibility for exported functions.
49 */
50#if defined(_WIN32) || defined(__CYGWIN__)
51#define _BT_EXPORT
52#else
53#define _BT_EXPORT __attribute__((visibility("default")))
54#endif
55
56#ifdef __cplusplus
57extern "C" {
58#endif
59
348#define BT_PLUGIN_MODULE() \
349 static struct __bt_plugin_descriptor const * const __bt_plugin_descriptor_dummy __BT_PLUGIN_DESCRIPTOR_ATTRS = NULL; \
350 _BT_HIDDEN extern struct __bt_plugin_descriptor const *__BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL __BT_PLUGIN_DESCRIPTOR_BEGIN_EXTRA; \
351 _BT_HIDDEN extern struct __bt_plugin_descriptor const *__BT_PLUGIN_DESCRIPTOR_END_SYMBOL __BT_PLUGIN_DESCRIPTOR_END_EXTRA; \
352 \
353 static struct __bt_plugin_descriptor_attribute const * const __bt_plugin_descriptor_attribute_dummy __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS = NULL; \
354 _BT_HIDDEN extern struct __bt_plugin_descriptor_attribute const *__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA; \
355 _BT_HIDDEN extern struct __bt_plugin_descriptor_attribute const *__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_EXTRA; \
356 \
357 static struct __bt_plugin_component_class_descriptor const * const __bt_plugin_component_class_descriptor_dummy __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS = NULL; \
358 _BT_HIDDEN extern struct __bt_plugin_component_class_descriptor const *__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_EXTRA; \
359 _BT_HIDDEN extern struct __bt_plugin_component_class_descriptor const *__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_EXTRA; \
360 \
361 static struct __bt_plugin_component_class_descriptor_attribute const * const __bt_plugin_component_class_descriptor_attribute_dummy __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_ATTRS = NULL; \
362 _BT_HIDDEN extern struct __bt_plugin_component_class_descriptor_attribute const *__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA; \
363 _BT_HIDDEN extern struct __bt_plugin_component_class_descriptor_attribute const *__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_EXTRA; \
364 \
365 _BT_EXPORT struct __bt_plugin_descriptor const * const *__bt_get_begin_section_plugin_descriptors(void) \
366 { \
367 return &__BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL; \
368 } \
369 _BT_EXPORT struct __bt_plugin_descriptor const * const *__bt_get_end_section_plugin_descriptors(void) \
370 { \
371 return &__BT_PLUGIN_DESCRIPTOR_END_SYMBOL; \
372 } \
373 _BT_EXPORT struct __bt_plugin_descriptor_attribute const * const *__bt_get_begin_section_plugin_descriptor_attributes(void) \
374 { \
375 return &__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL; \
376 } \
377 _BT_EXPORT struct __bt_plugin_descriptor_attribute const * const *__bt_get_end_section_plugin_descriptor_attributes(void) \
378 { \
379 return &__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL; \
380 } \
381 _BT_EXPORT struct __bt_plugin_component_class_descriptor const * const *__bt_get_begin_section_component_class_descriptors(void) \
382 { \
383 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL; \
384 } \
385 _BT_EXPORT struct __bt_plugin_component_class_descriptor const * const *__bt_get_end_section_component_class_descriptors(void) \
386 { \
387 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL; \
388 } \
389 _BT_EXPORT struct __bt_plugin_component_class_descriptor_attribute const * const *__bt_get_begin_section_component_class_descriptor_attributes(void) \
390 { \
391 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL; \
392 } \
393 _BT_EXPORT struct __bt_plugin_component_class_descriptor_attribute const * const *__bt_get_end_section_component_class_descriptor_attributes(void) \
394 { \
395 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL; \
396 }
397
425#define BT_PLUGIN_WITH_ID(_id, _name) \
426 struct __bt_plugin_descriptor __bt_plugin_descriptor_##_id = { \
427 .name = _name, \
428 }; \
429 static struct __bt_plugin_descriptor const * const __bt_plugin_descriptor_##_id##_ptr __BT_PLUGIN_DESCRIPTOR_ATTRS = &__bt_plugin_descriptor_##_id
430
436#define BT_PLUGIN(_name) static BT_PLUGIN_WITH_ID(auto, #_name)
437
467#define BT_PLUGIN_DESCRIPTION_WITH_ID(_id, _description) \
468 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _id, _description)
469
475#define BT_PLUGIN_DESCRIPTION(_description) BT_PLUGIN_DESCRIPTION_WITH_ID(auto, _description)
476
477
500#define BT_PLUGIN_AUTHOR_WITH_ID(_id, _author) \
501 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(author, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_AUTHOR, _id, _author)
502
508#define BT_PLUGIN_AUTHOR(_author) BT_PLUGIN_AUTHOR_WITH_ID(auto, _author)
509
532#define BT_PLUGIN_LICENSE_WITH_ID(_id, _license) \
533 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(license, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_LICENSE, _id, _license)
534
540#define BT_PLUGIN_LICENSE(_license) BT_PLUGIN_LICENSE_WITH_ID(auto, _license)
541
582#define BT_PLUGIN_VERSION_WITH_ID(_id, _major, _minor, _patch, _extra) \
583 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(version, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_VERSION, _id, __BT_PLUGIN_VERSION_STRUCT_VALUE(_major, _minor, _patch, _extra))
584
590#define BT_PLUGIN_VERSION(_major, _minor, _patch, _extra) BT_PLUGIN_VERSION_WITH_ID(auto, _major, _minor, _patch, _extra)
591
622
647 bt_self_plugin *self_plugin);
648
669#define BT_PLUGIN_INITIALIZE_FUNC_WITH_ID(_id, _func) \
670 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(init, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_INIT, _id, _func)
671
677#define BT_PLUGIN_INITIALIZE_FUNC(_func) BT_PLUGIN_INITIALIZE_FUNC_WITH_ID(auto, _func)
678
683typedef void (*bt_plugin_finalize_func)(void);
684
705#define BT_PLUGIN_FINALIZE_FUNC_WITH_ID(_id, _func) \
706 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(exit, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_EXIT, _id, _func)
707
713#define BT_PLUGIN_FINALIZE_FUNC(_func) BT_PLUGIN_FINALIZE_FUNC_WITH_ID(auto, _func)
714
759#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_WITH_ID(_plugin_id, _component_class_id, _name, _message_iterator_class_next_method) \
760 static struct __bt_plugin_component_class_descriptor __bt_plugin_source_component_class_descriptor_##_plugin_id##_##_component_class_id = { \
761 .plugin_descriptor = &__bt_plugin_descriptor_##_plugin_id, \
762 .name = _name, \
763 .type = BT_COMPONENT_CLASS_TYPE_SOURCE, \
764 .methods = { .source = { .msg_iter_next = _message_iterator_class_next_method } }, \
765 }; \
766 static struct __bt_plugin_component_class_descriptor const * const __bt_plugin_source_component_class_descriptor_##_plugin_id##_##_component_class_id##_ptr __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS = &__bt_plugin_source_component_class_descriptor_##_plugin_id##_##_component_class_id
767
784#define BT_PLUGIN_SOURCE_COMPONENT_CLASS(_name, _message_iterator_class_next_method) \
785 BT_PLUGIN_SOURCE_COMPONENT_CLASS_WITH_ID(auto, _name, #_name, _message_iterator_class_next_method)
786
824#define BT_PLUGIN_FILTER_COMPONENT_CLASS_WITH_ID(_plugin_id, _component_class_id, _name, _message_iterator_class_next_method) \
825 static struct __bt_plugin_component_class_descriptor __bt_plugin_filter_component_class_descriptor_##_plugin_id##_##_component_class_id = { \
826 .plugin_descriptor = &__bt_plugin_descriptor_##_plugin_id, \
827 .name = _name, \
828 .type = BT_COMPONENT_CLASS_TYPE_FILTER, \
829 .methods = { .filter = { .msg_iter_next = _message_iterator_class_next_method } }, \
830 }; \
831 static struct __bt_plugin_component_class_descriptor const * const __bt_plugin_filter_component_class_descriptor_##_plugin_id##_##_component_class_id##_ptr __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS = &__bt_plugin_filter_component_class_descriptor_##_plugin_id##_##_component_class_id
832
849#define BT_PLUGIN_FILTER_COMPONENT_CLASS(_name, _message_iterator_class_next_method) \
850 BT_PLUGIN_FILTER_COMPONENT_CLASS_WITH_ID(auto, _name, #_name, _message_iterator_class_next_method)
851
889#define BT_PLUGIN_SINK_COMPONENT_CLASS_WITH_ID(_plugin_id, _component_class_id, _name, _consume_method) \
890 static struct __bt_plugin_component_class_descriptor __bt_plugin_sink_component_class_descriptor_##_plugin_id##_##_component_class_id = { \
891 .plugin_descriptor = &__bt_plugin_descriptor_##_plugin_id, \
892 .name = _name, \
893 .type = BT_COMPONENT_CLASS_TYPE_SINK, \
894 .methods = { .sink = { .consume = _consume_method } }, \
895 }; \
896 static struct __bt_plugin_component_class_descriptor const * const __bt_plugin_sink_component_class_descriptor_##_plugin_id##_##_component_class_id##_ptr __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS = &__bt_plugin_sink_component_class_descriptor_##_plugin_id##_##_component_class_id
897
914#define BT_PLUGIN_SINK_COMPONENT_CLASS(_name, _consume_method) \
915 BT_PLUGIN_SINK_COMPONENT_CLASS_WITH_ID(auto, _name, #_name, _consume_method)
916
956#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_DESCRIPTION_WITH_ID(_plugin_id, _component_class_id, _description) \
957 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _plugin_id, _component_class_id, source, _description)
958
965#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_DESCRIPTION(_name, _description) \
966 BT_PLUGIN_SOURCE_COMPONENT_CLASS_DESCRIPTION_WITH_ID(auto, _name, _description)
967
1000#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_HELP_WITH_ID(_plugin_id, _component_class_id, _help_text) \
1001 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(help, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP, _plugin_id, _component_class_id, source, _help_text)
1002
1009#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_HELP(_name, _help_text) \
1010 BT_PLUGIN_SOURCE_COMPONENT_CLASS_HELP_WITH_ID(auto, _name, _help_text)
1011
1051#define BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION_WITH_ID(_plugin_id, _component_class_id, _description) \
1052 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _plugin_id, _component_class_id, filter, _description)
1053
1060#define BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION(_name, _description) \
1061 BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION_WITH_ID(auto, _name, _description)
1062
1095#define BT_PLUGIN_FILTER_COMPONENT_CLASS_HELP_WITH_ID(_plugin_id, _component_class_id, _help_text) \
1096 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(help, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP, _plugin_id, _component_class_id, filter, _help_text)
1097
1104#define BT_PLUGIN_FILTER_COMPONENT_CLASS_HELP(_name, _help_text) \
1105 BT_PLUGIN_FILTER_COMPONENT_CLASS_HELP_WITH_ID(auto, _name, _help_text)
1106
1146#define BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION_WITH_ID(_plugin_id, _component_class_id, _description) \
1147 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _plugin_id, _component_class_id, sink, _description)
1148
1155#define BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION(_name, _description) \
1156 BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION_WITH_ID(auto, _name, _description)
1157
1190#define BT_PLUGIN_SINK_COMPONENT_CLASS_HELP_WITH_ID(_plugin_id, _component_class_id, _help_text) \
1191 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(help, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP, _plugin_id, _component_class_id, sink, _help_text)
1192
1199#define BT_PLUGIN_SINK_COMPONENT_CLASS_HELP(_name, _help_text) \
1200 BT_PLUGIN_SINK_COMPONENT_CLASS_HELP_WITH_ID(auto, _name, _help_text)
1201
1241#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1242 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD, _plugin_id, _component_class_id, source, _method)
1243
1251#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_FINALIZE_METHOD(_name, _method) \
1252 BT_PLUGIN_SOURCE_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _method)
1253
1287#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1288 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_get_supported_mip_versions_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS_METHOD, _plugin_id, _component_class_id, source, _method)
1289
1297#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD(_name, _method) \
1298 BT_PLUGIN_SOURCE_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_WITH_ID(auto, _name, _method)
1299
1332#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1333 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD, _plugin_id, _component_class_id, source, _method)
1334
1342#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_INITIALIZE_METHOD(_name, _method) \
1343 BT_PLUGIN_SOURCE_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(auto, _name, _method)
1344
1377#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_FINALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1378 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD, _plugin_id, _component_class_id, source, _method)
1379
1387#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_FINALIZE_METHOD(_name, _method) \
1388 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _method)
1389
1423#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_INITIALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1424 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INITIALIZE_METHOD, _plugin_id, _component_class_id, source, _method)
1425
1433#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_INITIALIZE_METHOD(_name, _method) \
1434 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_INITIALIZE_METHOD_WITH_ID(auto, _name, _method)
1435
1485#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_BEGINNING_METHODS_WITH_ID(_plugin_id, _component_class_id, _seek_method, _can_seek_method) \
1486 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_seek_beginning_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD, _plugin_id, _component_class_id, source, _seek_method); \
1487 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_can_seek_beginning_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD, _plugin_id, _component_class_id, source, _can_seek_method)
1488
1496#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_BEGINNING_METHODS(_name, _seek_method, _can_seek_method) \
1497 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_BEGINNING_METHODS_WITH_ID(auto, _name, _seek_method, _can_seek_method)
1498
1549#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_NS_FROM_ORIGIN_METHODS_WITH_ID(_plugin_id, _component_class_id, _seek_method, _can_seek_method) \
1550 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_seek_ns_from_origin_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD, _plugin_id, _component_class_id, source, _seek_method); \
1551 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_can_seek_ns_from_origin_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD, _plugin_id, _component_class_id, source, _can_seek_method)
1552
1560#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_NS_FROM_ORIGIN_METHODS(_name, _seek_method, _can_seek_method) \
1561 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_NS_FROM_ORIGIN_METHODS_WITH_ID(auto, _name, _seek_method, _can_seek_method)
1562
1597#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1598 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_output_port_connected_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD, _plugin_id, _component_class_id, source, _method)
1599
1607#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD(_name, _method) \
1608 BT_PLUGIN_SOURCE_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _method)
1609
1642#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1643 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_query_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD, _plugin_id, _component_class_id, source, _method)
1644
1652#define BT_PLUGIN_SOURCE_COMPONENT_CLASS_QUERY_METHOD(_name, _method) \
1653 BT_PLUGIN_SOURCE_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(auto, _name, _method)
1654
1694#define BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1695 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD, _plugin_id, _component_class_id, filter, _method)
1696
1704#define BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD(_name, _method) \
1705 BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _method)
1706
1740#define BT_PLUGIN_FILTER_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1741 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_get_supported_mip_versions_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS_METHOD, _plugin_id, _component_class_id, filter, _method)
1742
1750#define BT_PLUGIN_FILTER_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD(_name, _method) \
1751 BT_PLUGIN_FILTER_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_WITH_ID(auto, _name, _method)
1752
1785#define BT_PLUGIN_FILTER_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1786 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD, _plugin_id, _component_class_id, filter, _method)
1787
1795#define BT_PLUGIN_FILTER_COMPONENT_CLASS_INITIALIZE_METHOD(_name, _method) \
1796 BT_PLUGIN_FILTER_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(auto, _name, _method)
1797
1832#define BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1833 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_input_port_connected_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD, _plugin_id, _component_class_id, filter, _method)
1834
1842#define BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD(_name, _method) \
1843 BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _method)
1844
1877#define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_FINALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1878 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD, _plugin_id, _component_class_id, filter, _method)
1879
1887#define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_FINALIZE_METHOD(_name, _method) \
1888 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _method)
1889
1923#define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_INITIALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
1924 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INITIALIZE_METHOD, _plugin_id, _component_class_id, filter, _method)
1925
1933#define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_INITIALIZE_METHOD(_name, _method) \
1934 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_INITIALIZE_METHOD_WITH_ID(auto, _name, _method)
1935
1985#define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_BEGINNING_METHODS_WITH_ID(_plugin_id, _component_class_id, _seek_method, _can_seek_method) \
1986 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_seek_beginning_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD, _plugin_id, _component_class_id, filter, _seek_method); \
1987 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_can_seek_beginning_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD, _plugin_id, _component_class_id, filter, _can_seek_method);
1988
1996#define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_BEGINNING_METHODS(_name, _seek_method, _can_seek_method) \
1997 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_BEGINNING_METHODS_WITH_ID(auto, _name, _seek_method, _can_seek_method)
1998
2049#define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_NS_FROM_ORIGIN_METHODS_WITH_ID(_plugin_id, _component_class_id, _seek_method, _can_seek_method) \
2050 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_seek_ns_from_origin_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD, _plugin_id, _component_class_id, filter, _seek_method); \
2051 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(msg_iter_can_seek_ns_from_origin_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD, _plugin_id, _component_class_id, filter, _can_seek_method)
2052
2060#define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_NS_FROM_ORIGIN_METHODS(_name, _seek_method, _can_seek_method) \
2061 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CLASS_SEEK_NS_FROM_ORIGIN_METHODS_WITH_ID(auto, _name, _seek_method, _can_seek_method)
2062
2097#define BT_PLUGIN_FILTER_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
2098 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_output_port_connected_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD, _plugin_id, _component_class_id, filter, _method)
2099
2107#define BT_PLUGIN_FILTER_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD(_name, _method) \
2108 BT_PLUGIN_FILTER_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _method)
2109
2142#define BT_PLUGIN_FILTER_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
2143 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_query_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD, _plugin_id, _component_class_id, filter, _method)
2144
2152#define BT_PLUGIN_FILTER_COMPONENT_CLASS_QUERY_METHOD(_name, _method) \
2153 BT_PLUGIN_FILTER_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(auto, _name, _method)
2154
2194#define BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
2195 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD, _plugin_id, _component_class_id, sink, _method)
2196
2204#define BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD(_name, _method) \
2205 BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _method)
2206
2240#define BT_PLUGIN_SINK_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
2241 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_get_supported_mip_versions_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS_METHOD, _plugin_id, _component_class_id, sink, _method)
2242
2250#define BT_PLUGIN_SINK_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD(_name, _method) \
2251 BT_PLUGIN_SINK_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_WITH_ID(auto, _name, _method)
2252
2287#define BT_PLUGIN_SINK_COMPONENT_CLASS_GRAPH_IS_CONFIGURED_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
2288 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_graph_is_configured_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GRAPH_IS_CONFIGURED_METHOD, _plugin_id, _component_class_id, sink, _method)
2289
2297#define BT_PLUGIN_SINK_COMPONENT_CLASS_GRAPH_IS_CONFIGURED_METHOD(_name, _method) \
2298 BT_PLUGIN_SINK_COMPONENT_CLASS_GRAPH_IS_CONFIGURED_METHOD_WITH_ID(auto, _name, _method)
2299
2332#define BT_PLUGIN_SINK_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
2333 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD, _plugin_id, _component_class_id, sink, _method)
2334
2342#define BT_PLUGIN_SINK_COMPONENT_CLASS_INITIALIZE_METHOD(_name, _method) \
2343 BT_PLUGIN_SINK_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(auto, _name, _method)
2344
2379#define BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
2380 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_input_port_connected_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD, _plugin_id, _component_class_id, sink, _method)
2381
2389#define BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD(_name, _method) \
2390 BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _method)
2391
2424#define BT_PLUGIN_SINK_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(_plugin_id, _component_class_id, _method) \
2425 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_query_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD, _plugin_id, _component_class_id, sink, _method)
2426
2434#define BT_PLUGIN_SINK_COMPONENT_CLASS_QUERY_METHOD(_name, _method) \
2435 BT_PLUGIN_SINK_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(auto, _name, _method)
2436
2441/* Plugin descriptor: describes a single plugin (internal use) */
2442struct __bt_plugin_descriptor {
2443 /* Plugin's name */
2444 const char *name;
2445} __attribute__((packed));
2446
2447/* Type of a plugin attribute (internal use) */
2448enum __bt_plugin_descriptor_attribute_type {
2449 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_INIT = 0,
2450 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_EXIT = 1,
2451 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_AUTHOR = 2,
2452 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_LICENSE = 3,
2453 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION = 4,
2454 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_VERSION = 5,
2455};
2456
2457/* Plugin (user) version */
2458struct __bt_plugin_descriptor_version {
2459 uint32_t major;
2460 uint32_t minor;
2461 uint32_t patch;
2462 const char *extra;
2463};
2464
2465/* Plugin attribute (internal use) */
2466struct __bt_plugin_descriptor_attribute {
2467 /* Plugin descriptor to which to associate this attribute */
2468 const struct __bt_plugin_descriptor *plugin_descriptor;
2469
2470 /* Name of the attribute's type for debug purposes */
2471 const char *type_name;
2472
2473 /* Attribute's type */
2474 enum __bt_plugin_descriptor_attribute_type type;
2475
2476 /* Attribute's value (depends on attribute's type) */
2477 union {
2478 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_INIT */
2480
2481 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_EXIT */
2483
2484 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_AUTHOR */
2485 const char *author;
2486
2487 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_LICENSE */
2488 const char *license;
2489
2490 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION */
2491 const char *description;
2492
2493 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_VERSION */
2494 struct __bt_plugin_descriptor_version version;
2495 } value;
2496} __attribute__((packed));
2497
2498/* Component class descriptor (internal use) */
2499struct __bt_plugin_component_class_descriptor {
2500 /*
2501 * Plugin descriptor to which to associate this component
2502 * class descriptor.
2503 */
2504 const struct __bt_plugin_descriptor *plugin_descriptor;
2505
2506 /* Component class name */
2507 const char *name;
2508
2509 /* Component class type */
2511
2512 /* Mandatory methods (depends on component class type) */
2513 union {
2514 /* BT_COMPONENT_CLASS_TYPE_SOURCE */
2515 struct {
2517 } source;
2518
2519 /* BT_COMPONENT_CLASS_TYPE_FILTER */
2520 struct {
2522 } filter;
2523
2524 /* BT_COMPONENT_CLASS_TYPE_SINK */
2525 struct {
2527 } sink;
2528 } methods;
2529} __attribute__((packed));
2530
2531/* Type of a component class attribute (internal use) */
2532enum __bt_plugin_component_class_descriptor_attribute_type {
2533 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION = 0,
2534 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP = 1,
2535 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS_METHOD = 2,
2536 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD = 3,
2537 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD = 4,
2538 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD = 5,
2539 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD = 6,
2540 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD = 7,
2541 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GRAPH_IS_CONFIGURED_METHOD = 8,
2542 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INITIALIZE_METHOD = 9,
2543 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD = 10,
2544 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD = 11,
2545 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD = 12,
2546 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD = 13,
2547 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD = 14,
2548};
2549
2550/* Component class attribute (internal use) */
2551struct __bt_plugin_component_class_descriptor_attribute {
2552 /*
2553 * Component class plugin attribute to which to associate this
2554 * component class attribute.
2555 */
2556 const struct __bt_plugin_component_class_descriptor *comp_class_descriptor;
2557
2558 /* Name of the attribute's type for debug purposes */
2559 const char *type_name;
2560
2561 /* Attribute's type */
2562 enum __bt_plugin_component_class_descriptor_attribute_type type;
2563
2564 /* Attribute's value (depends on attribute's type) */
2565 union {
2566 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION */
2567 const char *description;
2568
2569 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP */
2570 const char *help;
2571
2572 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS_METHOD */
2573 bt_component_class_source_get_supported_mip_versions_method source_get_supported_mip_versions_method;
2574 bt_component_class_filter_get_supported_mip_versions_method filter_get_supported_mip_versions_method;
2575 bt_component_class_sink_get_supported_mip_versions_method sink_get_supported_mip_versions_method;
2576
2577 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD */
2578 bt_component_class_source_initialize_method source_initialize_method;
2579 bt_component_class_filter_initialize_method filter_initialize_method;
2580 bt_component_class_sink_initialize_method sink_initialize_method;
2581
2582 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD */
2583 bt_component_class_source_finalize_method source_finalize_method;
2584 bt_component_class_filter_finalize_method filter_finalize_method;
2585 bt_component_class_sink_finalize_method sink_finalize_method;
2586
2587 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD */
2588 bt_component_class_source_query_method source_query_method;
2589 bt_component_class_filter_query_method filter_query_method;
2590 bt_component_class_sink_query_method sink_query_method;
2591
2592 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD */
2593 bt_component_class_filter_input_port_connected_method filter_input_port_connected_method;
2594 bt_component_class_sink_input_port_connected_method sink_input_port_connected_method;
2595
2596 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD */
2597 bt_component_class_source_output_port_connected_method source_output_port_connected_method;
2598 bt_component_class_filter_output_port_connected_method filter_output_port_connected_method;
2599
2600 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GRAPH_IS_CONFIGURED_METHOD */
2601 bt_component_class_sink_graph_is_configured_method sink_graph_is_configured_method;
2602
2603 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INITIALIZE_METHOD */
2604 bt_message_iterator_class_initialize_method msg_iter_initialize_method;
2605
2606 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD */
2607 bt_message_iterator_class_finalize_method msg_iter_finalize_method;
2608
2609 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD */
2610 bt_message_iterator_class_seek_ns_from_origin_method msg_iter_seek_ns_from_origin_method;
2611
2612 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD */
2613 bt_message_iterator_class_seek_beginning_method msg_iter_seek_beginning_method;
2614
2615 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD */
2616 bt_message_iterator_class_can_seek_ns_from_origin_method msg_iter_can_seek_ns_from_origin_method;
2617
2618 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD */
2619 bt_message_iterator_class_can_seek_beginning_method msg_iter_can_seek_beginning_method;
2620 } value;
2621} __attribute__((packed));
2622
2623struct __bt_plugin_descriptor const * const *__bt_get_begin_section_plugin_descriptors(void);
2624struct __bt_plugin_descriptor const * const *__bt_get_end_section_plugin_descriptors(void);
2625struct __bt_plugin_descriptor_attribute const * const *__bt_get_begin_section_plugin_descriptor_attributes(void);
2626struct __bt_plugin_descriptor_attribute const * const *__bt_get_end_section_plugin_descriptor_attributes(void);
2627struct __bt_plugin_component_class_descriptor const * const *__bt_get_begin_section_component_class_descriptors(void);
2628struct __bt_plugin_component_class_descriptor const * const *__bt_get_end_section_component_class_descriptors(void);
2629struct __bt_plugin_component_class_descriptor_attribute const * const *__bt_get_begin_section_component_class_descriptor_attributes(void);
2630struct __bt_plugin_component_class_descriptor_attribute const * const *__bt_get_end_section_component_class_descriptor_attributes(void);
2631
2632/*
2633 * Defines a plugin attribute (generic, internal use).
2634 *
2635 * _attr_name: Name of the attribute (C identifier).
2636 * _attr_type: Type of the attribute (enum __bt_plugin_descriptor_attribute_type).
2637 * _id: Plugin descriptor ID (C identifier).
2638 * _x: Value.
2639 */
2640#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(_attr_name, _attr_type, _id, _x) \
2641 static struct __bt_plugin_descriptor_attribute __bt_plugin_descriptor_attribute_##_id##_##_attr_name = { \
2642 .plugin_descriptor = &__bt_plugin_descriptor_##_id, \
2643 .type_name = #_attr_name, \
2644 .type = _attr_type, \
2645 .value = { ._attr_name = _x }, \
2646 }; \
2647 static struct __bt_plugin_descriptor_attribute const * const __bt_plugin_descriptor_attribute_##_id##_##_attr_name##_ptr __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS = &__bt_plugin_descriptor_attribute_##_id##_##_attr_name
2648
2649#define __BT_PLUGIN_VERSION_STRUCT_VALUE(_major, _minor, _patch, _extra) \
2650 {.major = _major, .minor = _minor, .patch = _patch, .extra = _extra,}
2651
2652/*
2653 * Defines a component class descriptor attribute (generic, internal
2654 * use).
2655 *
2656 * _id: Plugin descriptor ID (C identifier).
2657 * _component_class_id: Component class ID (C identifier).
2658 * _type: Component class type (`source`, `filter`, or `sink`).
2659 * _attr_name: Name of the attribute (C identifier).
2660 * _attr_type: Type of the attribute
2661 * (enum __bt_plugin_descriptor_attribute_type).
2662 * _x: Value.
2663 */
2664#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(_attr_name, _attr_type, _id, _component_class_id, _type, _x) \
2665 static struct __bt_plugin_component_class_descriptor_attribute __bt_plugin_##_type##_component_class_descriptor_attribute_##_id##_##_component_class_id##_##_attr_name = { \
2666 .comp_class_descriptor = &__bt_plugin_##_type##_component_class_descriptor_##_id##_##_component_class_id, \
2667 .type_name = #_attr_name, \
2668 .type = _attr_type, \
2669 .value = { ._attr_name = _x }, \
2670 }; \
2671 static struct __bt_plugin_component_class_descriptor_attribute const * const __bt_plugin_##_type##_component_class_descriptor_attribute_##_id##_##_component_class_id##_##_attr_name##_ptr __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_ATTRS = &__bt_plugin_##_type##_component_class_descriptor_attribute_##_id##_##_component_class_id##_##_attr_name
2672
2673/*
2674 * Clang supports the no_sanitize variable attribute on global variables.
2675 * GCC only supports the no_sanitize_address function attribute, which is
2676 * not what we need. This is fine because, as far as we have seen, gcc
2677 * does not insert red zones around global variables.
2678 */
2679#if defined(__clang__)
2680# if __has_feature(address_sanitizer)
2681# define __bt_plugin_variable_attribute_no_sanitize_address \
2682 __attribute__((no_sanitize("address")))
2683# else
2684# define __bt_plugin_variable_attribute_no_sanitize_address
2685# endif
2686#else
2687# define __bt_plugin_variable_attribute_no_sanitize_address
2688#endif
2689
2690/*
2691 * Variable attributes for a plugin descriptor pointer to be added to
2692 * the plugin descriptor section (internal use).
2693 */
2694#ifdef __APPLE__
2695#define __BT_PLUGIN_DESCRIPTOR_ATTRS \
2696 __attribute__((section("__DATA,btp_desc"), used)) \
2697 __bt_plugin_variable_attribute_no_sanitize_address
2698
2699#define __BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL \
2700 __start___bt_plugin_descriptors
2701
2702#define __BT_PLUGIN_DESCRIPTOR_END_SYMBOL \
2703 __stop___bt_plugin_descriptors
2704
2705#define __BT_PLUGIN_DESCRIPTOR_BEGIN_EXTRA \
2706 __asm("section$start$__DATA$btp_desc")
2707
2708#define __BT_PLUGIN_DESCRIPTOR_END_EXTRA \
2709 __asm("section$end$__DATA$btp_desc")
2710
2711#else
2712
2713#define __BT_PLUGIN_DESCRIPTOR_ATTRS \
2714 __attribute__((section("__bt_plugin_descriptors"), used)) \
2715 __bt_plugin_variable_attribute_no_sanitize_address
2716
2717#define __BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL \
2718 __start___bt_plugin_descriptors
2719
2720#define __BT_PLUGIN_DESCRIPTOR_END_SYMBOL \
2721 __stop___bt_plugin_descriptors
2722
2723#define __BT_PLUGIN_DESCRIPTOR_BEGIN_EXTRA
2724
2725#define __BT_PLUGIN_DESCRIPTOR_END_EXTRA
2726#endif
2727
2728/*
2729 * Variable attributes for a plugin attribute pointer to be added to
2730 * the plugin attribute section (internal use).
2731 */
2732#ifdef __APPLE__
2733#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS \
2734 __attribute__((section("__DATA,btp_desc_att"), used)) \
2735 __bt_plugin_variable_attribute_no_sanitize_address
2736
2737#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
2738 __start___bt_plugin_descriptor_attributes
2739
2740#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
2741 __stop___bt_plugin_descriptor_attributes
2742
2743#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA \
2744 __asm("section$start$__DATA$btp_desc_att")
2745
2746#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_EXTRA \
2747 __asm("section$end$__DATA$btp_desc_att")
2748
2749#else
2750
2751#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS \
2752 __attribute__((section("__bt_plugin_descriptor_attributes"), used)) \
2753 __bt_plugin_variable_attribute_no_sanitize_address
2754
2755#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
2756 __start___bt_plugin_descriptor_attributes
2757
2758#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
2759 __stop___bt_plugin_descriptor_attributes
2760
2761#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA
2762
2763#define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_EXTRA
2764#endif
2765
2766/*
2767 * Variable attributes for a component class descriptor pointer to be
2768 * added to the component class descriptor section (internal use).
2769 */
2770#ifdef __APPLE__
2771#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS \
2772 __attribute__((section("__DATA,btp_cc_desc"), used)) \
2773 __bt_plugin_variable_attribute_no_sanitize_address
2774
2775#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL \
2776 __start___bt_plugin_component_class_descriptors
2777
2778#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL \
2779 __stop___bt_plugin_component_class_descriptors
2780
2781#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_EXTRA \
2782 __asm("section$start$__DATA$btp_cc_desc")
2783
2784#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_EXTRA \
2785 __asm("section$end$__DATA$btp_cc_desc")
2786
2787#else
2788
2789#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS \
2790 __attribute__((section("__bt_plugin_component_class_descriptors"), used)) \
2791 __bt_plugin_variable_attribute_no_sanitize_address
2792
2793#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL \
2794 __start___bt_plugin_component_class_descriptors
2795
2796#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL \
2797 __stop___bt_plugin_component_class_descriptors
2798
2799#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_EXTRA
2800
2801#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_EXTRA
2802#endif
2803
2804/*
2805 * Variable attributes for a component class descriptor attribute
2806 * pointer to be added to the component class descriptor attribute
2807 * section (internal use).
2808 */
2809#ifdef __APPLE__
2810#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_ATTRS \
2811 __attribute__((section("__DATA,btp_cc_desc_att"), used)) \
2812 __bt_plugin_variable_attribute_no_sanitize_address
2813
2814#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
2815 __start___bt_plugin_component_class_descriptor_attributes
2816
2817#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
2818 __stop___bt_plugin_component_class_descriptor_attributes
2819
2820#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA \
2821 __asm("section$start$__DATA$btp_cc_desc_att")
2822
2823#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_EXTRA \
2824 __asm("section$end$__DATA$btp_cc_desc_att")
2825
2826#else
2827
2828#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_ATTRS \
2829 __attribute__((section("__bt_plugin_component_class_descriptor_attributes"), used)) \
2830 __bt_plugin_variable_attribute_no_sanitize_address
2831
2832#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
2833 __start___bt_plugin_component_class_descriptor_attributes
2834
2835#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
2836 __stop___bt_plugin_component_class_descriptor_attributes
2837
2838#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA
2839
2840#define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_EXTRA
2841#endif
2842
2843#ifdef __cplusplus
2844}
2845#endif
2846
2847#endif /* BABELTRACE2_PLUGIN_PLUGIN_DEV_H */
bt_component_class_initialize_method_status(* bt_component_class_source_initialize_method)(bt_self_component_source *self_component, bt_self_component_source_configuration *configuration, const bt_value *params, void *initialize_method_data)
Source component initialization method.
Definition component-class-dev.h:943
void(* bt_component_class_filter_finalize_method)(bt_self_component_filter *self_component)
Filter component finalization method.
Definition component-class-dev.h:599
void(* bt_component_class_source_finalize_method)(bt_self_component_source *self_component)
Source component finalization method.
Definition component-class-dev.h:580
bt_component_class_initialize_method_status(* bt_component_class_filter_initialize_method)(bt_self_component_filter *self_component, bt_self_component_filter_configuration *configuration, const bt_value *params, void *initialize_method_data)
Filter component initialization method.
Definition component-class-dev.h:990
bt_component_class_port_connected_method_status(* bt_component_class_filter_output_port_connected_method)(bt_self_component_filter *self_component, bt_self_component_port_output *self_port, const bt_port_input *other_port)
Filter component "output port connected" method.
Definition component-class-dev.h:1171
bt_component_class_get_supported_mip_versions_method_status(* bt_component_class_filter_get_supported_mip_versions_method)(bt_self_component_class_filter *self_component_class, const bt_value *params, void *initialize_method_data, bt_logging_level logging_level, bt_integer_range_set_unsigned *supported_versions)
Filter component class "get supported Message Interchange Protocol versions" method.
Definition component-class-dev.h:759
bt_component_class_initialize_method_status(* bt_component_class_sink_initialize_method)(bt_self_component_sink *self_component, bt_self_component_sink_configuration *configuration, const bt_value *params, void *initialize_method_data)
Sink component initialization method.
Definition component-class-dev.h:1038
bt_component_class_sink_graph_is_configured_method_status(* bt_component_class_sink_graph_is_configured_method)(bt_self_component_sink *self_component)
Sink component "graph is configured" method.
Definition component-class-dev.h:871
bt_component_class_port_connected_method_status(* bt_component_class_filter_input_port_connected_method)(bt_self_component_filter *self_component, bt_self_component_port_input *self_port, const bt_port_output *other_port)
Filter component "input port connected" method.
Definition component-class-dev.h:1136
bt_component_class_get_supported_mip_versions_method_status(* bt_component_class_source_get_supported_mip_versions_method)(bt_self_component_class_source *self_component_class, const bt_value *params, void *initialize_method_data, bt_logging_level logging_level, bt_integer_range_set_unsigned *supported_versions)
Source component class "get supported Message Interchange Protocol versions" method.
Definition component-class-dev.h:700
bt_component_class_query_method_status(* bt_component_class_filter_query_method)(bt_self_component_class_filter *self_component_class, bt_private_query_executor *query_executor, const char *object_name, const bt_value *params, void *method_data, const bt_value **result)
Filter component class query method.
Definition component-class-dev.h:1374
bt_component_class_query_method_status(* bt_component_class_sink_query_method)(bt_self_component_class_sink *self_component_class, bt_private_query_executor *query_executor, const char *object_name, const bt_value *params, void *method_data, const bt_value **result)
Sink component class query method.
Definition component-class-dev.h:1439
bt_component_class_get_supported_mip_versions_method_status(* bt_component_class_sink_get_supported_mip_versions_method)(bt_self_component_class_sink *self_component_class, const bt_value *params, void *initialize_method_data, bt_logging_level logging_level, bt_integer_range_set_unsigned *supported_versions)
Sink component class "get supported Message Interchange Protocol versions" method.
Definition component-class-dev.h:817
bt_component_class_port_connected_method_status(* bt_component_class_sink_input_port_connected_method)(bt_self_component_sink *self_component, bt_self_component_port_input *self_port, const bt_port_output *other_port)
Sink component "input port connected" method.
Definition component-class-dev.h:1206
void(* bt_component_class_sink_finalize_method)(bt_self_component_sink *self_component)
Sink component finalization method.
Definition component-class-dev.h:618
bt_component_class_port_connected_method_status(* bt_component_class_source_output_port_connected_method)(bt_self_component_source *self_component, bt_self_component_port_output *self_port, const bt_port_input *other_port)
Source component "output port connected" method.
Definition component-class-dev.h:1101
bt_component_class_sink_consume_method_status(* bt_component_class_sink_consume_method)(bt_self_component_sink *self_component)
Sink component consuming method.
Definition component-class-dev.h:561
bt_component_class_query_method_status(* bt_component_class_source_query_method)(bt_self_component_class_source *self_component_class, bt_private_query_executor *query_executor, const char *object_name, const bt_value *params, void *method_data, const bt_value **result)
Source component class query method.
Definition component-class-dev.h:1309
bt_component_class_type
Component class type enumerators.
Definition component-class.h:214
bt_message_iterator_class_initialize_method_status(* bt_message_iterator_class_initialize_method)(bt_self_message_iterator *self_message_iterator, bt_self_message_iterator_configuration *configuration, bt_self_component_port_output *port)
Message iterator initialization method.
Definition message-iterator-class.h:722
bt_message_iterator_class_can_seek_beginning_method_status(* bt_message_iterator_class_can_seek_beginning_method)(bt_self_message_iterator *self_message_iterator, bt_bool *can_seek_beginning)
Message iterator "can seek beginning?" method.
Definition message-iterator-class.h:575
bt_message_iterator_class_seek_beginning_method_status(* bt_message_iterator_class_seek_beginning_method)(bt_self_message_iterator *self_message_iterator)
Message iterator "seek beginning" method.
Definition message-iterator-class.h:902
bt_message_iterator_class_can_seek_ns_from_origin_method_status(* bt_message_iterator_class_can_seek_ns_from_origin_method)(bt_self_message_iterator *self_message_iterator, int64_t ns_from_origin, bt_bool *can_seek_ns_from_origin)
Message iterator "can seek ns from origin?" method.
Definition message-iterator-class.h:646
bt_message_iterator_class_seek_ns_from_origin_method_status(* bt_message_iterator_class_seek_ns_from_origin_method)(bt_self_message_iterator *self_message_iterator, int64_t ns_from_origin)
Message iterator "seek ns from origin" method.
Definition message-iterator-class.h:968
bt_message_iterator_class_next_method_status(* bt_message_iterator_class_next_method)(bt_self_message_iterator *self_message_iterator, bt_message_array_const messages, uint64_t capacity, uint64_t *count)
Message iterator "next" (get next messages) method.
Definition message-iterator-class.h:836
void(* bt_message_iterator_class_finalize_method)(bt_self_message_iterator *self_message_iterator)
Message iterator finalization method.
Definition message-iterator-class.h:667
void(* bt_plugin_finalize_func)(void)
User plugin finalization function.
Definition plugin-dev.h:683
bt_plugin_initialize_func_status
Status codes for bt_plugin_initialize_func.
Definition plugin-dev.h:603
bt_plugin_initialize_func_status(* bt_plugin_initialize_func)(bt_self_plugin *self_plugin)
User plugin initialization function.
Definition plugin-dev.h:646
@ BT_PLUGIN_INITIALIZE_FUNC_STATUS_OK
Success.
Definition plugin-dev.h:608
@ BT_PLUGIN_INITIALIZE_FUNC_STATUS_MEMORY_ERROR
Out of memory.
Definition plugin-dev.h:614
@ BT_PLUGIN_INITIALIZE_FUNC_STATUS_ERROR
Error.
Definition plugin-dev.h:620