lib: rename "notification" -> "message"
[babeltrace.git] / plugins / utils / plugin.c
CommitLineData
e0dfa761
PP
1/*
2 * Copyright 2017 Philippe Proulx <pproulx@efficios.com>
3 *
4 * Permission is hereby granted, free of charge, to any person obtaining a copy
5 * of this software and associated documentation files (the "Software"), to deal
6 * in the Software without restriction, including without limitation the rights
7 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8 * copies of the Software, and to permit persons to whom the Software is
9 * furnished to do so, subject to the following conditions:
10 *
11 * The above copyright notice and this permission notice shall be included in
12 * all copies or substantial portions of the Software.
13 *
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20 * SOFTWARE.
21 */
22
9d408fca 23#include <babeltrace/babeltrace.h>
e0dfa761 24#include "dummy/dummy.h"
358340ec 25#include "counter/counter.h"
958f7d11 26#include "muxer/muxer.h"
e0dfa761 27
52238017
MJ
28#ifndef BT_BUILT_IN_PLUGINS
29BT_PLUGIN_MODULE();
30#endif
31
e0dfa761 32BT_PLUGIN(utils);
958f7d11 33BT_PLUGIN_DESCRIPTION("Graph utilities");
97ade20b 34BT_PLUGIN_AUTHOR("Julien Desfossez, Jérémie Galarneau, Philippe Proulx");
e0dfa761
PP
35BT_PLUGIN_LICENSE("MIT");
36
358340ec 37/* sink.utils.dummy */
e0dfa761 38BT_PLUGIN_SINK_COMPONENT_CLASS(dummy, dummy_consume);
c2b71c92 39BT_PLUGIN_SINK_COMPONENT_CLASS_INIT_METHOD(dummy, dummy_init);
64cadc66 40BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD(dummy, dummy_finalize);
d94d92ac 41BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD(dummy,
0d8b4d8e 42 dummy_port_connected);
e0dfa761 43BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION(dummy,
d6e69534 44 "Consume messages and discard them.");
e0dfa761 45
358340ec
PP
46/* sink.utils.counter */
47BT_PLUGIN_SINK_COMPONENT_CLASS(counter, counter_consume);
48BT_PLUGIN_SINK_COMPONENT_CLASS_INIT_METHOD(counter, counter_init);
49BT_PLUGIN_SINK_COMPONENT_CLASS_FINALIZE_METHOD(counter, counter_finalize);
d94d92ac 50BT_PLUGIN_SINK_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD(counter,
358340ec
PP
51 counter_port_connected);
52BT_PLUGIN_SINK_COMPONENT_CLASS_DESCRIPTION(counter,
d6e69534 53 "Count messages and print the results.");
358340ec 54
3dca2276 55#if 0
358340ec 56/* flt.utils.trimmer */
41a2b7ae 57BT_PLUGIN_FILTER_COMPONENT_CLASS(trimmer, trimmer_iterator_next);
e0dfa761 58BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION(trimmer,
d6e69534 59 "Keep messages that occur within a specific time range.");
e0dfa761 60BT_PLUGIN_FILTER_COMPONENT_CLASS_INIT_METHOD(trimmer, trimmer_component_init);
64cadc66 61BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD(trimmer, finalize_trimmer);
d6e69534 62BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_INIT_METHOD(trimmer,
958f7d11 63 trimmer_iterator_init);
d6e69534 64BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD(trimmer,
958f7d11 65 trimmer_iterator_finalize);
3dca2276 66#endif
958f7d11 67
358340ec 68/* flt.utils.muxer */
d6e69534 69BT_PLUGIN_FILTER_COMPONENT_CLASS(muxer, muxer_msg_iter_next);
958f7d11 70BT_PLUGIN_FILTER_COMPONENT_CLASS_DESCRIPTION(muxer,
d6e69534 71 "Sort messages from multiple input ports to a single output port by time.");
958f7d11
PP
72BT_PLUGIN_FILTER_COMPONENT_CLASS_INIT_METHOD(muxer, muxer_init);
73BT_PLUGIN_FILTER_COMPONENT_CLASS_FINALIZE_METHOD(muxer, muxer_finalize);
d94d92ac
PP
74BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_DISCONNECTED_METHOD(muxer,
75 muxer_input_port_disconnected);
76BT_PLUGIN_FILTER_COMPONENT_CLASS_INPUT_PORT_CONNECTED_METHOD(muxer,
77 muxer_input_port_connected);
d6e69534
PP
78BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_INIT_METHOD(muxer,
79 muxer_msg_iter_init);
80BT_PLUGIN_FILTER_COMPONENT_CLASS_MESSAGE_ITERATOR_FINALIZE_METHOD(muxer,
81 muxer_msg_iter_finalize);
This page took 0.037988 seconds and 4 git commands to generate.