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")))
53 /* Plugin initialization function type */
54 typedef enum bt_plugin_initialize_func_status
{
55 BT_PLUGIN_INITIALIZE_FUNC_STATUS_OK
= __BT_FUNC_STATUS_OK
,
56 BT_PLUGIN_INITIALIZE_FUNC_STATUS_MEMORY_ERROR
= __BT_FUNC_STATUS_MEMORY_ERROR
,
57 BT_PLUGIN_INITIALIZE_FUNC_STATUS_ERROR
= __BT_FUNC_STATUS_ERROR
,
58 } bt_plugin_initialize_func_status
;
60 typedef bt_plugin_initialize_func_status (*bt_plugin_initialize_func
)(
61 bt_self_plugin
*plugin
);
63 /* Plugin exit function type */
64 typedef void (*bt_plugin_finalize_func
)(void);
66 /* Plugin descriptor: describes a single plugin (internal use) */
67 struct __bt_plugin_descriptor
{
70 } __attribute__((packed
));
72 /* Type of a plugin attribute (internal use) */
73 enum __bt_plugin_descriptor_attribute_type
{
74 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_INIT
= 0,
75 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_EXIT
= 1,
76 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_AUTHOR
= 2,
77 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_LICENSE
= 3,
78 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION
= 4,
79 BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_VERSION
= 5,
82 /* Plugin (user) version */
83 struct __bt_plugin_descriptor_version
{
90 /* Plugin attribute (internal use) */
91 struct __bt_plugin_descriptor_attribute
{
92 /* Plugin descriptor to which to associate this attribute */
93 const struct __bt_plugin_descriptor
*plugin_descriptor
;
95 /* Name of the attribute's type for debug purposes */
96 const char *type_name
;
98 /* Attribute's type */
99 enum __bt_plugin_descriptor_attribute_type type
;
101 /* Attribute's value (depends on attribute's type) */
103 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_INIT */
104 bt_plugin_initialize_func init
;
106 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_EXIT */
107 bt_plugin_finalize_func exit
;
109 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_AUTHOR */
112 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_LICENSE */
115 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION */
116 const char *description
;
118 /* BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_VERSION */
119 struct __bt_plugin_descriptor_version version
;
121 } __attribute__((packed
));
123 /* Component class descriptor (internal use) */
124 struct __bt_plugin_component_class_descriptor
{
126 * Plugin descriptor to which to associate this component
129 const struct __bt_plugin_descriptor
*plugin_descriptor
;
131 /* Component class name */
134 /* Component class type */
135 bt_component_class_type type
;
137 /* Mandatory methods (depends on component class type) */
139 /* BT_COMPONENT_CLASS_TYPE_SOURCE */
141 bt_component_class_source_message_iterator_next_method msg_iter_next
;
144 /* BT_COMPONENT_CLASS_TYPE_FILTER */
146 bt_component_class_filter_message_iterator_next_method msg_iter_next
;
149 /* BT_COMPONENT_CLASS_TYPE_SINK */
151 bt_component_class_sink_consume_method consume
;
154 } __attribute__((packed
));
156 /* Type of a component class attribute (internal use) */
157 enum __bt_plugin_component_class_descriptor_attribute_type
{
158 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION
= 0,
159 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP
= 1,
160 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS_METHOD
= 2,
161 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD
= 3,
162 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD
= 4,
163 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD
= 5,
164 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD
= 6,
165 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD
= 7,
166 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GRAPH_IS_CONFIGURED_METHOD
= 8,
167 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INITIALIZE_METHOD
= 9,
168 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD
= 10,
169 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD
= 11,
170 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD
= 12,
171 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD
= 13,
172 BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD
= 14,
175 /* Component class attribute (internal use) */
176 struct __bt_plugin_component_class_descriptor_attribute
{
178 * Component class plugin attribute to which to associate this
179 * component class attribute.
181 const struct __bt_plugin_component_class_descriptor
*comp_class_descriptor
;
183 /* Name of the attribute's type for debug purposes */
184 const char *type_name
;
186 /* Attribute's type */
187 enum __bt_plugin_component_class_descriptor_attribute_type type
;
189 /* Attribute's value (depends on attribute's type) */
191 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION */
192 const char *description
;
194 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP */
197 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS_METHOD */
198 bt_component_class_source_get_supported_mip_versions_method source_get_supported_mip_versions_method
;
199 bt_component_class_filter_get_supported_mip_versions_method filter_get_supported_mip_versions_method
;
200 bt_component_class_sink_get_supported_mip_versions_method sink_get_supported_mip_versions_method
;
202 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD */
203 bt_component_class_source_initialize_method source_initialize_method
;
204 bt_component_class_filter_initialize_method filter_initialize_method
;
205 bt_component_class_sink_initialize_method sink_initialize_method
;
207 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD */
208 bt_component_class_source_finalize_method source_finalize_method
;
209 bt_component_class_filter_finalize_method filter_finalize_method
;
210 bt_component_class_sink_finalize_method sink_finalize_method
;
212 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD */
213 bt_component_class_source_query_method source_query_method
;
214 bt_component_class_filter_query_method filter_query_method
;
215 bt_component_class_sink_query_method sink_query_method
;
217 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INPUT_PORT_CONNECTED_METHOD */
218 bt_component_class_filter_input_port_connected_method filter_input_port_connected_method
;
219 bt_component_class_sink_input_port_connected_method sink_input_port_connected_method
;
221 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_OUTPUT_PORT_CONNECTED_METHOD */
222 bt_component_class_source_output_port_connected_method source_output_port_connected_method
;
223 bt_component_class_filter_output_port_connected_method filter_output_port_connected_method
;
225 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GRAPH_IS_CONFIGURED_METHOD */
226 bt_component_class_sink_graph_is_configured_method sink_graph_is_configured_method
;
228 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INITIALIZE_METHOD */
229 bt_component_class_source_message_iterator_initialize_method source_msg_iter_initialize_method
;
230 bt_component_class_filter_message_iterator_initialize_method filter_msg_iter_initialize_method
;
232 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_FINALIZE_METHOD */
233 bt_component_class_source_message_iterator_finalize_method source_msg_iter_finalize_method
;
234 bt_component_class_filter_message_iterator_finalize_method filter_msg_iter_finalize_method
;
236 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_NS_FROM_ORIGIN_METHOD */
237 bt_component_class_source_message_iterator_seek_ns_from_origin_method source_msg_iter_seek_ns_from_origin_method
;
238 bt_component_class_filter_message_iterator_seek_ns_from_origin_method filter_msg_iter_seek_ns_from_origin_method
;
240 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_SEEK_BEGINNING_METHOD */
241 bt_component_class_source_message_iterator_seek_beginning_method source_msg_iter_seek_beginning_method
;
242 bt_component_class_filter_message_iterator_seek_beginning_method filter_msg_iter_seek_beginning_method
;
244 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_NS_FROM_ORIGIN_METHOD */
245 bt_component_class_source_message_iterator_can_seek_ns_from_origin_method source_msg_iter_can_seek_ns_from_origin_method
;
246 bt_component_class_filter_message_iterator_can_seek_ns_from_origin_method filter_msg_iter_can_seek_ns_from_origin_method
;
248 /* BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_CAN_SEEK_BEGINNING_METHOD */
249 bt_component_class_source_message_iterator_can_seek_beginning_method source_msg_iter_can_seek_beginning_method
;
250 bt_component_class_filter_message_iterator_can_seek_beginning_method filter_msg_iter_can_seek_beginning_method
;
252 } __attribute__((packed
));
254 struct __bt_plugin_descriptor
const * const *__bt_get_begin_section_plugin_descriptors(void);
255 struct __bt_plugin_descriptor
const * const *__bt_get_end_section_plugin_descriptors(void);
256 struct __bt_plugin_descriptor_attribute
const * const *__bt_get_begin_section_plugin_descriptor_attributes(void);
257 struct __bt_plugin_descriptor_attribute
const * const *__bt_get_end_section_plugin_descriptor_attributes(void);
258 struct __bt_plugin_component_class_descriptor
const * const *__bt_get_begin_section_component_class_descriptors(void);
259 struct __bt_plugin_component_class_descriptor
const * const *__bt_get_end_section_component_class_descriptors(void);
260 struct __bt_plugin_component_class_descriptor_attribute
const * const *__bt_get_begin_section_component_class_descriptor_attributes(void);
261 struct __bt_plugin_component_class_descriptor_attribute
const * const *__bt_get_end_section_component_class_descriptor_attributes(void);
264 * Variable attributes for a plugin descriptor pointer to be added to
265 * the plugin descriptor section (internal use).
268 #define __BT_PLUGIN_DESCRIPTOR_ATTRS \
269 __attribute__((section("__DATA,btp_desc"), used))
271 #define __BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL \
272 __start___bt_plugin_descriptors
274 #define __BT_PLUGIN_DESCRIPTOR_END_SYMBOL \
275 __stop___bt_plugin_descriptors
277 #define __BT_PLUGIN_DESCRIPTOR_BEGIN_EXTRA \
278 __asm("section$start$__DATA$btp_desc")
280 #define __BT_PLUGIN_DESCRIPTOR_END_EXTRA \
281 __asm("section$end$__DATA$btp_desc")
285 #define __BT_PLUGIN_DESCRIPTOR_ATTRS \
286 __attribute__((section("__bt_plugin_descriptors"), used))
288 #define __BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL \
289 __start___bt_plugin_descriptors
291 #define __BT_PLUGIN_DESCRIPTOR_END_SYMBOL \
292 __stop___bt_plugin_descriptors
294 #define __BT_PLUGIN_DESCRIPTOR_BEGIN_EXTRA
296 #define __BT_PLUGIN_DESCRIPTOR_END_EXTRA
300 * Variable attributes for a plugin attribute pointer to be added to
301 * the plugin attribute section (internal use).
304 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS \
305 __attribute__((section("__DATA,btp_desc_att"), used))
307 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
308 __start___bt_plugin_descriptor_attributes
310 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
311 __stop___bt_plugin_descriptor_attributes
313 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA \
314 __asm("section$start$__DATA$btp_desc_att")
316 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_EXTRA \
317 __asm("section$end$__DATA$btp_desc_att")
321 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS \
322 __attribute__((section("__bt_plugin_descriptor_attributes"), used))
324 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
325 __start___bt_plugin_descriptor_attributes
327 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
328 __stop___bt_plugin_descriptor_attributes
330 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA
332 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_EXTRA
336 * Variable attributes for a component class descriptor pointer to be
337 * added to the component class descriptor section (internal use).
340 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS \
341 __attribute__((section("__DATA,btp_cc_desc"), used))
343 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL \
344 __start___bt_plugin_component_class_descriptors
346 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL \
347 __stop___bt_plugin_component_class_descriptors
349 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_EXTRA \
350 __asm("section$start$__DATA$btp_cc_desc")
352 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_EXTRA \
353 __asm("section$end$__DATA$btp_cc_desc")
357 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS \
358 __attribute__((section("__bt_plugin_component_class_descriptors"), used))
360 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL \
361 __start___bt_plugin_component_class_descriptors
363 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL \
364 __stop___bt_plugin_component_class_descriptors
366 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_EXTRA
368 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_EXTRA
372 * Variable attributes for a component class descriptor attribute
373 * pointer to be added to the component class descriptor attribute
374 * section (internal use).
377 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_ATTRS \
378 __attribute__((section("__DATA,btp_cc_desc_att"), used))
380 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
381 __start___bt_plugin_component_class_descriptor_attributes
383 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
384 __stop___bt_plugin_component_class_descriptor_attributes
386 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA \
387 __asm("section$start$__DATA$btp_cc_desc_att")
389 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_EXTRA \
390 __asm("section$end$__DATA$btp_cc_desc_att")
394 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_ATTRS \
395 __attribute__((section("__bt_plugin_component_class_descriptor_attributes"), used))
397 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL \
398 __start___bt_plugin_component_class_descriptor_attributes
400 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL \
401 __stop___bt_plugin_component_class_descriptor_attributes
403 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA
405 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_EXTRA
409 * Declares a plugin descriptor pointer variable with a custom ID.
411 * _id: ID (any valid C identifier except `auto`).
413 #define BT_PLUGIN_DECLARE(_id) extern struct __bt_plugin_descriptor __bt_plugin_descriptor_##_id
416 * Defines a plugin descriptor with a custom ID.
418 * _id: ID (any valid C identifier except `auto`).
419 * _name: Plugin's name (C string).
421 #define BT_PLUGIN_WITH_ID(_id, _name) \
422 struct __bt_plugin_descriptor __bt_plugin_descriptor_##_id = { \
425 static struct __bt_plugin_descriptor const * const __bt_plugin_descriptor_##_id##_ptr __BT_PLUGIN_DESCRIPTOR_ATTRS = &__bt_plugin_descriptor_##_id
428 * Defines a plugin attribute (generic, internal use).
430 * _attr_name: Name of the attribute (C identifier).
431 * _attr_type: Type of the attribute (enum __bt_plugin_descriptor_attribute_type).
432 * _id: Plugin descriptor ID (C identifier).
435 #define __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(_attr_name, _attr_type, _id, _x) \
436 static struct __bt_plugin_descriptor_attribute __bt_plugin_descriptor_attribute_##_id##_##_attr_name = { \
437 .plugin_descriptor = &__bt_plugin_descriptor_##_id, \
438 .type_name = #_attr_name, \
439 .type = _attr_type, \
440 .value = { ._attr_name = _x }, \
442 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
445 * Defines a plugin initialization function attribute attached to a
446 * specific plugin descriptor.
448 * _id: Plugin descriptor ID (C identifier).
449 * _x: Initialization function (bt_plugin_initialize_func).
451 #define BT_PLUGIN_INITIALIZE_WITH_ID(_id, _x) \
452 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(init, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_INIT, _id, _x)
455 * Defines a plugin exit function attribute attached to a specific
458 * _id: Plugin descriptor ID (C identifier).
459 * _x: Exit function (bt_plugin_finalize_func).
461 #define BT_PLUGIN_FINALIZE_WITH_ID(_id, _x) \
462 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(exit, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_EXIT, _id, _x)
465 * Defines an author attribute attached to a specific plugin descriptor.
467 * _id: Plugin descriptor ID (C identifier).
468 * _x: Author (C string).
470 #define BT_PLUGIN_AUTHOR_WITH_ID(_id, _x) \
471 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(author, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_AUTHOR, _id, _x)
474 * Defines a license attribute attached to a specific plugin descriptor.
476 * _id: Plugin descriptor ID (C identifier).
477 * _x: License (C string).
479 #define BT_PLUGIN_LICENSE_WITH_ID(_id, _x) \
480 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(license, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_LICENSE, _id, _x)
483 * Defines a description attribute attached to a specific plugin
486 * _id: Plugin descriptor ID (C identifier).
487 * _x: Description (C string).
489 #define BT_PLUGIN_DESCRIPTION_WITH_ID(_id, _x) \
490 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _id, _x)
492 #define __BT_PLUGIN_VERSION_STRUCT_VALUE(_major, _minor, _patch, _extra) \
493 {.major = _major, .minor = _minor, .patch = _patch, .extra = _extra,}
496 * Defines a version attribute attached to a specific plugin descriptor.
498 * _id: Plugin descriptor ID (C identifier).
499 * _major: Plugin's major version (uint32_t).
500 * _minor: Plugin's minor version (uint32_t).
501 * _patch: Plugin's patch version (uint32_t).
502 * _extra: Plugin's version extra information (C string).
504 #define BT_PLUGIN_VERSION_WITH_ID(_id, _major, _minor, _patch, _extra) \
505 __BT_PLUGIN_DESCRIPTOR_ATTRIBUTE(version, BT_PLUGIN_DESCRIPTOR_ATTRIBUTE_TYPE_VERSION, _id, __BT_PLUGIN_VERSION_STRUCT_VALUE(_major, _minor, _patch, _extra))
508 * Defines a source component class descriptor with a custom ID.
510 * _id: ID (any valid C identifier except `auto`).
511 * _comp_class_id: Component class ID (C identifier).
512 * _name: Component class name (C string).
513 * _msg_iter_next_method: Component class's iterator next method
514 * (bt_component_class_source_message_iterator_next_method).
516 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_WITH_ID(_id, _comp_class_id, _name, _msg_iter_next_method) \
517 static struct __bt_plugin_component_class_descriptor __bt_plugin_source_component_class_descriptor_##_id##_##_comp_class_id = { \
518 .plugin_descriptor = &__bt_plugin_descriptor_##_id, \
520 .type = BT_COMPONENT_CLASS_TYPE_SOURCE, \
521 .methods = { .source = { .msg_iter_next = _msg_iter_next_method } }, \
523 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
526 * Defines a filter component class descriptor with a custom ID.
528 * _id: ID (any valid C identifier except `auto`).
529 * _comp_class_id: Component class ID (C identifier).
530 * _name: Component class name (C string).
531 * _msg_iter_next_method: Component class's iterator next method
532 * (bt_component_class_filter_message_iterator_next_method).
534 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_WITH_ID(_id, _comp_class_id, _name, _msg_iter_next_method) \
535 static struct __bt_plugin_component_class_descriptor __bt_plugin_filter_component_class_descriptor_##_id##_##_comp_class_id = { \
536 .plugin_descriptor = &__bt_plugin_descriptor_##_id, \
538 .type = BT_COMPONENT_CLASS_TYPE_FILTER, \
539 .methods = { .filter = { .msg_iter_next = _msg_iter_next_method } }, \
541 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
544 * Defines a sink component class descriptor with a custom ID.
546 * _id: ID (any valid C identifier except `auto`).
547 * _comp_class_id: Component class ID (C identifier).
548 * _name: Component class name (C string).
549 * _consume_method: Component class's iterator consume method
550 * (bt_component_class_sink_consume_method).
552 #define BT_PLUGIN_SINK_COMPONENT_CLASS_WITH_ID(_id, _comp_class_id, _name, _consume_method) \
553 static struct __bt_plugin_component_class_descriptor __bt_plugin_sink_component_class_descriptor_##_id##_##_comp_class_id = { \
554 .plugin_descriptor = &__bt_plugin_descriptor_##_id, \
556 .type = BT_COMPONENT_CLASS_TYPE_SINK, \
557 .methods = { .sink = { .consume = _consume_method } }, \
559 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
562 * Defines a component class descriptor attribute (generic, internal
565 * _id: Plugin descriptor ID (C identifier).
566 * _comp_class_id: Component class ID (C identifier).
567 * _type: Component class type (`source`, `filter`, or `sink`).
568 * _attr_name: Name of the attribute (C identifier).
569 * _attr_type: Type of the attribute
570 * (enum __bt_plugin_descriptor_attribute_type).
573 #define __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(_attr_name, _attr_type, _id, _comp_class_id, _type, _x) \
574 static struct __bt_plugin_component_class_descriptor_attribute __bt_plugin_##_type##_component_class_descriptor_attribute_##_id##_##_comp_class_id##_##_attr_name = { \
575 .comp_class_descriptor = &__bt_plugin_##_type##_component_class_descriptor_##_id##_##_comp_class_id, \
576 .type_name = #_attr_name, \
577 .type = _attr_type, \
578 .value = { ._attr_name = _x }, \
580 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
583 * Defines a description attribute attached to a specific source
584 * component class descriptor.
586 * _id: Plugin descriptor ID (C identifier).
587 * _comp_class_id: Component class descriptor ID (C identifier).
588 * _x: Description (C string).
590 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_DESCRIPTION_WITH_ID(_id, _comp_class_id, _x) \
591 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _id, _comp_class_id, source, _x)
594 * Defines a description attribute attached to a specific filter
595 * component class descriptor.
597 * _id: Plugin descriptor ID (C identifier).
598 * _comp_class_id: Component class descriptor ID (C identifier).
599 * _x: Description (C string).
601 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION_WITH_ID(_id, _comp_class_id, _x) \
602 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _id, _comp_class_id, filter, _x)
605 * Defines a description attribute attached to a specific sink
606 * component class descriptor.
608 * _id: Plugin descriptor ID (C identifier).
609 * _comp_class_id: Component class descriptor ID (C identifier).
610 * _x: Description (C string).
612 #define BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION_WITH_ID(_id, _comp_class_id, _x) \
613 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(description, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_DESCRIPTION, _id, _comp_class_id, sink, _x)
616 * Defines a help attribute attached to a specific source component
619 * _id: Plugin descriptor ID (C identifier).
620 * _comp_class_id: Component class descriptor ID (C identifier).
621 * _x: Help (C string).
623 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_HELP_WITH_ID(_id, _comp_class_id, _x) \
624 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(help, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP, _id, _comp_class_id, source, _x)
627 * Defines a help attribute attached to a specific filter component
630 * _id: Plugin descriptor ID (C identifier).
631 * _comp_class_id: Component class descriptor ID (C identifier).
632 * _x: Help (C string).
634 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_HELP_WITH_ID(_id, _comp_class_id, _x) \
635 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(help, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP, _id, _comp_class_id, filter, _x)
638 * Defines a help attribute attached to a specific sink component class
641 * _id: Plugin descriptor ID (C identifier).
642 * _comp_class_id: Component class descriptor ID (C identifier).
643 * _x: Help (C string).
645 #define BT_PLUGIN_SINK_COMPONENT_CLASS_HELP_WITH_ID(_id, _comp_class_id, _x) \
646 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(help, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_HELP, _id, _comp_class_id, sink, _x)
649 * Defines an initialization method attribute attached to a specific
650 * source component class descriptor.
652 * _id: Plugin descriptor ID (C identifier).
653 * _comp_class_id: Component class descriptor ID (C identifier).
654 * _x: Initialization method (bt_component_class_source_initialize_method).
656 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
657 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD, _id, _comp_class_id, source, _x)
660 * Defines an initialization method attribute attached to a specific
661 * filter component class descriptor.
663 * _id: Plugin descriptor ID (C identifier).
664 * _comp_class_id: Component class descriptor ID (C identifier).
665 * _x: Initialization method (bt_component_class_filter_initialize_method).
667 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
668 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD, _id, _comp_class_id, filter, _x)
671 * Defines an initialization method attribute attached to a specific
672 * sink component class descriptor.
674 * _id: Plugin descriptor ID (C identifier).
675 * _comp_class_id: Component class descriptor ID (C identifier).
676 * _x: Initialization method (bt_component_class_sink_initialize_method).
678 #define BT_PLUGIN_SINK_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
679 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_INITIALIZE_METHOD, _id, _comp_class_id, sink, _x)
682 * Defines a "get supported MIP versions" attribute attached to a
683 * specific source component class descriptor.
685 * _id: Plugin descriptor ID (C identifier).
686 * _comp_class_id: Component class descriptor ID (C identifier).
687 * _x: "Get supported MIP versions" method (bt_component_class_source_get_supported_mip_versions_method).
689 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_WITH_ID(_id, _comp_class_id, _x) \
690 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_get_supported_mip_versions_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS, _id, _comp_class_id, source, _x)
693 * Defines a "get supported MIP versions" attribute attached to a
694 * specific filter component class descriptor.
696 * _id: Plugin descriptor ID (C identifier).
697 * _comp_class_id: Component class descriptor ID (C identifier).
698 * _x: "Get supported MIP versions" method (bt_component_class_filter_get_supported_mip_versions_method).
700 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_WITH_ID(_id, _comp_class_id, _x) \
701 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_get_supported_mip_versions_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS, _id, _comp_class_id, filter, _x)
704 * Defines a "get supported MIP versions" attribute attached to a
705 * specific sink component class descriptor.
707 * _id: Plugin descriptor ID (C identifier).
708 * _comp_class_id: Component class descriptor ID (C identifier).
709 * _x: "Get supported MIP versions" method (bt_component_class_sink_get_supported_mip_versions_method).
711 #define BT_PLUGIN_SINK_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_WITH_ID(_id, _comp_class_id, _x) \
712 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_get_supported_mip_versions_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_GET_SUPPORTED_MIP_VERSIONS, _id, _comp_class_id, sink, _x)
715 * Defines a finalization method attribute attached to a specific source
716 * component class descriptor.
718 * _id: Plugin descriptor ID (C identifier).
719 * _comp_class_id: Component class descriptor ID (C identifier).
720 * _x: Finalize method (bt_component_class_source_finalize_method).
722 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
723 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD, _id, _comp_class_id, source, _x)
726 * Defines a finalization method attribute attached to a specific filter
727 * component class descriptor.
729 * _id: Plugin descriptor ID (C identifier).
730 * _comp_class_id: Component class descriptor ID (C identifier).
731 * _x: Finalize method (bt_component_class_filter_finalize_method).
733 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
734 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD, _id, _comp_class_id, filter, _x)
737 * Defines a finalization method attribute attached to a specific sink
738 * component class descriptor.
740 * _id: Plugin descriptor ID (C identifier).
741 * _comp_class_id: Component class descriptor ID (C identifier).
742 * _x: Finalize method (bt_component_class_sink_finalize_method).
744 #define BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
745 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_finalize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_FINALIZE_METHOD, _id, _comp_class_id, sink, _x)
748 * Defines a query method attribute attached to a specific source
749 * component class descriptor.
751 * _id: Plugin descriptor ID (C identifier).
752 * _comp_class_id: Component class descriptor ID (C identifier).
753 * _x: Finalize method (bt_component_class_source_query_method).
755 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(_id, _comp_class_id, _x) \
756 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_query_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD, _id, _comp_class_id, source, _x)
759 * Defines a query method attribute attached to a specific filter
760 * component class descriptor.
762 * _id: Plugin descriptor ID (C identifier).
763 * _comp_class_id: Component class descriptor ID (C identifier).
764 * _x: Finalize method (bt_component_class_filter_query_method).
766 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(_id, _comp_class_id, _x) \
767 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_query_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD, _id, _comp_class_id, filter, _x)
770 * Defines a query method attribute attached to a specific sink
771 * component class descriptor.
773 * _id: Plugin descriptor ID (C identifier).
774 * _comp_class_id: Component class descriptor ID (C identifier).
775 * _x: Finalize method (bt_component_class_sink_query_method).
777 #define BT_PLUGIN_SINK_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(_id, _comp_class_id, _x) \
778 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(sink_query_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_QUERY_METHOD, _id, _comp_class_id, sink, _x)
781 * Defines an input port connected method attribute attached to a
782 * specific filter component class descriptor.
784 * _id: Plugin descriptor ID (C identifier).
785 * _comp_class_id: Component class descriptor ID (C identifier).
786 * _x: Port connected method
787 * (bt_component_class_filter_input_port_connected_method).
789 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
790 __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)
793 * Defines an input port connected method attribute attached to a
794 * specific sink component class descriptor.
796 * _id: Plugin descriptor ID (C identifier).
797 * _comp_class_id: Component class descriptor ID (C identifier).
798 * _x: Port connected method
799 * (bt_component_class_sink_input_port_connected_method).
801 #define BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
802 __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)
805 * Defines an output port connected method attribute attached to a
806 * specific source component class descriptor.
808 * _id: Plugin descriptor ID (C identifier).
809 * _comp_class_id: Component class descriptor ID (C identifier).
810 * _x: Port connected method
811 * (bt_component_class_source_output_port_connected_method).
813 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
814 __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)
817 * Defines an output port connected method attribute attached to a
818 * specific filter component class descriptor.
820 * _id: Plugin descriptor ID (C identifier).
821 * _comp_class_id: Component class descriptor ID (C identifier).
822 * _x: Port connected method
823 * (bt_component_class_filter_output_port_connected_method).
825 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
826 __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)
829 * Defines a "graph is configured" method attribute attached to a
830 * specific sink component class descriptor.
832 * _id: Plugin descriptor ID (C identifier).
833 * _comp_class_id: Component class descriptor ID (C identifier).
834 * _x: "Graph is configured" method
835 * (bt_component_class_sink_graph_is_configured_method).
837 #define BT_PLUGIN_SINK_COMPONENT_CLASS_GRAPH_IS_CONFIGURED_METHOD_WITH_ID(_id, _comp_class_id, _x) \
838 __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)
841 * Defines an iterator initialization method attribute attached to a
842 * specific source component class descriptor.
844 * _id: Plugin descriptor ID (C identifier).
845 * _comp_class_id: Component class descriptor ID (C identifier).
846 * _x: Iterator initialization method
847 * (bt_component_class_source_message_iterator_initialize_method).
849 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_INITIALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
850 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(source_msg_iter_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INITIALIZE_METHOD, _id, _comp_class_id, source, _x)
853 * Defines an iterator finalize method attribute attached to a specific
854 * source component class descriptor.
856 * _id: Plugin descriptor ID (C identifier).
857 * _comp_class_id: Component class descriptor ID (C identifier).
858 * _x: Iterator finalize method
859 * (bt_component_class_source_message_iterator_finalize_method).
861 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
862 __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)
865 * Defines an iterator "seek nanoseconds from origin" and "can seek nanoseconds
866 * from origin" method attributes attached to a specific source component class
869 * _id: Plugin descriptor ID (C identifier).
870 * _comp_class_id: Component class descriptor ID (C identifier).
871 * _seek_method: Iterator "seek nanoseconds from origin" method
872 * (bt_component_class_source_message_iterator_seek_ns_from_origin_method).
873 * _can_seek_method: Iterator "can seek nanoseconds from origin" method
874 * (bt_component_class_source_message_iterator_can_seek_ns_from_origin_method).
876 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHODS_WITH_ID(_id, _comp_class_id, _seek_method, _can_seek_method) \
877 __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, _seek_method); \
878 __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, _can_seek_method)
881 * Defines an iterator "seek beginning" and "can seek beginning" method
882 * attributes attached to a specific source component class descriptor.
884 * _id: Plugin descriptor ID (C identifier).
885 * _comp_class_id: Component class descriptor ID (C identifier).
886 * _seek_method: Iterator "seek beginning" method
887 * (bt_component_class_source_message_iterator_seek_beginning_method).
888 * _can_seek_method: 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_SEEK_BEGINNING_METHODS_WITH_ID(_id, _comp_class_id, _seek_method, _can_seek_method) \
892 __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, _seek_method); \
893 __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, _can_seek_method)
896 * Defines an iterator initialization method attribute attached to a
897 * specific filter component class descriptor.
899 * _id: Plugin descriptor ID (C identifier).
900 * _comp_class_id: Component class descriptor ID (C identifier).
901 * _x: Iterator initialization method
902 * (bt_component_class_filter_message_iterator_initialize_method).
904 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_INITIALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
905 __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE(filter_msg_iter_initialize_method, BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTE_TYPE_MSG_ITER_INITIALIZE_METHOD, _id, _comp_class_id, filter, _x)
908 * Defines an iterator finalize method attribute attached to a specific
909 * filter component class descriptor.
911 * _id: Plugin descriptor ID (C identifier).
912 * _comp_class_id: Component class descriptor ID (C identifier).
913 * _x: Iterator finalize method
914 * (bt_component_class_filter_message_iterator_finalize_method).
916 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD_WITH_ID(_id, _comp_class_id, _x) \
917 __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)
920 * Defines an iterator "seek nanoseconds" and "can seek nanoseconds from origin"
921 * method attributes attached to a specific filter component class descriptor.
923 * _id: Plugin descriptor ID (C identifier).
924 * _comp_class_id: Component class descriptor ID (C identifier).
925 * _seek_method: Iterator "seek nanoseconds from origin" method
926 * (bt_component_class_filter_message_iterator_seek_ns_from_origin_method).
927 * _can_seek_method: Iterator "can seek nanoseconds from origin" method
928 * (bt_component_class_filter_message_iterator_can_seek_ns_from_origin_method).
930 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHODS_WITH_ID(_id, _comp_class_id, _seek_method, _can_seek_method) \
931 __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, _seek_method); \
932 __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, _can_seek_method)
935 * Defines an iterator "seek beginning" and "can seek beginning" method
936 * attributes attached to a specific filter component class descriptor.
938 * _id: Plugin descriptor ID (C identifier).
939 * _comp_class_id: Component class descriptor ID (C identifier).
940 * _seek_method: Iterator "seek beginning" method
941 * (bt_component_class_filter_message_iterator_seek_beginning_method).
942 * _can_seek_method: Iterator "can seek beginning" method
943 * (bt_component_class_filter_message_iterator_can_seek_beginning_method).
945 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHODS_WITH_ID(_id, _comp_class_id, _seek_method, _can_seek_method) \
946 __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, _seek_method); \
947 __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, _can_seek_method);
950 * Defines a plugin descriptor with an automatic ID.
952 * _name: Plugin's name (C string).
954 #define BT_PLUGIN(_name) static BT_PLUGIN_WITH_ID(auto, #_name)
957 * Defines a plugin initialization function attribute attached to the
958 * automatic plugin descriptor.
960 * _x: Initialization function (bt_plugin_initialize_func).
962 #define BT_PLUGIN_INITIALIZE(_x) BT_PLUGIN_INITIALIZE_WITH_ID(auto, _x)
965 * Defines a plugin exit function attribute attached to the automatic
968 * _x: Exit function (bt_plugin_finalize_func).
970 #define BT_PLUGIN_FINALIZE(_x) BT_PLUGIN_FINALIZE_WITH_ID(auto, _x)
973 * Defines an author attribute attached to the automatic plugin
976 * _x: Author (C string).
978 #define BT_PLUGIN_AUTHOR(_x) BT_PLUGIN_AUTHOR_WITH_ID(auto, _x)
981 * Defines a license attribute attached to the automatic plugin
984 * _x: License (C string).
986 #define BT_PLUGIN_LICENSE(_x) BT_PLUGIN_LICENSE_WITH_ID(auto, _x)
989 * Defines a description attribute attached to the automatic plugin
992 * _x: Description (C string).
994 #define BT_PLUGIN_DESCRIPTION(_x) BT_PLUGIN_DESCRIPTION_WITH_ID(auto, _x)
997 * Defines a version attribute attached to the automatic plugin
1000 * _major: Plugin's major version (uint32_t).
1001 * _minor: Plugin's minor version (uint32_t).
1002 * _patch: Plugin's patch version (uint32_t).
1003 * _extra: Plugin's version extra information (C string).
1005 #define BT_PLUGIN_VERSION(_major, _minor, _patch, _extra) BT_PLUGIN_VERSION_WITH_ID(auto, _major, _minor, _patch, _extra)
1008 * Defines a source component class attached to the automatic plugin
1009 * descriptor. Its ID is the same as its name, hence its name must be a
1010 * C identifier in this version.
1012 * _name: Component class name (C identifier).
1013 * _msg_iter_next_method: Component class's iterator next method
1014 * (bt_component_class_source_message_iterator_next_method).
1016 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS(_name, _msg_iter_next_method) \
1017 BT_PLUGIN_SOURCE_COMPONENT_CLASS_WITH_ID(auto, _name, #_name, _msg_iter_next_method)
1020 * Defines a filter component class attached to the automatic plugin
1021 * descriptor. Its ID is the same as its name, hence its name must be a
1022 * C identifier in this version.
1024 * _name: Component class name (C identifier).
1025 * _msg_iter_next_method: Component class's iterator next method
1026 * (bt_component_class_filter_message_iterator_next_method).
1028 #define BT_PLUGIN_FILTER_COMPONENT_CLASS(_name, _msg_iter_next_method) \
1029 BT_PLUGIN_FILTER_COMPONENT_CLASS_WITH_ID(auto, _name, #_name, _msg_iter_next_method)
1032 * Defines a sink component class attached to the automatic plugin
1033 * descriptor. Its ID is the same as its name, hence its name must be a
1034 * C identifier in this version.
1036 * _name: Component class name (C identifier).
1037 * _consume_method: Component class's consume method
1038 * (bt_component_class_sink_consume_method).
1040 #define BT_PLUGIN_SINK_COMPONENT_CLASS(_name, _consume_method) \
1041 BT_PLUGIN_SINK_COMPONENT_CLASS_WITH_ID(auto, _name, #_name, _consume_method)
1044 * Defines a description attribute attached to a source component class
1045 * descriptor which is attached to the automatic plugin descriptor.
1047 * _name: Component class name (C identifier).
1048 * _x: Description (C string).
1050 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_DESCRIPTION(_name, _x) \
1051 BT_PLUGIN_SOURCE_COMPONENT_CLASS_DESCRIPTION_WITH_ID(auto, _name, _x)
1054 * Defines a description attribute attached to a filter component class
1055 * descriptor which is attached to the automatic plugin descriptor.
1057 * _name: Component class name (C identifier).
1058 * _x: Description (C string).
1060 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION(_name, _x) \
1061 BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION_WITH_ID(auto, _name, _x)
1064 * Defines a description attribute attached to a sink component class
1065 * descriptor which is attached to the automatic plugin descriptor.
1067 * _name: Component class name (C identifier).
1068 * _x: Description (C string).
1070 #define BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION(_name, _x) \
1071 BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION_WITH_ID(auto, _name, _x)
1074 * Defines a help attribute attached to a source component class
1075 * descriptor which is attached to the automatic plugin descriptor.
1077 * _name: Component class name (C identifier).
1078 * _x: Help (C string).
1080 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_HELP(_name, _x) \
1081 BT_PLUGIN_SOURCE_COMPONENT_CLASS_HELP_WITH_ID(auto, _name, _x)
1084 * Defines a help attribute attached to a filter component class
1085 * descriptor which is attached to the automatic plugin descriptor.
1087 * _name: Component class name (C identifier).
1088 * _x: Help (C string).
1090 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_HELP(_name, _x) \
1091 BT_PLUGIN_FILTER_COMPONENT_CLASS_HELP_WITH_ID(auto, _name, _x)
1094 * Defines a help attribute attached to a sink component class
1095 * descriptor which is attached to the automatic plugin descriptor.
1097 * _name: Component class name (C identifier).
1098 * _x: Help (C string).
1100 #define BT_PLUGIN_SINK_COMPONENT_CLASS_HELP(_name, _x) \
1101 BT_PLUGIN_SINK_COMPONENT_CLASS_HELP_WITH_ID(auto, _name, _x)
1104 * Defines an initialization method attribute attached to a source
1105 * component class descriptor which is attached to the automatic plugin
1108 * _name: Component class name (C identifier).
1109 * _x: Initialization method (bt_component_class_source_initialize_method).
1111 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_INITIALIZE_METHOD(_name, _x) \
1112 BT_PLUGIN_SOURCE_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(auto, _name, _x)
1115 * Defines an initialization method attribute attached to a filter
1116 * component class descriptor which is attached to the automatic plugin
1119 * _name: Component class name (C identifier).
1120 * _x: Initialization method (bt_component_class_filter_initialize_method).
1122 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_INITIALIZE_METHOD(_name, _x) \
1123 BT_PLUGIN_FILTER_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(auto, _name, _x)
1126 * Defines an initialization method attribute attached to a sink
1127 * component class descriptor which is attached to the automatic plugin
1130 * _name: Component class name (C identifier).
1131 * _x: Initialization method (bt_component_class_sink_initialize_method).
1133 #define BT_PLUGIN_SINK_COMPONENT_CLASS_INITIALIZE_METHOD(_name, _x) \
1134 BT_PLUGIN_SINK_COMPONENT_CLASS_INITIALIZE_METHOD_WITH_ID(auto, _name, _x)
1137 * Defines a "get supported MIP versions" method attribute attached to a
1138 * source component class descriptor which is attached to the automatic
1139 * plugin descriptor.
1141 * _name: Component class name (C identifier).
1142 * _x: Initialization method (bt_component_class_source_get_supported_mip_versions_method).
1144 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD(_name, _x) \
1145 BT_PLUGIN_SOURCE_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_WITH_ID(auto, _name, _x)
1148 * Defines a "get supported MIP versions" method attribute attached to a
1149 * filter component class descriptor which is attached to the automatic
1150 * plugin descriptor.
1152 * _name: Component class name (C identifier).
1153 * _x: Initialization method (bt_component_class_filter_get_supported_mip_versions_method).
1155 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD(_name, _x) \
1156 BT_PLUGIN_FILTER_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_WITH_ID(auto, _name, _x)
1159 * Defines a "get supported MIP versions" method attribute attached to a
1160 * sink component class descriptor which is attached to the automatic
1161 * plugin descriptor.
1163 * _name: Component class name (C identifier).
1164 * _x: Initialization method (bt_component_class_sink_get_supported_mip_versions_method).
1166 #define BT_PLUGIN_SINK_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD(_name, _x) \
1167 BT_PLUGIN_SINK_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_WITH_ID(auto, _name, _x)
1170 * Defines a finalization method attribute attached to a source component
1171 * class descriptor which is attached to the automatic plugin
1174 * _name: Component class name (C identifier).
1175 * _x: Initialization method (bt_component_class_source_finalize_method).
1177 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_FINALIZE_METHOD(_name, _x) \
1178 BT_PLUGIN_SOURCE_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1181 * Defines a finalization method attribute attached to a filter component
1182 * class descriptor which is attached to the automatic plugin
1185 * _name: Component class name (C identifier).
1186 * _x: Initialization method (bt_component_class_filter_finalize_method).
1188 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD(_name, _x) \
1189 BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1192 * Defines a finalization method attribute attached to a sink component class
1193 * descriptor which is attached to the automatic plugin descriptor.
1195 * _name: Component class name (C identifier).
1196 * _x: Initialization method (bt_component_class_sink_finalize_method).
1198 #define BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD(_name, _x) \
1199 BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1202 * Defines a query method attribute attached to a source component
1203 * class descriptor which is attached to the automatic plugin
1206 * _name: Component class name (C identifier).
1207 * _x: Initialization method (bt_component_class_source_query_method).
1209 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_QUERY_METHOD(_name, _x) \
1210 BT_PLUGIN_SOURCE_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(auto, _name, _x)
1213 * Defines a query method attribute attached to a filter component
1214 * class descriptor which is attached to the automatic plugin
1217 * _name: Component class name (C identifier).
1218 * _x: Initialization method (bt_component_class_filter_query_method).
1220 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_QUERY_METHOD(_name, _x) \
1221 BT_PLUGIN_FILTER_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(auto, _name, _x)
1224 * Defines a query method attribute attached to a sink component
1225 * class descriptor which is attached to the automatic plugin
1228 * _name: Component class name (C identifier).
1229 * _x: Initialization method (bt_component_class_sink_query_method).
1231 #define BT_PLUGIN_SINK_COMPONENT_CLASS_QUERY_METHOD(_name, _x) \
1232 BT_PLUGIN_SINK_COMPONENT_CLASS_QUERY_METHOD_WITH_ID(auto, _name, _x)
1235 * Defines an input port connected method attribute attached to a filter
1236 * component class descriptor which is attached to the automatic plugin
1239 * _name: Component class name (C identifier).
1240 * _x: Port connected (bt_component_class_filter_input_port_connected_method).
1242 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD(_name, _x) \
1243 BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _x)
1246 * Defines an input port connected method attribute attached to a sink
1247 * component class descriptor which is attached to the automatic plugin
1250 * _name: Component class name (C identifier).
1251 * _x: Port connected (bt_component_class_sink_input_port_connected_method).
1253 #define BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD(_name, _x) \
1254 BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _x)
1257 * Defines an output port connected method attribute attached to a source
1258 * component class descriptor which is attached to the automatic plugin
1261 * _name: Component class name (C identifier).
1262 * _x: Port connected (bt_component_class_source_output_port_connected_method).
1264 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD(_name, _x) \
1265 BT_PLUGIN_SOURCE_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _x)
1268 * Defines an output port connected method attribute attached to a filter
1269 * component class descriptor which is attached to the automatic plugin
1272 * _name: Component class name (C identifier).
1273 * _x: Port connected (bt_component_class_filter_output_port_connected_method).
1275 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD(_name, _x) \
1276 BT_PLUGIN_FILTER_COMPONENT_CLASS_OUTPUT_PORT_CONNECTED_METHOD_WITH_ID(auto, _name, _x)
1279 * Defines a "graph is configured" method attribute attached to
1280 * a sink component class descriptor which is attached to the automatic
1281 * plugin descriptor.
1283 * _name: Component class name (C identifier).
1284 * _x: "Graph is configured" method
1285 * (bt_component_class_sink_graph_is_configured_method).
1287 #define BT_PLUGIN_SINK_COMPONENT_CLASS_GRAPH_IS_CONFIGURED_METHOD(_name, _x) \
1288 BT_PLUGIN_SINK_COMPONENT_CLASS_GRAPH_IS_CONFIGURED_METHOD_WITH_ID(auto, _name, _x)
1291 * Defines an iterator initialization method attribute attached to a
1292 * source component class descriptor which is attached to the automatic
1293 * plugin descriptor.
1295 * _name: Component class name (C identifier).
1296 * _x: Iterator initialization method
1297 * (bt_component_class_source_message_iterator_initialize_method).
1299 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_INITIALIZE_METHOD(_name, _x) \
1300 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_INITIALIZE_METHOD_WITH_ID(auto, _name, _x)
1303 * Defines an iterator finalize method attribute attached to a source
1304 * component class descriptor which is attached to the automatic plugin
1307 * _name: Component class name (C identifier).
1308 * _x: Iterator finalize method
1309 * (bt_component_class_source_message_iterator_finalize_method).
1311 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD(_name, _x) \
1312 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1315 * Defines an iterator "seek nanoseconds from origin" and "can seek nanoseconds
1316 * from origin" method attributes attached to a source component class
1317 * descriptor which is attached to the automatic plugin descriptor.
1319 * _name: Component class name (C identifier).
1320 * _seek_method: Iterator "seek nanoseconds from origin" method
1321 * (bt_component_class_source_message_iterator_seek_ns_from_origin_method).
1322 * _can_seek_method: Iterator "can seek nanoseconds from origin" method
1323 * (bt_component_class_source_message_iterator_can_seek_ns_from_origin_method).
1325 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHODS(_name, _seek_method, _can_seek_method) \
1326 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHODS_WITH_ID(auto, _name, _seek_method, _can_seek_method)
1329 * Defines an iterator "seek beginning" and "can seek beginning" method
1330 * attributes attached to a source component class descriptor which is attached
1331 * to the automatic plugin descriptor.
1333 * _name: Component class name (C identifier).
1334 * _seek_method: Iterator "can seek beginning" method
1335 * (bt_component_class_source_message_iterator_can_seek_beginning_method).
1336 * _can_seek_method: Iterator "can seek beginning" method
1337 * (bt_component_class_source_message_iterator_seek_beginning_method).
1339 #define BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHODS(_name, _seek_method, _can_seek_method) \
1340 BT_PLUGIN_SOURCE_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHODS_WITH_ID(auto, _name, _seek_method, _can_seek_method)
1343 * Defines an iterator initialization method attribute attached to a
1344 * filter component class descriptor which is attached to the automatic
1345 * plugin descriptor.
1347 * _name: Component class name (C identifier).
1348 * _x: Iterator initialization method
1349 * (bt_component_class_filter_message_iterator_initialize_method).
1351 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_INITIALIZE_METHOD(_name, _x) \
1352 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_INITIALIZE_METHOD_WITH_ID(auto, _name, _x)
1355 * Defines an iterator finalize method attribute attached to a filter
1356 * component class descriptor which is attached to the automatic plugin
1359 * _name: Component class name (C identifier).
1360 * _x: Iterator finalize method
1361 * (bt_component_class_filter_message_iterator_finalize_method).
1363 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD(_name, _x) \
1364 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD_WITH_ID(auto, _name, _x)
1367 * Defines an iterator "seek nanosecconds from origin" and "can seek
1368 * nanoseconds from origin" method attributes attached to a filter component
1369 * class descriptor which is attached to the automatic plugin descriptor.
1371 * _name: Component class name (C identifier).
1372 * _seek_method: Iterator "seek nanoseconds from origin" method
1373 * (bt_component_class_filter_message_iterator_seek_ns_from_origin_method).
1374 * _can_seek_method: Iterator "can seek nanoseconds from origin" method
1375 * (bt_component_class_filter_message_iterator_can_seek_ns_from_origin_method).
1377 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHODS(_name, _seek_method, _can_seek_method) \
1378 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_NS_FROM_ORIGIN_METHODS_WITH_ID(auto, _name, _seek_method, _can_seek_method)
1381 * Defines an iterator "seek beginning" and "can seek beginning" method
1382 * attributes attached to a filter component class descriptor which is attached
1383 * to the automatic plugin descriptor.
1385 * _name: Component class name (C identifier).
1386 * _seek_method: Iterator "seek beginning" method
1387 * (bt_component_class_filter_message_iterator_seek_beginning_method).
1388 * _can_seek_method: Iterator "can seek beginning" method
1389 * (bt_component_class_filter_message_iterator_can_seek_beginning_method).
1391 #define BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHODS(_name, _seek_method, _can_seek_method) \
1392 BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_SEEK_BEGINNING_METHODS_WITH_ID(auto, _name, _seek_method, _can_seek_method)
1394 #define BT_PLUGIN_MODULE() \
1395 static struct __bt_plugin_descriptor const * const __bt_plugin_descriptor_dummy __BT_PLUGIN_DESCRIPTOR_ATTRS = NULL; \
1396 _BT_HIDDEN extern struct __bt_plugin_descriptor const *__BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL __BT_PLUGIN_DESCRIPTOR_BEGIN_EXTRA; \
1397 _BT_HIDDEN extern struct __bt_plugin_descriptor const *__BT_PLUGIN_DESCRIPTOR_END_SYMBOL __BT_PLUGIN_DESCRIPTOR_END_EXTRA; \
1399 static struct __bt_plugin_descriptor_attribute const * const __bt_plugin_descriptor_attribute_dummy __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_ATTRS = NULL; \
1400 _BT_HIDDEN extern struct __bt_plugin_descriptor_attribute const *__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_EXTRA; \
1401 _BT_HIDDEN extern struct __bt_plugin_descriptor_attribute const *__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL __BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_EXTRA; \
1403 static struct __bt_plugin_component_class_descriptor const * const __bt_plugin_component_class_descriptor_dummy __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRS = NULL; \
1404 _BT_HIDDEN extern struct __bt_plugin_component_class_descriptor const *__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_EXTRA; \
1405 _BT_HIDDEN extern struct __bt_plugin_component_class_descriptor const *__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL __BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_EXTRA; \
1407 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; \
1408 _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; \
1409 _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; \
1411 struct __bt_plugin_descriptor const * const *__bt_get_begin_section_plugin_descriptors(void) \
1413 return &__BT_PLUGIN_DESCRIPTOR_BEGIN_SYMBOL; \
1415 struct __bt_plugin_descriptor const * const *__bt_get_end_section_plugin_descriptors(void) \
1417 return &__BT_PLUGIN_DESCRIPTOR_END_SYMBOL; \
1419 struct __bt_plugin_descriptor_attribute const * const *__bt_get_begin_section_plugin_descriptor_attributes(void) \
1421 return &__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL; \
1423 struct __bt_plugin_descriptor_attribute const * const *__bt_get_end_section_plugin_descriptor_attributes(void) \
1425 return &__BT_PLUGIN_DESCRIPTOR_ATTRIBUTES_END_SYMBOL; \
1427 struct __bt_plugin_component_class_descriptor const * const *__bt_get_begin_section_component_class_descriptors(void) \
1429 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_BEGIN_SYMBOL; \
1431 struct __bt_plugin_component_class_descriptor const * const *__bt_get_end_section_component_class_descriptors(void) \
1433 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_END_SYMBOL; \
1435 struct __bt_plugin_component_class_descriptor_attribute const * const *__bt_get_begin_section_component_class_descriptor_attributes(void) \
1437 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_BEGIN_SYMBOL; \
1439 struct __bt_plugin_component_class_descriptor_attribute const * const *__bt_get_end_section_component_class_descriptor_attributes(void) \
1441 return &__BT_PLUGIN_COMPONENT_CLASS_DESCRIPTOR_ATTRIBUTES_END_SYMBOL; \
1448 #endif /* BABELTRACE2_PLUGIN_PLUGIN_DEV_H */