Babeltrace 2 C API 2.1.0
Open-source trace manipulation framework
Loading...
Searching...
No Matches
component-class-dev.h
1/*
2 * SPDX-License-Identifier: MIT
3 *
4 * Copyright (C) 2010-2019 EfficiOS Inc. and Linux Foundation
5 */
6
7#ifndef BABELTRACE2_GRAPH_COMPONENT_CLASS_DEV_H
8#define BABELTRACE2_GRAPH_COMPONENT_CLASS_DEV_H
9
10/* IWYU pragma: private, include <babeltrace2/babeltrace.h> */
11
12#ifndef __BT_IN_BABELTRACE_H
13# error "Please include <babeltrace2/babeltrace.h> instead."
14#endif
15
16#include <babeltrace2/types.h>
17#include <babeltrace2/logging.h>
18
19#ifdef __cplusplus
20extern "C" {
21#endif
22
542
570 bt_self_component_sink *self_component);
571
589 bt_self_component_source *self_component);
590
608 bt_self_component_filter *self_component);
609
627 bt_self_component_sink *self_component);
628
655
710 bt_self_component_class_source *self_component_class,
711 const bt_value *params, void *initialize_method_data,
712 bt_logging_level logging_level,
713 bt_integer_range_set_unsigned *supported_versions);
714
769 bt_self_component_class_filter *self_component_class,
770 const bt_value *params, void *initialize_method_data,
771 bt_logging_level logging_level,
772 bt_integer_range_set_unsigned *supported_versions);
773
828 bt_self_component_class_sink *self_component_class,
829 const bt_value *params, void *initialize_method_data,
830 bt_logging_level logging_level,
831 bt_integer_range_set_unsigned *supported_versions);
832
857
882 bt_self_component_sink *self_component);
883
910
954 bt_self_component_source *self_component,
956 const bt_value *params, void *initialize_method_data);
957
1001 bt_self_component_filter *self_component,
1003 const bt_value *params, void *initialize_method_data);
1004
1049 bt_self_component_sink *self_component,
1051 const bt_value *params, void *initialize_method_data);
1052
1080
1112 bt_self_component_source *self_component,
1114 const bt_port_input *other_port);
1115
1147 bt_self_component_filter *self_component,
1149 const bt_port_output *other_port);
1150
1182 bt_self_component_filter *self_component,
1184 const bt_port_input *other_port);
1185
1217 bt_self_component_sink *self_component,
1219 const bt_port_output *other_port);
1220
1259
1320 bt_self_component_class_source *self_component_class,
1321 bt_private_query_executor *query_executor,
1322 const char *object_name, const bt_value *params,
1323 void *method_data, const bt_value **result);
1324
1385 bt_self_component_class_filter *self_component_class,
1386 bt_private_query_executor *query_executor,
1387 const char *object_name, const bt_value *params,
1388 void *method_data, const bt_value **result);
1389
1450 bt_self_component_class_sink *self_component_class,
1451 bt_private_query_executor *query_executor,
1452 const char *object_name, const bt_value *params,
1453 void *method_data, const bt_value **result);
1454
1501extern
1503 const char *name,
1504 bt_message_iterator_class *message_iterator_class)
1505 __BT_NOEXCEPT;
1506
1546extern
1548 const char *name,
1549 bt_message_iterator_class *message_iterator_class)
1550 __BT_NOEXCEPT;
1551
1587extern
1589 const char *name,
1591 __BT_NOEXCEPT;
1592
1617
1645 const char *description) __BT_NOEXCEPT;
1646
1664
1691 bt_component_class *component_class,
1692 const char *help_text) __BT_NOEXCEPT;
1693
1713
1736 bt_component_class_source *component_class,
1737 bt_component_class_source_finalize_method method) __BT_NOEXCEPT;
1738
1761 bt_component_class_filter *component_class,
1762 bt_component_class_filter_finalize_method method) __BT_NOEXCEPT;
1763
1784extern
1787 bt_component_class_sink *component_class,
1788 bt_component_class_sink_finalize_method method) __BT_NOEXCEPT;
1789
1813 bt_component_class_source *component_class,
1815 __BT_NOEXCEPT;
1816
1840 bt_component_class_filter *component_class,
1842 __BT_NOEXCEPT;
1843
1867 bt_component_class_sink *component_class,
1869 __BT_NOEXCEPT;
1870
1893extern
1896 bt_component_class_sink *component_class,
1898 __BT_NOEXCEPT;
1899
1922 bt_component_class_source *component_class,
1924 __BT_NOEXCEPT;
1925
1948 bt_component_class_filter *component_class,
1950 __BT_NOEXCEPT;
1951
1972extern
1975 bt_component_class_sink *component_class,
1976 bt_component_class_sink_initialize_method method) __BT_NOEXCEPT;
1977
2002 bt_component_class_source *component_class,
2004 __BT_NOEXCEPT;
2005
2030 bt_component_class_filter *component_class,
2032 __BT_NOEXCEPT;
2033
2058 bt_component_class_filter *component_class,
2060 __BT_NOEXCEPT;
2061
2084extern
2087 bt_component_class_sink *component_class,
2089 __BT_NOEXCEPT;
2090
2113 bt_component_class_source *component_class,
2114 bt_component_class_source_query_method method) __BT_NOEXCEPT;
2115
2138 bt_component_class_filter *component_class,
2139 bt_component_class_filter_query_method method) __BT_NOEXCEPT;
2140
2161extern
2164 bt_component_class_sink *component_class,
2165 bt_component_class_sink_query_method method) __BT_NOEXCEPT;
2166
2189static inline
2191 bt_component_class_source *component_class) __BT_NOEXCEPT
2192{
2193 return __BT_UPCAST(bt_component_class, component_class);
2194}
2195
2211static inline
2213 bt_component_class_filter *component_class) __BT_NOEXCEPT
2214{
2215 return __BT_UPCAST(bt_component_class, component_class);
2216}
2217
2233static inline
2235 bt_component_class_sink *component_class) __BT_NOEXCEPT
2236{
2237 return __BT_UPCAST(bt_component_class, component_class);
2238}
2239
2244#ifdef __cplusplus
2245}
2246#endif
2247
2248#endif /* BABELTRACE2_GRAPH_COMPONENT_CLASS_DEV_H */
bt_component_class_initialize_method_status(* bt_component_class_source_initialize_method)(bt_self_component_source *self_component, bt_self_component_source_configuration *configuration, const bt_value *params, void *initialize_method_data)
Source component initialization method.
Definition component-class-dev.h:953
bt_component_class_set_method_status bt_component_class_sink_set_input_port_connected_method(bt_component_class_sink *component_class, bt_component_class_sink_input_port_connected_method method)
Sets the optional "input port connected" method of the sink component class component_class to method...
bt_component_class_set_help_status
Status codes for bt_component_class_set_help().
Definition component-class-dev.h:1651
bt_component_class_set_method_status bt_component_class_sink_set_initialize_method(bt_component_class_sink *component_class, bt_component_class_sink_initialize_method method)
Sets the optional initialization method of the sink component class component_class to method.
void(* bt_component_class_filter_finalize_method)(bt_self_component_filter *self_component)
Filter component finalization method.
Definition component-class-dev.h:607
void(* bt_component_class_source_finalize_method)(bt_self_component_source *self_component)
Source component finalization method.
Definition component-class-dev.h:588
bt_component_class_set_method_status bt_component_class_sink_set_graph_is_configured_method(bt_component_class_sink *component_class, bt_component_class_sink_graph_is_configured_method method)
Sets the "graph is configured" method of the sink component class component_class to method.
bt_component_class_sink_consume_method_status
Status codes for bt_component_class_sink_consume_method.
Definition component-class-dev.h:511
bt_component_class_initialize_method_status(* bt_component_class_filter_initialize_method)(bt_self_component_filter *self_component, bt_self_component_filter_configuration *configuration, const bt_value *params, void *initialize_method_data)
Filter component initialization method.
Definition component-class-dev.h:1000
bt_component_class_port_connected_method_status(* bt_component_class_filter_output_port_connected_method)(bt_self_component_filter *self_component, bt_self_component_port_output *self_port, const bt_port_input *other_port)
Filter component "output port connected" method.
Definition component-class-dev.h:1181
bt_component_class_get_supported_mip_versions_method_status(* bt_component_class_filter_get_supported_mip_versions_method)(bt_self_component_class_filter *self_component_class, const bt_value *params, void *initialize_method_data, bt_logging_level logging_level, bt_integer_range_set_unsigned *supported_versions)
Filter component class "get supported Message Interchange Protocol versions" method.
Definition component-class-dev.h:768
bt_component_class_initialize_method_status(* bt_component_class_sink_initialize_method)(bt_self_component_sink *self_component, bt_self_component_sink_configuration *configuration, const bt_value *params, void *initialize_method_data)
Sink component initialization method.
Definition component-class-dev.h:1048
bt_component_class_port_connected_method_status
Status codes for bt_component_class_source_output_port_connected_method, bt_component_class_filter_in...
Definition component-class-dev.h:1061
bt_component_class_set_method_status bt_component_class_filter_set_initialize_method(bt_component_class_filter *component_class, bt_component_class_filter_initialize_method method)
Sets the optional initialization method of the filter component class component_class to method.
bt_component_class_set_help_status bt_component_class_set_help(bt_component_class *component_class, const char *help_text)
Sets the help text of the component class component_class to a copy of help_text.
bt_component_class_source * bt_component_class_source_create(const char *name, bt_message_iterator_class *message_iterator_class)
Creates a source component class named name and having the message iterator class message_iterator_cl...
bt_component_class_sink_graph_is_configured_method_status
Status codes for bt_component_class_sink_graph_is_configured_method.
Definition component-class-dev.h:838
bt_component_class_set_method_status bt_component_class_source_set_get_supported_mip_versions_method(bt_component_class_source *component_class, bt_component_class_source_get_supported_mip_versions_method method)
Sets the "get supported Message Interchange Protocol versions" method of the source component class c...
bt_component_class_sink_graph_is_configured_method_status(* bt_component_class_sink_graph_is_configured_method)(bt_self_component_sink *self_component)
Sink component "graph is configured" method.
Definition component-class-dev.h:881
bt_component_class_set_method_status bt_component_class_filter_set_finalize_method(bt_component_class_filter *component_class, bt_component_class_filter_finalize_method method)
Sets the optional finalization method of the filter component class component_class to method.
bt_component_class_port_connected_method_status(* bt_component_class_filter_input_port_connected_method)(bt_self_component_filter *self_component, bt_self_component_port_input *self_port, const bt_port_output *other_port)
Filter component "input port connected" method.
Definition component-class-dev.h:1146
bt_component_class_query_method_status
Status codes for bt_component_class_source_query_method, bt_component_class_filter_query_method,...
Definition component-class-dev.h:1228
static bt_component_class * bt_component_class_filter_as_component_class(bt_component_class_filter *component_class)
Upcasts the filter component class component_class to the common bt_component_class type.
Definition component-class-dev.h:2212
bt_component_class_set_method_status bt_component_class_sink_set_finalize_method(bt_component_class_sink *component_class, bt_component_class_sink_finalize_method method)
Sets the optional finalization method of the sink component class component_class to method.
bt_component_class_filter * bt_component_class_filter_create(const char *name, bt_message_iterator_class *message_iterator_class)
Creates a filter component class named name and having the message iterator class message_iterator_cl...
bt_component_class_set_description_status
Status codes for bt_component_class_set_description().
Definition component-class-dev.h:1604
bt_component_class_get_supported_mip_versions_method_status(* bt_component_class_source_get_supported_mip_versions_method)(bt_self_component_class_source *self_component_class, const bt_value *params, void *initialize_method_data, bt_logging_level logging_level, bt_integer_range_set_unsigned *supported_versions)
Source component class "get supported Message Interchange Protocol versions" method.
Definition component-class-dev.h:709
bt_component_class_set_method_status
Status code for the bt_component_class_*_set_*_method() functions.
Definition component-class-dev.h:1706
bt_component_class_sink * bt_component_class_sink_create(const char *name, bt_component_class_sink_consume_method consume_method)
Creates a sink component class named name and having the consuming method consume_method.
bt_component_class_query_method_status(* bt_component_class_filter_query_method)(bt_self_component_class_filter *self_component_class, bt_private_query_executor *query_executor, const char *object_name, const bt_value *params, void *method_data, const bt_value **result)
Filter component class query method.
Definition component-class-dev.h:1384
bt_component_class_set_method_status bt_component_class_source_set_query_method(bt_component_class_source *component_class, bt_component_class_source_query_method method)
Sets the optional query method of the source component class component_class to method.
bt_component_class_query_method_status(* bt_component_class_sink_query_method)(bt_self_component_class_sink *self_component_class, bt_private_query_executor *query_executor, const char *object_name, const bt_value *params, void *method_data, const bt_value **result)
Sink component class query method.
Definition component-class-dev.h:1449
bt_component_class_set_method_status bt_component_class_source_set_finalize_method(bt_component_class_source *component_class, bt_component_class_source_finalize_method method)
Sets the optional finalization method of the source component class component_class to method.
static bt_component_class * bt_component_class_sink_as_component_class(bt_component_class_sink *component_class)
Upcasts the sink component class component_class to the common bt_component_class type.
Definition component-class-dev.h:2234
bt_component_class_set_method_status bt_component_class_sink_set_query_method(bt_component_class_sink *component_class, bt_component_class_sink_query_method method)
Sets the optional query method of the sink component class component_class to method.
bt_component_class_initialize_method_status
Status codes for bt_component_class_source_initialize_method, bt_component_class_filter_initialize_me...
Definition component-class-dev.h:891
bt_component_class_set_method_status bt_component_class_filter_set_get_supported_mip_versions_method(bt_component_class_filter *component_class, bt_component_class_filter_get_supported_mip_versions_method method)
Sets the "get supported Message Interchange Protocol versions" method of the filter component class c...
bt_component_class_get_supported_mip_versions_method_status(* bt_component_class_sink_get_supported_mip_versions_method)(bt_self_component_class_sink *self_component_class, const bt_value *params, void *initialize_method_data, bt_logging_level logging_level, bt_integer_range_set_unsigned *supported_versions)
Sink component class "get supported Message Interchange Protocol versions" method.
Definition component-class-dev.h:827
bt_component_class_port_connected_method_status(* bt_component_class_sink_input_port_connected_method)(bt_self_component_sink *self_component, bt_self_component_port_input *self_port, const bt_port_output *other_port)
Sink component "input port connected" method.
Definition component-class-dev.h:1216
bt_component_class_get_supported_mip_versions_method_status
Status codes for bt_component_class_source_get_supported_mip_versions_method, bt_component_class_filt...
Definition component-class-dev.h:636
bt_component_class_set_method_status bt_component_class_source_set_initialize_method(bt_component_class_source *component_class, bt_component_class_source_initialize_method method)
Sets the optional initialization method of the source component class component_class to method.
bt_component_class_set_method_status bt_component_class_sink_set_get_supported_mip_versions_method(bt_component_class_sink *component_class, bt_component_class_sink_get_supported_mip_versions_method method)
Sets the "get supported Message Interchange Protocol versions" method of the sink component class com...
bt_component_class_set_method_status bt_component_class_filter_set_output_port_connected_method(bt_component_class_filter *component_class, bt_component_class_filter_output_port_connected_method method)
Sets the optional "output port connected" method of the filter component class component_class to met...
void(* bt_component_class_sink_finalize_method)(bt_self_component_sink *self_component)
Sink component finalization method.
Definition component-class-dev.h:626
bt_component_class_port_connected_method_status(* bt_component_class_source_output_port_connected_method)(bt_self_component_source *self_component, bt_self_component_port_output *self_port, const bt_port_input *other_port)
Source component "output port connected" method.
Definition component-class-dev.h:1111
bt_component_class_set_method_status bt_component_class_filter_set_query_method(bt_component_class_filter *component_class, bt_component_class_filter_query_method method)
Sets the optional query method of the filter component class component_class to method.
static bt_component_class * bt_component_class_source_as_component_class(bt_component_class_source *component_class)
Upcasts the source component class component_class to the common bt_component_class type.
Definition component-class-dev.h:2190
bt_component_class_set_method_status bt_component_class_filter_set_input_port_connected_method(bt_component_class_filter *component_class, bt_component_class_filter_input_port_connected_method method)
Sets the optional "input port connected" method of the filter component class component_class to meth...
bt_component_class_set_description_status bt_component_class_set_description(bt_component_class *component_class, const char *description)
Sets the description of the component class component_class to a copy of description.
bt_component_class_sink_consume_method_status(* bt_component_class_sink_consume_method)(bt_self_component_sink *self_component)
Sink component consuming method.
Definition component-class-dev.h:569
bt_component_class_query_method_status(* bt_component_class_source_query_method)(bt_self_component_class_source *self_component_class, bt_private_query_executor *query_executor, const char *object_name, const bt_value *params, void *method_data, const bt_value **result)
Source component class query method.
Definition component-class-dev.h:1319
bt_component_class_set_method_status bt_component_class_source_set_output_port_connected_method(bt_component_class_source *component_class, bt_component_class_source_output_port_connected_method method)
Sets the optional "output port connected" method of the source component class component_class to met...
@ BT_COMPONENT_CLASS_SET_HELP_STATUS_MEMORY_ERROR
Out of memory.
Definition component-class-dev.h:1662
@ BT_COMPONENT_CLASS_SET_HELP_STATUS_OK
Success.
Definition component-class-dev.h:1656
@ BT_COMPONENT_CLASS_SINK_CONSUME_METHOD_STATUS_ERROR
User error.
Definition component-class-dev.h:540
@ BT_COMPONENT_CLASS_SINK_CONSUME_METHOD_STATUS_END
Sink component is finished processing.
Definition component-class-dev.h:522
@ BT_COMPONENT_CLASS_SINK_CONSUME_METHOD_STATUS_AGAIN
Try again.
Definition component-class-dev.h:528
@ BT_COMPONENT_CLASS_SINK_CONSUME_METHOD_STATUS_MEMORY_ERROR
Out of memory.
Definition component-class-dev.h:534
@ BT_COMPONENT_CLASS_SINK_CONSUME_METHOD_STATUS_OK
Success.
Definition component-class-dev.h:516
@ BT_COMPONENT_CLASS_PORT_CONNECTED_METHOD_STATUS_ERROR
User error.
Definition component-class-dev.h:1078
@ BT_COMPONENT_CLASS_PORT_CONNECTED_METHOD_STATUS_MEMORY_ERROR
Out of memory.
Definition component-class-dev.h:1072
@ BT_COMPONENT_CLASS_PORT_CONNECTED_METHOD_STATUS_OK
Success.
Definition component-class-dev.h:1066
@ BT_COMPONENT_CLASS_SINK_GRAPH_IS_CONFIGURED_METHOD_STATUS_ERROR
User error.
Definition component-class-dev.h:855
@ BT_COMPONENT_CLASS_SINK_GRAPH_IS_CONFIGURED_METHOD_STATUS_MEMORY_ERROR
Out of memory.
Definition component-class-dev.h:849
@ BT_COMPONENT_CLASS_SINK_GRAPH_IS_CONFIGURED_METHOD_STATUS_OK
Success.
Definition component-class-dev.h:843
@ BT_COMPONENT_CLASS_QUERY_METHOD_STATUS_UNKNOWN_OBJECT
Unknown object to query.
Definition component-class-dev.h:1239
@ BT_COMPONENT_CLASS_QUERY_METHOD_STATUS_AGAIN
Try again.
Definition component-class-dev.h:1245
@ BT_COMPONENT_CLASS_QUERY_METHOD_STATUS_ERROR
User error.
Definition component-class-dev.h:1257
@ BT_COMPONENT_CLASS_QUERY_METHOD_STATUS_MEMORY_ERROR
Out of memory.
Definition component-class-dev.h:1251
@ BT_COMPONENT_CLASS_QUERY_METHOD_STATUS_OK
Success.
Definition component-class-dev.h:1233
@ BT_COMPONENT_CLASS_SET_DESCRIPTION_STATUS_OK
Success.
Definition component-class-dev.h:1609
@ BT_COMPONENT_CLASS_SET_DESCRIPTION_STATUS_MEMORY_ERROR
Out of memory.
Definition component-class-dev.h:1615
@ BT_COMPONENT_CLASS_SET_METHOD_STATUS_OK
Success.
Definition component-class-dev.h:1711
@ BT_COMPONENT_CLASS_INITIALIZE_METHOD_STATUS_MEMORY_ERROR
Out of memory.
Definition component-class-dev.h:902
@ BT_COMPONENT_CLASS_INITIALIZE_METHOD_STATUS_ERROR
User error.
Definition component-class-dev.h:908
@ BT_COMPONENT_CLASS_INITIALIZE_METHOD_STATUS_OK
Success.
Definition component-class-dev.h:896
@ BT_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_STATUS_MEMORY_ERROR
Out of memory.
Definition component-class-dev.h:647
@ BT_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_STATUS_OK
Success.
Definition component-class-dev.h:641
@ BT_COMPONENT_CLASS_GET_SUPPORTED_MIP_VERSIONS_METHOD_STATUS_ERROR
User error.
Definition component-class-dev.h:653
struct bt_component_class_sink bt_component_class_sink
Sink component class.
Definition types.h:27
struct bt_component_class_source bt_component_class_source
Source component class.
Definition types.h:28
struct bt_component_class_filter bt_component_class_filter
Filter component class.
Definition types.h:26
struct bt_component_class bt_component_class
Component class.
Definition types.h:25
struct bt_integer_range_set_unsigned bt_integer_range_set_unsigned
Set of unsigned 64-bit integer ranges.
Definition types.h:54
bt_logging_level
Logging level enumerators.
Definition logging.h:97
struct bt_message_iterator_class bt_message_iterator_class
Message iterator class.
Definition types.h:60
struct bt_port_output bt_port_output
Output port.
Definition types.h:67
struct bt_port_input bt_port_input
Input port.
Definition types.h:66
struct bt_private_query_executor bt_private_query_executor
Private query executor.
Definition types.h:69
struct bt_self_component_class_source bt_self_component_class_source
Self source component class.
Definition types.h:75
struct bt_self_component_class_filter bt_self_component_class_filter
Self filter component class.
Definition types.h:73
struct bt_self_component_class_sink bt_self_component_class_sink
Self sink component class.
Definition types.h:74
struct bt_self_component_port_output bt_self_component_port_output
Self component output port.
Definition types.h:81
struct bt_self_component_port_input bt_self_component_port_input
Self component input port.
Definition types.h:79
struct bt_self_component_sink_configuration bt_self_component_sink_configuration
Self sink component configuration.
Definition types.h:83
struct bt_self_component_filter_configuration bt_self_component_filter_configuration
Self filter component configuration.
Definition types.h:77
struct bt_self_component_source bt_self_component_source
Self source component.
Definition types.h:84
struct bt_self_component_filter bt_self_component_filter
Self filter component.
Definition types.h:76
struct bt_self_component_sink bt_self_component_sink
Self sink component.
Definition types.h:82
struct bt_self_component_source_configuration bt_self_component_source_configuration
Self source component configuration.
Definition types.h:85
struct bt_value bt_value
Value.
Definition types.h:93