bt2: check for _graph_is_configured method in user sink classes
authorSimon Marchi <simon.marchi@efficios.com>
Mon, 15 Jul 2019 03:19:24 +0000 (23:19 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 18 Jul 2019 15:53:36 +0000 (11:53 -0400)
commit8a08af82fd9df23f0c13fb9a872947d2a30a911c
tree86a0d494248cf503436dff53a534fa03da9a2cd9
parent6b0765905e56acc4abc02903e2d5ba55b3d78265
bt2: check for _graph_is_configured method in user sink classes

Since a _graph_is_configured method is an essential method to implement
in any useful sink, check for the presence of that method when
instantiating a user sink component class in Python (that is, when the
Python class is created).  We already do that for the _consume method,
and I think it greatly helps the user writing a sink by telling them
what not to forget.

Change-Id: Ic8c3741b121eccc2857afac809521dd7213aa679
Signed-off-by: Simon Marchi <simon.marchi@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1707
Tested-by: jenkins <jenkins@lttng.org>
Reviewed-by: Philippe Proulx <eeppeliteloop@gmail.com>
src/bindings/python/bt2/bt2/component.py
tests/bindings/python/bt2/test_component.py
tests/bindings/python/bt2/test_component_class.py
tests/bindings/python/bt2/test_connection.py
tests/bindings/python/bt2/test_graph.py
tests/bindings/python/bt2/test_port.py
tests/bindings/python/bt2/test_query_executor.py
tests/bindings/python/bt2/utils.py
tests/python-plugin-provider/bt_plugin_test_python_plugin_provider.py
This page took 0.026352 seconds and 4 git commands to generate.