1 #ifndef BABELTRACE2_PLUGIN_PLUGIN_DEV_H
2 #define BABELTRACE2_PLUGIN_PLUGIN_DEV_H
5 * Copyright (c) 2010-2019 EfficiOS Inc. and Linux Foundation
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:
14 * The above copyright notice and this permission notice shall be included in
15 * all copies or substantial portions of the Software.
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
26 #ifndef __BT_IN_BABELTRACE_H
27 # error "Please include <babeltrace2/babeltrace.h> instead."
32 #include <babeltrace2/graph/component-class-const.h>
33 #include <babeltrace2/graph/component-class-source.h>
34 #include <babeltrace2/graph/component-class-filter.h>
35 #include <babeltrace2/graph/component-class-sink.h>
36 #include <babeltrace2/types.h>
39 * _BT_HIDDEN: set the hidden attribute for internal functions
40 * On Windows, symbols are local unless explicitly exported,
41 * see https://gcc.gnu.org/wiki/Visibility
43 #if defined(_WIN32) || defined(__CYGWIN__)
46 #define _BT_HIDDEN __attribute__((visibility("hidden")))
54 * Plugin interface's version, not synced with Babeltrace's version
57 #define __BT_PLUGIN_VERSION_MAJOR 1
58 #define __BT_PLUGIN_VERSION_MINOR 0
60 /* Plugin initialization function type */
61 typedef enum bt_plugin_init_func_status
{
62 BT_PLUGIN_INIT_FUNC_STATUS_OK
= __BT_FUNC_STATUS_OK
,
63 BT_PLUGIN_INIT_FUNC_STATUS_MEMORY_ERROR
= __BT_FUNC_STATUS_MEMORY_ERROR
,
64 BT_PLUGIN_INIT_FUNC_STATUS_ERROR
= __BT_FUNC_STATUS_ERROR
,
65 } bt_plugin_init_func_status
;
67 typedef bt_plugin_init_func_status (*bt_plugin_init_func
)(
68 bt_self_plugin
*plugin
);
70 /* Plugin exit function type */
71 typedef void (*bt_plugin_exit_func
)(void);
73 /* Plugin descriptor: describes a single plugin (internal use) */
74 struct __bt_plugin_descriptor
{
75 /* Plugin's interface major version number */
78 /* Plugin's interface minor version number */
83 } __attribute__((packed
));
85 /* Type of a plugin attribute (internal use) */
86 enum __bt_plugin_descriptor_attribute_type
{
87 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_INIT
= 0,
88 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_EXIT
= 1,
89 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_AUTHOR
= 2,
90 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_LICENSE
= 3,
91 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION
= 4,
92 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_VERSION
= 5,
95 /* Plugin (user) version */
96 struct __bt_plugin_descriptor_version
{
103 /* Plugin attribute (internal use) */
104 struct __bt_plugin_descriptor_attribute
{
105 /* Plugin descriptor to which to associate this attribute */
106 const struct __bt_plugin_descriptor
*plugin_descriptor
;
108 /* Name of the attribute's type for debug purposes */
109 const char *type_name
;
111 /* Attribute's type */
112 enum __bt_plugin_descriptor_attribute_type type
;
114 /* Attribute's value (depends on attribute's type) */
116 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_INIT */
117 bt_plugin_init_func init
;
119 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_EXIT */
120 bt_plugin_exit_func exit
;
122 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_AUTHOR */
125 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_LICENSE */
128 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION */
129 const char *description
;
131 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_VERSION */
132 struct __bt_plugin_descriptor_version version
;
134 } __attribute__((packed
));
136 /* Component class descriptor (internal use) */
137 struct __bt_plugin_component_class_descriptor
{
139 * Plugin descriptor to which to associate this component
142 const struct __bt_plugin_descriptor
*plugin_descriptor
;
144 /* Component class name */
147 /* Component class type */
148 bt_component_class_type type
;
150 /* Mandatory methods (depends on component class type) */
152 /* BT_COMPONENT_CLASS_TYPE_SOURCE */
154 bt_component_class_source_message_iterator_next_method msg_iter_next
;
157 /* BT_COMPONENT_CLASS_TYPE_FILTER */
159 bt_component_class_filter_message_iterator_next_method msg_iter_next
;
162 /* BT_COMPONENT_CLASS_TYPE_SINK */
164 bt_component_class_sink_consume_method consume
;
167 } __attribute__((packed
));
169 /* Type of a component class attribute (internal use) */
170 enum __bt_plugin_component_class_descriptor_attribute_type
{
171 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION
= 0,
172 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP
= 1,
173 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INIT_METHOD
= 2,
174 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD
= 3,
175 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD
= 4,
176 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD
= 5,
177 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD
= 6,
178 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GRAPH_IS_CONFIGURED_METHOD
= 7,
179 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INIT_METHOD
= 8,
180 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD
= 9,
181 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD
= 10,
182 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD
= 11,
183 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD
= 12,
184 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD
= 13,
187 /* Component class attribute (internal use) */
188 struct __bt_plugin_component_class_descriptor_attribute
{
190 * Component class plugin attribute to which to associate this
191 * component class attribute.
193 const struct __bt_plugin_component_class_descriptor
*comp_class_descriptor
;
195 /* Name of the attribute's type for debug purposes */
196 const char *type_name
;
198 /* Attribute's type */
199 enum __bt_plugin_component_class_descriptor_attribute_type type
;
201 /* Attribute's value (depends on attribute's type) */
203 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION */
204 const char *description
;
206 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP */
209 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INIT_METHOD */
210 bt_component_class_source_init_method source_init_method
;
211 bt_component_class_filter_init_method filter_init_method
;
212 bt_component_class_sink_init_method sink_init_method
;
214 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD */
215 bt_component_class_source_finalize_method source_finalize_method
;
216 bt_component_class_filter_finalize_method filter_finalize_method
;
217 bt_component_class_sink_finalize_method sink_finalize_method
;
219 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD */
220 bt_component_class_source_query_method source_query_method
;
221 bt_component_class_filter_query_method filter_query_method
;
222 bt_component_class_sink_query_method sink_query_method
;
224 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD */
225 bt_component_class_filter_input_port_connected_method filter_input_port_connected_method
;
226 bt_component_class_sink_input_port_connected_method sink_input_port_connected_method
;
228 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD */
229 bt_component_class_source_output_port_connected_method source_output_port_connected_method
;
230 bt_component_class_filter_output_port_connected_method filter_output_port_connected_method
;
232 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GRAPH_IS_CONFIGURED_METHOD */
233 bt_component_class_sink_graph_is_configured_method sink_graph_is_configured_method
;
235 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INIT_METHOD */
236 bt_component_class_source_message_iterator_init_method source_msg_iter_init_method
;
237 bt_component_class_filter_message_iterator_init_method filter_msg_iter_init_method
;
239 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD */
240 bt_component_class_source_message_iterator_finalize_method source_msg_iter_finalize_method
;
241 bt_component_class_filter_message_iterator_finalize_method filter_msg_iter_finalize_method
;
243 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD */
244 bt_component_class_source_message_iterator_seek_ns_from_origin_method source_msg_iter_seek_ns_from_origin_method
;
245 bt_component_class_filter_message_iterator_seek_ns_from_origin_method filter_msg_iter_seek_ns_from_origin_method
;
247 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD */
248 bt_component_class_source_message_iterator_seek_beginning_method source_msg_iter_seek_beginning_method
;
249 bt_component_class_filter_message_iterator_seek_beginning_method filter_msg_iter_seek_beginning_method
;
251 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD */
252 bt_component_class_source_message_iterator_can_seek_ns_from_origin_method source_msg_iter_can_seek_ns_from_origin_method
;
253 bt_component_class_filter_message_iterator_can_seek_ns_from_origin_method filter_msg_iter_can_seek_ns_from_origin_method
;
255 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD */
256 bt_component_class_source_message_iterator_can_seek_beginning_method source_msg_iter_can_seek_beginning_method
;
257 bt_component_class_filter_message_iterator_can_seek_beginning_method filter_msg_iter_can_seek_beginning_method
;
259 } __attribute__((packed
));
261 struct __bt_plugin_descriptor
const * const *__bt_get_begin_section_plugin_descriptors(void);
262 struct __bt_plugin_descriptor
const * const *__bt_get_end_section_plugin_descriptors(void);
263 struct __bt_plugin_descriptor_attribute
const * const *__bt_get_begin_section_plugin_descriptor_attributes(void);
264 struct __bt_plugin_descriptor_attribute
const * const *__bt_get_end_section_plugin_descriptor_attributes(void);
265 struct __bt_plugin_component_class_descriptor
const * const *__bt_get_begin_section_component_class_descriptors(void);
266 struct __bt_plugin_component_class_descriptor
const * const *__bt_get_end_section_component_class_descriptors(void);
267 struct __bt_plugin_component_class_descriptor_attribute
const * const *__bt_get_begin_section_component_class_descriptor_attributes(void);
268 struct __bt_plugin_component_class_descriptor_attribute
const * const *__bt_get_end_section_component_class_descriptor_attributes(void);
271 * Variable attributes for a plugin descriptor pointer to be added to
272 * the plugin descriptor section (internal use).
275 #define __BT_PLUGIN_DESCRIPTOR_ATTRS \
276 __attribute__((section("__DATA,btp_desc"), used))
278 #define __BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL \
279 __start___bt_plugin_descriptors
281 #define __BT_PLUGIN_DESCRIPTOR_END_SYMBOL \
282 __stop___bt_plugin_descriptors
284 #define __BT_PLUGIN_DESCRIPTOR_BEGIN_EXTRA \
285 __asm("section$start$__DATA$btp_desc")
287 #define __BT_PLUGIN_DESCRIPTOR_END_EXTRA \
288 __asm("section$end$__DATA$btp_desc")
292 #define __BT_PLUGIN_DESCRIPTOR_ATTRS \
293 __attribute__((section("__bt_plugin_descriptors"), used))
295 #define __BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL \
296 __start___bt_plugin_descriptors
298 #define __BT_PLUGIN_DESCRIPTOR_END_SYMBOL \
299 __stop___bt_plugin_descriptors
301 #define __BT_PLUGIN_DESCRIPTOR_BEGIN_EXTRA
303 #define __BT_PLUGIN_DESCRIPTOR_END_EXTRA
307 * Variable attributes for a plugin attribute pointer to be added to
308 * the plugin attribute section (internal use).
311 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS \
312 __attribute__((section("__DATA,btp_desc_att"), used))
314 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
315 __start___bt_plugin_descriptor_attributes
317 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
318 __stop___bt_plugin_descriptor_attributes
320 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA \
321 __asm("section$start$__DATA$btp_desc_att")
323 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_EXTRA \
324 __asm("section$end$__DATA$btp_desc_att")
328 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS \
329 __attribute__((section("__bt_plugin_descriptor_attributes"), used))
331 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
332 __start___bt_plugin_descriptor_attributes
334 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
335 __stop___bt_plugin_descriptor_attributes
337 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA
339 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_EXTRA
343 * Variable attributes for a component class descriptor pointer to be
344 * added to the component class descriptor section (internal use).
347 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS \
348 __attribute__((section("__DATA,btp_cc_desc"), used))
350 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL \
351 __start___bt_plugin_component_class_descriptors
353 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL \
354 __stop___bt_plugin_component_class_descriptors
356 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_EXTRA \
357 __asm("section$start$__DATA$btp_cc_desc")
359 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_EXTRA \
360 __asm("section$end$__DATA$btp_cc_desc")
364 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS \
365 __attribute__((section("__bt_plugin_component_class_descriptors"), used))
367 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL \
368 __start___bt_plugin_component_class_descriptors
370 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL \
371 __stop___bt_plugin_component_class_descriptors
373 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_EXTRA
375 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_EXTRA
379 * Variable attributes for a component class descriptor attribute
380 * pointer to be added to the component class descriptor attribute
381 * section (internal use).
384 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_ATTRS \
385 __attribute__((section("__DATA,btp_cc_desc_att"), used))
387 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
388 __start___bt_plugin_component_class_descriptor_attributes
390 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
391 __stop___bt_plugin_component_class_descriptor_attributes
393 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA \
394 __asm("section$start$__DATA$btp_cc_desc_att")
396 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_EXTRA \
397 __asm("section$end$__DATA$btp_cc_desc_att")
401 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_ATTRS \
402 __attribute__((section("__bt_plugin_component_class_descriptor_attributes"), used))
404 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
405 __start___bt_plugin_component_class_descriptor_attributes
407 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
408 __stop___bt_plugin_component_class_descriptor_attributes
410 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA
412 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_EXTRA
416 * Declares a plugin descriptor pointer variable with a custom ID.
418 * _id: ID (any valid C identifier except `auto`).
420 #define BT_PLUGIN_DECLARE(_id) extern struct __bt_plugin_descriptor __bt_plugin_descriptor_##_id
423 * Defines a plugin descriptor with a custom ID.
425 * _id: ID (any valid C identifier except `auto`).
426 * _name: Plugin's name (C string).
428 #define BT_PLUGIN_WITH_ID(_id, _name) \
429 struct __bt_plugin_descriptor __bt_plugin_descriptor_##_id = { \
430 .major = __BT_PLUGIN_VERSION_MAJOR, \
431 .minor = __BT_PLUGIN_VERSION_MINOR, \
434 static struct __bt_plugin_descriptor const * const __bt_plugin_descriptor_##_id##_ptr __BT_PLUGIN_DESCRIPTOR_ATTRS = &__bt_plugin_descriptor_##_id
437 * Defines a plugin attribute (generic, internal use).
439 * _attr_name: Name of the attribute (C identifier).
440 * _attr_type: Type of the attribute (enum __bt_plugin_descriptor_attribute_type).
441 * _id: Plugin descriptor ID (C identifier).
444 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(_attr_name, _attr_type, _id, _x) \
445 static struct __bt_plugin_descriptor_attribute __bt_plugin_descriptor_attribute_##_id##_##_attr_name = { \
446 .plugin_descriptor = &__bt_plugin_descriptor_##_id, \
447 .type_name = #_attr_name, \
448 .type = _attr_type, \
449 .value._attr_name = _x, \
451 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
454 * Defines a plugin initialization function attribute attached to a
455 * specific plugin descriptor.
457 * _id: Plugin descriptor ID (C identifier).
458 * _x: Initialization function (bt_plugin_init_func).
460 #define BT_PLUGIN_INIT_WITH_ID(_id, _x) \
461 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(init, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_INIT, _id, _x)
464 * Defines a plugin exit function attribute attached to a specific
467 * _id: Plugin descriptor ID (C identifier).
468 * _x: Exit function (bt_plugin_exit_func).
470 #define BT_PLUGIN_EXIT_WITH_ID(_id, _x) \
471 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(exit, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_EXIT, _id, _x)
474 * Defines an author attribute attached to a specific plugin descriptor.
476 * _id: Plugin descriptor ID (C identifier).
477 * _x: Author (C string).
479 #define BT_PLUGIN_AUTHOR_WITH_ID(_id, _x) \
480 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(author, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_AUTHOR, _id, _x)
483 * Defines a license attribute attached to a specific plugin descriptor.
485 * _id: Plugin descriptor ID (C identifier).
486 * _x: License (C string).
488 #define BT_PLUGIN_LICENSE_WITH_ID(_id, _x) \
489 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(license, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_LICENSE, _id, _x)
492 * Defines a description attribute attached to a specific plugin
495 * _id: Plugin descriptor ID (C identifier).
496 * _x: Description (C string).
498 #define BT_PLUGIN_DESCRIPTION_WITH_ID(_id, _x) \
499 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _id, _x)
501 #define __BT_PLUGIN_VERSION_STRUCT_VALUE(_major, _minor, _patch, _extra) \
502 {.major = _major, .minor = _minor, .patch = _patch, .extra = _extra,}
505 * Defines a version attribute attached to a specific plugin descriptor.
507 * _id: Plugin descriptor ID (C identifier).
508 * _major: Plugin's major version (uint32_t).
509 * _minor: Plugin's minor version (uint32_t).
510 * _patch: Plugin's patch version (uint32_t).
511 * _extra: Plugin's version extra information (C string).
513 #define BT_PLUGIN_VERSION_WITH_ID(_id, _major, _minor, _patch, _extra) \
514 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(version, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_VERSION, _id, __BT_PLUGIN_VERSION_STRUCT_VALUE(_major, _minor, _patch, _extra))
517 * Defines a source component class descriptor with a custom ID.
519 * _id: ID (any valid C identifier except `auto`).
520 * _comp_class_id: Component class ID (C identifier).
521 * _name: Component class name (C string).
522 * _msg_iter_next_method: Component class's iterator next method
523 * (bt_component_class_source_message_iterator_next_method).
525 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_WITH_ID(_id, _comp_class_id, _name, _msg_iter_next_method) \
526 static struct __bt_plugin_component_class_descriptor __bt_plugin_source_component_class_descriptor_##_id##_##_comp_class_id = { \
527 .plugin_descriptor = &__bt_plugin_descriptor_##_id, \
529 .type = BT_COMPONENT_CLASS_TYPE_SOURCE, \
530 .methods.source = { \
531 .msg_iter_next = _msg_iter_next_method, \
534 static struct __bt_plugin_component_class_descriptor const * const __bt_plugin_source_component_class_descriptor_##_id##_##_comp_class_id##_ptr __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS = &__bt_plugin_source_component_class_descriptor_##_id##_##_comp_class_id
537 * Defines a filter component class descriptor with a custom ID.
539 * _id: ID (any valid C identifier except `auto`).
540 * _comp_class_id: Component class ID (C identifier).
541 * _name: Component class name (C string).
542 * _msg_iter_next_method: Component class's iterator next method
543 * (bt_component_class_filter_message_iterator_next_method).
545 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_WITH_ID(_id, _comp_class_id, _name, _msg_iter_next_method) \
546 static struct __bt_plugin_component_class_descriptor __bt_plugin_filter_component_class_descriptor_##_id##_##_comp_class_id = { \
547 .plugin_descriptor = &__bt_plugin_descriptor_##_id, \
549 .type = BT_COMPONENT_CLASS_TYPE_FILTER, \
550 .methods.filter = { \
551 .msg_iter_next = _msg_iter_next_method, \
554 static struct __bt_plugin_component_class_descriptor const * const __bt_plugin_filter_component_class_descriptor_##_id##_##_comp_class_id##_ptr __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS = &__bt_plugin_filter_component_class_descriptor_##_id##_##_comp_class_id
557 * Defines a sink component class descriptor with a custom ID.
559 * _id: ID (any valid C identifier except `auto`).
560 * _comp_class_id: Component class ID (C identifier).
561 * _name: Component class name (C string).
562 * _consume_method: Component class's iterator consume method
563 * (bt_component_class_sink_consume_method).
565 #define BT_PLUGIN_SINK_COMPONENT_CLASS_WITH_ID(_id, _comp_class_id, _name, _consume_method) \
566 static struct __bt_plugin_component_class_descriptor __bt_plugin_sink_component_class_descriptor_##_id##_##_comp_class_id = { \
567 .plugin_descriptor = &__bt_plugin_descriptor_##_id, \
569 .type = BT_COMPONENT_CLASS_TYPE_SINK, \
571 .consume = _consume_method, \
574 static struct __bt_plugin_component_class_descriptor const * const __bt_plugin_sink_component_class_descriptor_##_id##_##_comp_class_id##_ptr __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS = &__bt_plugin_sink_component_class_descriptor_##_id##_##_comp_class_id
577 * Defines a component class descriptor attribute (generic, internal
580 * _id: Plugin descriptor ID (C identifier).
581 * _comp_class_id: Component class ID (C identifier).
582 * _type: Component class type (`source`, `filter`, or `sink`).
583 * _attr_name: Name of the attribute (C identifier).
584 * _attr_type: Type of the attribute
585 * (enum __bt_plugin_descriptor_attribute_type).
588 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(_attr_name, _attr_type, _id, _comp_class_id, _type, _x) \
589 static struct __bt_plugin_component_class_descriptor_attribute __bt_plugin_##_type##_component_class_descriptor_attribute_##_id##_##_comp_class_id##_##_attr_name = { \
590 .comp_class_descriptor = &__bt_plugin_##_type##_component_class_descriptor_##_id##_##_comp_class_id, \
591 .type_name = #_attr_name, \
592 .type = _attr_type, \
593 .value._attr_name = _x, \
595 static struct __bt_plugin_component_class_descriptor_attribute const * const __bt_plugin_##_type##_component_class_descriptor_attribute_##_id##_##_comp_class_id##_##_attr_name##_ptr __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_ATTRS = &__bt_plugin_##_type##_component_class_descriptor_attribute_##_id##_##_comp_class_id##_##_attr_name
598 * Defines a description attribute attached to a specific source
599 * component class descriptor.
601 * _id: Plugin descriptor ID (C identifier).
602 * _comp_class_id: Component class descriptor ID (C identifier).
603 * _x: Description (C string).
605 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_DESCRIPTION_WITH_ID(_id, _comp_class_id, _x) \
606 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _id, _comp_class_id, source, _x)
609 * Defines a description attribute attached to a specific filter
610 * component class descriptor.
612 * _id: Plugin descriptor ID (C identifier).
613 * _comp_class_id: Component class descriptor ID (C identifier).
614 * _x: Description (C string).
616 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION_WITH_ID(_id, _comp_class_id, _x) \
617 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _id, _comp_class_id, filter, _x)
620 * Defines a description attribute attached to a specific sink
621 * component class descriptor.
623 * _id: Plugin descriptor ID (C identifier).
624 * _comp_class_id: Component class descriptor ID (C identifier).
625 * _x: Description (C string).
627 #define BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION_WITH_ID(_id, _comp_class_id, _x) \
628 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _id, _comp_class_id, sink, _x)
631 * Defines a help attribute attached to a specific source component
634 * _id: Plugin descriptor ID (C identifier).
635 * _comp_class_id: Component class descriptor ID (C identifier).
636 * _x: Help (C string).
638 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_HELP_WITH_ID(_id, _comp_class_id, _x) \
639 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(help, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP, _id, _comp_class_id, source, _x)
642 * Defines a help attribute attached to a specific filter component
645 * _id: Plugin descriptor ID (C identifier).
646 * _comp_class_id: Component class descriptor ID (C identifier).
647 * _x: Help (C string).
649 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_HELP_WITH_ID(_id, _comp_class_id, _x) \
650 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(help, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP, _id, _comp_class_id, filter, _x)
653 * Defines a help attribute attached to a specific sink component class
656 * _id: Plugin descriptor ID (C identifier).
657 * _comp_class_id: Component class descriptor ID (C identifier).
658 * _x: Help (C string).
660 #define BT_PLUGIN_SINK_COMPONENT_CLASS_HELP_WITH_ID(_id, _comp_class_id, _x) \
661 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(help, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP, _id, _comp_class_id, sink, _x)
664 * Defines an initialization method attribute attached to a specific
665 * source component class descriptor.
667 * _id: Plugin descriptor ID (C identifier).
668 * _comp_class_id: Component class descriptor ID (C identifier).
669 * _x: Initialization method (bt_component_class_source_init_method).
671 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_INIT_METHOD_WITH_ID(_id, _comp_class_id, _x) \
672 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_init_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INIT_METHOD, _id, _comp_class_id, source, _x)
675 * Defines an initialization method attribute attached to a specific
676 * filter component class descriptor.
678 * _id: Plugin descriptor ID (C identifier).
679 * _comp_class_id: Component class descriptor ID (C identifier).
680 * _x: Initialization method (bt_component_class_filter_init_method).
682 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_INIT_METHOD_WITH_ID(_id, _comp_class_id, _x) \
683 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_init_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INIT_METHOD, _id, _comp_class_id, filter, _x)
686 * Defines an initialization method attribute attached to a specific
687 * sink component class descriptor.
689 * _id: Plugin descriptor ID (C identifier).
690 * _comp_class_id: Component class descriptor ID (C identifier).
691 * _x: Initialization method (bt_component_class_sink_init_method).
693 #define BT_PLUGIN_SINK_COMPONENT_CLASS_INIT_METHOD_WITH_ID(_id, _comp_class_id, _x) \
694 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_init_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INIT_METHOD, _id, _comp_class_id, sink, _x)
697 * Defines a finalization method attribute attached to a specific source
698 * component class descriptor.
700 * _id: Plugin descriptor ID (C identifier).
701 * _comp_class_id: Component class descriptor ID (C identifier).
702 * _x: Finalize method (bt_component_class_source_finalize_method).
704 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
705 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD, _id, _comp_class_id, source, _x)
708 * Defines a finalization method attribute attached to a specific filter
709 * component class descriptor.
711 * _id: Plugin descriptor ID (C identifier).
712 * _comp_class_id: Component class descriptor ID (C identifier).
713 * _x: Finalize method (bt_component_class_filter_finalize_method).
715 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
716 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD, _id, _comp_class_id, filter, _x)
719 * Defines a finalization method attribute attached to a specific sink
720 * component class descriptor.
722 * _id: Plugin descriptor ID (C identifier).
723 * _comp_class_id: Component class descriptor ID (C identifier).
724 * _x: Finalize method (bt_component_class_sink_finalize_method).
726 #define BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
727 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD, _id, _comp_class_id, sink, _x)
730 * Defines a query method attribute attached to a specific source
731 * component class descriptor.
733 * _id: Plugin descriptor ID (C identifier).
734 * _comp_class_id: Component class descriptor ID (C identifier).
735 * _x: Finalize method (bt_component_class_source_query_method).
737 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(_id, _comp_class_id, _x) \
738 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_query_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD, _id, _comp_class_id, source, _x)
741 * Defines a query method attribute attached to a specific filter
742 * component class descriptor.
744 * _id: Plugin descriptor ID (C identifier).
745 * _comp_class_id: Component class descriptor ID (C identifier).
746 * _x: Finalize method (bt_component_class_filter_query_method).
748 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(_id, _comp_class_id, _x) \
749 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_query_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD, _id, _comp_class_id, filter, _x)
752 * Defines a query method attribute attached to a specific sink
753 * component class descriptor.
755 * _id: Plugin descriptor ID (C identifier).
756 * _comp_class_id: Component class descriptor ID (C identifier).
757 * _x: Finalize method (bt_component_class_sink_query_method).
759 #define BT_PLUGIN_SINK_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(_id, _comp_class_id, _x) \
760 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_query_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD, _id, _comp_class_id, sink, _x)
763 * Defines an input port connected method attribute attached to a
764 * specific filter component class descriptor.
766 * _id: Plugin descriptor ID (C identifier).
767 * _comp_class_id: Component class descriptor ID (C identifier).
768 * _x: Port connected method
769 * (bt_component_class_filter_input_port_connected_method).
771 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
772 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_input_port_connected_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD, _id, _comp_class_id, filter, _x)
775 * Defines an input port connected method attribute attached to a
776 * specific sink component class descriptor.
778 * _id: Plugin descriptor ID (C identifier).
779 * _comp_class_id: Component class descriptor ID (C identifier).
780 * _x: Port connected method
781 * (bt_component_class_sink_input_port_connected_method).
783 #define BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
784 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_input_port_connected_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD, _id, _comp_class_id, sink, _x)
787 * Defines an output port connected method attribute attached to a
788 * specific source component class descriptor.
790 * _id: Plugin descriptor ID (C identifier).
791 * _comp_class_id: Component class descriptor ID (C identifier).
792 * _x: Port connected method
793 * (bt_component_class_source_output_port_connected_method).
795 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
796 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_output_port_connected_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD, _id, _comp_class_id, source, _x)
799 * Defines an output port connected method attribute attached to a
800 * specific filter component class descriptor.
802 * _id: Plugin descriptor ID (C identifier).
803 * _comp_class_id: Component class descriptor ID (C identifier).
804 * _x: Port connected method
805 * (bt_component_class_filter_output_port_connected_method).
807 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
808 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_output_port_connected_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD, _id, _comp_class_id, filter, _x)
811 * Defines a "graph is configured" method attribute attached to a
812 * specific sink component class descriptor.
814 * _id: Plugin descriptor ID (C identifier).
815 * _comp_class_id: Component class descriptor ID (C identifier).
816 * _x: "Graph is configured" method
817 * (bt_component_class_sink_graph_is_configured_method).
819 #define BT_PLUGIN_SINK_COMPONENT_CLASS_GRAPH_IS_CONFIGURED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
820 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_graph_is_configured_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GRAPH_IS_CONFIGURED_METHOD, _id, _comp_class_id, sink, _x)
823 * Defines an iterator initialization method attribute attached to a
824 * specific source component class descriptor.
826 * _id: Plugin descriptor ID (C identifier).
827 * _comp_class_id: Component class descriptor ID (C identifier).
828 * _x: Iterator initialization method
829 * (bt_component_class_source_message_iterator_init_method).
831 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_INIT_METHOD_WITH_ID(_id, _comp_class_id, _x) \
832 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_msg_iter_init_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INIT_METHOD, _id, _comp_class_id, source, _x)
835 * Defines an iterator finalize method attribute attached to a specific
836 * source component class descriptor.
838 * _id: Plugin descriptor ID (C identifier).
839 * _comp_class_id: Component class descriptor ID (C identifier).
840 * _x: Iterator finalize method
841 * (bt_component_class_source_message_iterator_finalize_method).
843 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
844 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_msg_iter_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD, _id, _comp_class_id, source, _x)
847 * Defines an iterator "seek nanoseconds from origin" method attribute
848 * attached to a specific source component class descriptor.
850 * _id: Plugin descriptor ID (C identifier).
851 * _comp_class_id: Component class descriptor ID (C identifier).
852 * _x: Iterator "seek nanoseconds from origin" method
853 * (bt_component_class_source_message_iterator_seek_ns_from_origin_method).
855 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHOD_WITH_ID(_id, _comp_class_id, _x) \
856 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_msg_iter_seek_ns_from_origin_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD, _id, _comp_class_id, source, _x)
859 * Defines an iterator "seek beginning" method attribute attached to a
860 * specific source component class descriptor.
862 * _id: Plugin descriptor ID (C identifier).
863 * _comp_class_id: Component class descriptor ID (C identifier).
864 * _x: Iterator "seek beginning" method
865 * (bt_component_class_source_message_iterator_seek_beginning_method).
867 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHOD_WITH_ID(_id, _comp_class_id, _x) \
868 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_msg_iter_seek_beginning_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD, _id, _comp_class_id, source, _x)
871 * Defines an iterator "can seek nanoseconds from origin" method
872 * attribute attached to a specific source component class descriptor.
874 * _id: Plugin descriptor ID (C identifier).
875 * _comp_class_id: Component class descriptor ID (C identifier).
876 * _x: Iterator "can seek nanoseconds from origin" method
877 * (bt_component_class_source_message_iterator_can_seek_ns_from_origin_method).
879 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_NS_FROM_ORIGIN_METHOD_WITH_ID(_id, _comp_class_id, _x) \
880 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_msg_iter_can_seek_ns_from_origin_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD, _id, _comp_class_id, source, _x)
883 * Defines an iterator "can seek beginning" method attribute attached to a
884 * specific source component class descriptor.
886 * _id: Plugin descriptor ID (C identifier).
887 * _comp_class_id: Component class descriptor ID (C identifier).
888 * _x: Iterator "can seek beginning" method
889 * (bt_component_class_source_message_iterator_can_seek_beginning_method).
891 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_BEGINNING_METHOD_WITH_ID(_id, _comp_class_id, _x) \
892 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_msg_iter_can_seek_beginning_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD, _id, _comp_class_id, source, _x)
895 * Defines an iterator initialization method attribute attached to a
896 * specific filter component class descriptor.
898 * _id: Plugin descriptor ID (C identifier).
899 * _comp_class_id: Component class descriptor ID (C identifier).
900 * _x: Iterator initialization method
901 * (bt_component_class_filter_message_iterator_init_method).
903 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_INIT_METHOD_WITH_ID(_id, _comp_class_id, _x) \
904 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_msg_iter_init_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INIT_METHOD, _id, _comp_class_id, filter, _x)
907 * Defines an iterator finalize method attribute attached to a specific
908 * filter component class descriptor.
910 * _id: Plugin descriptor ID (C identifier).
911 * _comp_class_id: Component class descriptor ID (C identifier).
912 * _x: Iterator finalize method
913 * (bt_component_class_filter_message_iterator_finalize_method).
915 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
916 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_msg_iter_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD, _id, _comp_class_id, filter, _x)
919 * Defines an iterator "seek nanoseconds from origin" method attribute
920 * attached to a specific filter component class descriptor.
922 * _id: Plugin descriptor ID (C identifier).
923 * _comp_class_id: Component class descriptor ID (C identifier).
924 * _x: Iterator "seek nanoseconds from origin" method
925 * (bt_component_class_filter_message_iterator_seek_ns_from_origin_method).
927 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHOD_WITH_ID(_id, _comp_class_id, _x) \
928 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_msg_iter_seek_ns_from_origin_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD, _id, _comp_class_id, filter, _x)
931 * Defines an iterator "seek beginning" method attribute attached to a
932 * specific filter component class descriptor.
934 * _id: Plugin descriptor ID (C identifier).
935 * _comp_class_id: Component class descriptor ID (C identifier).
936 * _x: Iterator "seek beginning" method
937 * (bt_component_class_filter_message_iterator_seek_beginning_method).
939 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHOD_WITH_ID(_id, _comp_class_id, _x) \
940 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_msg_iter_seek_beginning_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD, _id, _comp_class_id, filter, _x)
943 * Defines an iterator "can seek nanoseconds from origin" method
944 * attribute attached to a specific filter component class descriptor.
946 * _id: Plugin descriptor ID (C identifier).
947 * _comp_class_id: Component class descriptor ID (C identifier).
948 * _x: Iterator "can seek nanoseconds from origin" method
949 * (bt_component_class_filter_message_iterator_can_seek_ns_from_origin_method).
951 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_NS_FROM_ORIGIN_METHOD_WITH_ID(_id, _comp_class_id, _x) \
952 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_msg_iter_can_seek_ns_from_origin_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD, _id, _comp_class_id, filter, _x)
955 * Defines an iterator "can seek beginning" method attribute attached to a
956 * specific filter component class descriptor.
958 * _id: Plugin descriptor ID (C identifier).
959 * _comp_class_id: Component class descriptor ID (C identifier).
960 * _x: Iterator "can seek beginning" method
961 * (bt_component_class_filter_message_iterator_can_seek_beginning_method).
963 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_BEGINNING_METHOD_WITH_ID(_id, _comp_class_id, _x) \
964 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_msg_iter_can_seek_beginning_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD, _id, _comp_class_id, filter, _x)
967 * Defines a plugin descriptor with an automatic ID.
969 * _name: Plugin's name (C string).
971 #define BT_PLUGIN(_name) static BT_PLUGIN_WITH_ID(auto, #_name)
974 * Defines a plugin initialization function attribute attached to the
975 * automatic plugin descriptor.
977 * _x: Initialization function (bt_plugin_init_func).
979 #define BT_PLUGIN_INIT(_x) BT_PLUGIN_INIT_WITH_ID(auto, _x)
982 * Defines a plugin exit function attribute attached to the automatic
985 * _x: Exit function (bt_plugin_exit_func).
987 #define BT_PLUGIN_EXIT(_x) BT_PLUGIN_EXIT_WITH_ID(auto, _x)
990 * Defines an author attribute attached to the automatic plugin
993 * _x: Author (C string).
995 #define BT_PLUGIN_AUTHOR(_x) BT_PLUGIN_AUTHOR_WITH_ID(auto, _x)
998 * Defines a license attribute attached to the automatic plugin
1001 * _x: License (C string).
1003 #define BT_PLUGIN_LICENSE(_x) BT_PLUGIN_LICENSE_WITH_ID(auto, _x)
1006 * Defines a description attribute attached to the automatic plugin
1009 * _x: Description (C string).
1011 #define BT_PLUGIN_DESCRIPTION(_x) BT_PLUGIN_DESCRIPTION_WITH_ID(auto, _x)
1014 * Defines a version attribute attached to the automatic plugin
1017 * _major: Plugin's major version (uint32_t).
1018 * _minor: Plugin's minor version (uint32_t).
1019 * _patch: Plugin's patch version (uint32_t).
1020 * _extra: Plugin's version extra information (C string).
1022 #define BT_PLUGIN_VERSION(_major, _minor, _patch, _extra) BT_PLUGIN_VERSION_WITH_ID(auto, _major, _minor, _patch, _extra)
1025 * Defines a source component class attached to the automatic plugin
1026 * descriptor. Its ID is the same as its name, hence its name must be a
1027 * C identifier in this version.
1029 * _name: Component class name (C identifier).
1030 * _msg_iter_next_method: Component class's iterator next method
1031 * (bt_component_class_source_message_iterator_next_method).
1033 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS(_name, _msg_iter_next_method) \
1034 BT_PLUGIN_SOURCE_COMPONENT_CLASS_WITH_ID(auto, _name, #_name, _msg_iter_next_method)
1037 * Defines a filter component class attached to the automatic plugin
1038 * descriptor. Its ID is the same as its name, hence its name must be a
1039 * C identifier in this version.
1041 * _name: Component class name (C identifier).
1042 * _msg_iter_next_method: Component class's iterator next method
1043 * (bt_component_class_filter_message_iterator_next_method).
1045 #define BT_PLUGIN_FILTER_COMPONENT_CLASS(_name, _msg_iter_next_method) \
1046 BT_PLUGIN_FILTER_COMPONENT_CLASS_WITH_ID(auto, _name, #_name, _msg_iter_next_method)
1049 * Defines a sink component class attached to the automatic plugin
1050 * descriptor. Its ID is the same as its name, hence its name must be a
1051 * C identifier in this version.
1053 * _name: Component class name (C identifier).
1054 * _consume_method: Component class's consume method
1055 * (bt_component_class_sink_consume_method).
1057 #define BT_PLUGIN_SINK_COMPONENT_CLASS(_name, _consume_method) \
1058 BT_PLUGIN_SINK_COMPONENT_CLASS_WITH_ID(auto, _name, #_name, _consume_method)
1061 * Defines a description attribute attached to a source component class
1062 * descriptor which is attached to the automatic plugin descriptor.
1064 * _name: Component class name (C identifier).
1065 * _x: Description (C string).
1067 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_DESCRIPTION(_name, _x) \
1068 BT_PLUGIN_SOURCE_COMPONENT_CLASS_DESCRIPTION_WITH_ID(auto, _name, _x)
1071 * Defines a description attribute attached to a filter component class
1072 * descriptor which is attached to the automatic plugin descriptor.
1074 * _name: Component class name (C identifier).
1075 * _x: Description (C string).
1077 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION(_name, _x) \
1078 BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION_WITH_ID(auto, _name, _x)
1081 * Defines a description attribute attached to a sink component class
1082 * descriptor which is attached to the automatic plugin descriptor.
1084 * _name: Component class name (C identifier).
1085 * _x: Description (C string).
1087 #define BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION(_name, _x) \
1088 BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION_WITH_ID(auto, _name, _x)
1091 * Defines a help attribute attached to a source component class
1092 * descriptor which is attached to the automatic plugin descriptor.
1094 * _name: Component class name (C identifier).
1095 * _x: Help (C string).
1097 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_HELP(_name, _x) \
1098 BT_PLUGIN_SOURCE_COMPONENT_CLASS_HELP_WITH_ID(auto, _name, _x)
1101 * Defines a help attribute attached to a filter component class
1102 * descriptor which is attached to the automatic plugin descriptor.
1104 * _name: Component class name (C identifier).
1105 * _x: Help (C string).
1107 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_HELP(_name, _x) \
1108 BT_PLUGIN_FILTER_COMPONENT_CLASS_HELP_WITH_ID(auto, _name, _x)
1111 * Defines a help attribute attached to a sink component class
1112 * descriptor which is attached to the automatic plugin descriptor.
1114 * _name: Component class name (C identifier).
1115 * _x: Help (C string).
1117 #define BT_PLUGIN_SINK_COMPONENT_CLASS_HELP(_name, _x) \
1118 BT_PLUGIN_SINK_COMPONENT_CLASS_HELP_WITH_ID(auto, _name, _x)
1121 * Defines an initialization method attribute attached to a source
1122 * component class descriptor which is attached to the automatic plugin
1125 * _name: Component class name (C identifier).
1126 * _x: Initialization method (bt_component_class_source_init_method).
1128 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_INIT_METHOD(_name, _x) \
1129 BT_PLUGIN_SOURCE_COMPONENT_CLASS_INIT_METHOD_WITH_ID(auto, _name, _x)
1132 * Defines an initialization method attribute attached to a filter
1133 * component class descriptor which is attached to the automatic plugin
1136 * _name: Component class name (C identifier).
1137 * _x: Initialization method (bt_component_class_filter_init_method).
1139 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_INIT_METHOD(_name, _x) \
1140 BT_PLUGIN_FILTER_COMPONENT_CLASS_INIT_METHOD_WITH_ID(auto, _name, _x)
1143 * Defines an initialization method attribute attached to a sink
1144 * component class descriptor which is attached to the automatic plugin
1147 * _name: Component class name (C identifier).
1148 * _x: Initialization method (bt_component_class_sink_init_method).
1150 #define BT_PLUGIN_SINK_COMPONENT_CLASS_INIT_METHOD(_name, _x) \
1151 BT_PLUGIN_SINK_COMPONENT_CLASS_INIT_METHOD_WITH_ID(auto, _name, _x)
1154 * Defines a finalization method attribute attached to a source component
1155 * class descriptor which is attached to the automatic plugin
1158 * _name: Component class name (C identifier).
1159 * _x: Initialization method (bt_component_class_source_finalize_method).
1161 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_FINALIZE_METHOD(_name, _x) \
1162 BT_PLUGIN_SOURCE_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1165 * Defines a finalization method attribute attached to a filter component
1166 * class descriptor which is attached to the automatic plugin
1169 * _name: Component class name (C identifier).
1170 * _x: Initialization method (bt_component_class_filter_finalize_method).
1172 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD(_name, _x) \
1173 BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1176 * Defines a finalization method attribute attached to a sink component class
1177 * descriptor which is attached to the automatic plugin descriptor.
1179 * _name: Component class name (C identifier).
1180 * _x: Initialization method (bt_component_class_sink_finalize_method).
1182 #define BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD(_name, _x) \
1183 BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1186 * Defines a query method attribute attached to a source component
1187 * class descriptor which is attached to the automatic plugin
1190 * _name: Component class name (C identifier).
1191 * _x: Initialization method (bt_component_class_source_query_method).
1193 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_QUERY_METHOD(_name, _x) \
1194 BT_PLUGIN_SOURCE_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(auto, _name, _x)
1197 * Defines a query method attribute attached to a filter component
1198 * class descriptor which is attached to the automatic plugin
1201 * _name: Component class name (C identifier).
1202 * _x: Initialization method (bt_component_class_filter_query_method).
1204 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_QUERY_METHOD(_name, _x) \
1205 BT_PLUGIN_FILTER_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(auto, _name, _x)
1208 * Defines a query method attribute attached to a sink component
1209 * class descriptor which is attached to the automatic plugin
1212 * _name: Component class name (C identifier).
1213 * _x: Initialization method (bt_component_class_sink_query_method).
1215 #define BT_PLUGIN_SINK_COMPONENT_CLASS_QUERY_METHOD(_name, _x) \
1216 BT_PLUGIN_SINK_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(auto, _name, _x)
1219 * Defines an input port connected method attribute attached to a filter
1220 * component class descriptor which is attached to the automatic plugin
1223 * _name: Component class name (C identifier).
1224 * _x: Port connected (bt_component_class_filter_input_port_connected_method).
1226 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD(_name, _x) \
1227 BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _x)
1230 * Defines an input port connected method attribute attached to a sink
1231 * component class descriptor which is attached to the automatic plugin
1234 * _name: Component class name (C identifier).
1235 * _x: Port connected (bt_component_class_sink_input_port_connected_method).
1237 #define BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD(_name, _x) \
1238 BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _x)
1241 * Defines an output port connected method attribute attached to a source
1242 * component class descriptor which is attached to the automatic plugin
1245 * _name: Component class name (C identifier).
1246 * _x: Port connected (bt_component_class_source_output_port_connected_method).
1248 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD(_name, _x) \
1249 BT_PLUGIN_SOURCE_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _x)
1252 * Defines an output port connected method attribute attached to a filter
1253 * component class descriptor which is attached to the automatic plugin
1256 * _name: Component class name (C identifier).
1257 * _x: Port connected (bt_component_class_filter_output_port_connected_method).
1259 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD(_name, _x) \
1260 BT_PLUGIN_FILTER_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _x)
1263 * Defines a "graph is configured" method attribute attached to
1264 * a sink component class descriptor which is attached to the automatic
1265 * plugin descriptor.
1267 * _name: Component class name (C identifier).
1268 * _x: "Graph is configured" method
1269 * (bt_component_class_sink_graph_is_configured_method).
1271 #define BT_PLUGIN_SINK_COMPONENT_CLASS_GRAPH_IS_CONFIGURED_METHOD(_name, _x) \
1272 BT_PLUGIN_SINK_COMPONENT_CLASS_GRAPH_IS_CONFIGURED_METHOD_WITH_ID(auto, _name, _x)
1275 * Defines an iterator initialization method attribute attached to a
1276 * source component class descriptor which is attached to the automatic
1277 * plugin descriptor.
1279 * _name: Component class name (C identifier).
1280 * _x: Iterator initialization method
1281 * (bt_component_class_source_message_iterator_init_method).
1283 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_INIT_METHOD(_name, _x) \
1284 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_INIT_METHOD_WITH_ID(auto, _name, _x)
1287 * Defines an iterator finalize method attribute attached to a source
1288 * component class descriptor which is attached to the automatic plugin
1291 * _name: Component class name (C identifier).
1292 * _x: Iterator finalize method
1293 * (bt_component_class_source_message_iterator_finalize_method).
1295 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD(_name, _x) \
1296 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1299 * Defines an iterator "seek nanoseconds from origin" method attribute
1300 * attached to a source component class descriptor which is attached to
1301 * the automatic plugin descriptor.
1303 * _name: Component class name (C identifier).
1304 * _x: Iterator "seek nanoseconds from origin" method
1305 * (bt_component_class_source_message_iterator_seek_ns_from_origin_method).
1307 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHOD(_name, _x) \
1308 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHOD_WITH_ID(auto, _name, _x)
1311 * Defines an iterator "seek beginning" method attribute
1312 * attached to a source component class descriptor which is attached to
1313 * the automatic plugin descriptor.
1315 * _name: Component class name (C identifier).
1316 * _x: Iterator "seek beginning" method
1317 * (bt_component_class_source_message_iterator_seek_beginning_method).
1319 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHOD(_name, _x) \
1320 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHOD_WITH_ID(auto, _name, _x)
1323 * Defines an iterator "can seek nanoseconds from origin" method
1324 * attribute attached to a source component class descriptor which is
1325 * attached to the automatic plugin descriptor.
1327 * _name: Component class name (C identifier).
1328 * _x: Iterator "can seek nanoseconds from origin" method
1329 * (bt_component_class_source_message_iterator_can_seek_ns_from_origin_method).
1331 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_NS_FROM_ORIGIN_METHOD(_name, _x) \
1332 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_NS_FROM_ORIGIN_METHOD_WITH_ID(auto, _name, _x)
1335 * Defines an iterator "can seek beginning" method attribute
1336 * attached to a source component class descriptor which is attached to
1337 * the automatic plugin descriptor.
1339 * _name: Component class name (C identifier).
1340 * _x: Iterator "can seek beginning" method
1341 * (bt_component_class_source_message_iterator_can_seek_beginning_method).
1343 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_BEGINNING_METHOD(_name, _x) \
1344 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_BEGINNING_METHOD_WITH_ID(auto, _name, _x)
1347 * Defines an iterator initialization method attribute attached to a
1348 * filter component class descriptor which is attached to the automatic
1349 * plugin descriptor.
1351 * _name: Component class name (C identifier).
1352 * _x: Iterator initialization method
1353 * (bt_component_class_filter_message_iterator_init_method).
1355 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_INIT_METHOD(_name, _x) \
1356 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_INIT_METHOD_WITH_ID(auto, _name, _x)
1359 * Defines an iterator finalize method attribute attached to a filter
1360 * component class descriptor which is attached to the automatic plugin
1363 * _name: Component class name (C identifier).
1364 * _x: Iterator finalize method
1365 * (bt_component_class_filter_message_iterator_finalize_method).
1367 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD(_name, _x) \
1368 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1371 * Defines an iterator "seek nanoseconds from origin" method attribute
1372 * attached to a filter component class descriptor which is attached to
1373 * the automatic plugin descriptor.
1375 * _name: Component class name (C identifier).
1376 * _x: Iterator "seek nanoseconds from origin" method
1377 * (bt_component_class_filter_message_iterator_seek_ns_from_origin_method).
1379 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHOD(_name, _x) \
1380 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHOD_WITH_ID(auto, _name, _x)
1383 * Defines an iterator "seek beginning" method attribute
1384 * attached to a filter component class descriptor which is attached to
1385 * the automatic plugin descriptor.
1387 * _name: Component class name (C identifier).
1388 * _x: Iterator "seek beginning" method
1389 * (bt_component_class_filter_message_iterator_seek_beginning_method).
1391 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHOD(_name, _x) \
1392 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHOD_WITH_ID(auto, _name, _x)
1395 * Defines an iterator "can seek nanoseconds from origin" method
1396 * attribute attached to a filter component class descriptor which is
1397 * attached to the automatic plugin descriptor.
1399 * _name: Component class name (C identifier).
1400 * _x: Iterator "can seek nanoseconds from origin" method
1401 * (bt_component_class_filter_message_iterator_can_seek_ns_from_origin_method).
1403 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_NS_FROM_ORIGIN_METHOD(_name, _x) \
1404 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_NS_FROM_ORIGIN_METHOD_WITH_ID(auto, _name, _x)
1407 * Defines an iterator "can seek beginning" method attribute
1408 * attached to a filter component class descriptor which is attached to
1409 * the automatic plugin descriptor.
1411 * _name: Component class name (C identifier).
1412 * _x: Iterator "can seek beginning" method
1413 * (bt_component_class_filter_message_iterator_can_seek_beginning_method).
1415 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_BEGINNING_METHOD(_name, _x) \
1416 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_CAN_SEEK_BEGINNING_METHOD_WITH_ID(auto, _name, _x)
1418 #define BT_PLUGIN_MODULE() \
1419 static struct __bt_plugin_descriptor const * const __bt_plugin_descriptor_dummy __BT_PLUGIN_DESCRIPTOR_ATTRS = NULL; \
1420 _BT_HIDDEN extern struct __bt_plugin_descriptor const *__BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL __BT_PLUGIN_DESCRIPTOR_BEGIN_EXTRA; \
1421 _BT_HIDDEN extern struct __bt_plugin_descriptor const *__BT_PLUGIN_DESCRIPTOR_END_SYMBOL __BT_PLUGIN_DESCRIPTOR_END_EXTRA; \
1423 static struct __bt_plugin_descriptor_attribute const * const __bt_plugin_descriptor_attribute_dummy __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS = NULL; \
1424 _BT_HIDDEN extern struct __bt_plugin_descriptor_attribute const *__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA; \
1425 _BT_HIDDEN extern struct __bt_plugin_descriptor_attribute const *__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_EXTRA; \
1427 static struct __bt_plugin_component_class_descriptor const * const __bt_plugin_component_class_descriptor_dummy __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS = NULL; \
1428 _BT_HIDDEN extern struct __bt_plugin_component_class_descriptor const *__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_EXTRA; \
1429 _BT_HIDDEN extern struct __bt_plugin_component_class_descriptor const *__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_EXTRA; \
1431 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; \
1432 _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; \
1433 _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; \
1435 struct __bt_plugin_descriptor const * const *__bt_get_begin_section_plugin_descriptors(void) \
1437 return &__BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL; \
1439 struct __bt_plugin_descriptor const * const *__bt_get_end_section_plugin_descriptors(void) \
1441 return &__BT_PLUGIN_DESCRIPTOR_END_SYMBOL; \
1443 struct __bt_plugin_descriptor_attribute const * const *__bt_get_begin_section_plugin_descriptor_attributes(void) \
1445 return &__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL; \
1447 struct __bt_plugin_descriptor_attribute const * const *__bt_get_end_section_plugin_descriptor_attributes(void) \
1449 return &__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL; \
1451 struct __bt_plugin_component_class_descriptor const * const *__bt_get_begin_section_component_class_descriptors(void) \
1453 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL; \
1455 struct __bt_plugin_component_class_descriptor const * const *__bt_get_end_section_component_class_descriptors(void) \
1457 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL; \
1459 struct __bt_plugin_component_class_descriptor_attribute const * const *__bt_get_begin_section_component_class_descriptor_attributes(void) \
1461 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL; \
1463 struct __bt_plugin_component_class_descriptor_attribute const * const *__bt_get_end_section_component_class_descriptor_attributes(void) \
1465 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL; \
1472 #endif /* BABELTRACE2_PLUGIN_PLUGIN_DEV_H */