bt2: make ComponentSpec take a component class object
... rather than a plugin and component class name. It can be a user
component class:
class MySource(bt2._UserSourceComponent, ...):
...
spec = bt2.ComponentSpec(MySource)
or a component class from a plugin:
cc = bt2.find_plugin('my_plugin').source_component_classes['cerfeuil']
spec = bt2.ComponentSpec(cc)
This is a bit more general compared to taking a plugin name and a
component class name, since it allows passing an component class that
does not come from a plugin. It also allows the user to use component
classes from plugins in non-standard locations, by looking up plugins
manually with bt2.find_plugins_in_path.
For convenience, there is a new static method
bt2.ComponentSpec.from_named_plugin_and_component_class that creates a
ComponentSpec from a plugin and component class names.
Change-Id: I39e3fec6bbc7e7a9ba375065c9318b61b1791e35
Signed-off-by: Simon Marchi <simon.marchi@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1890
CI-Build: Francis Deslauriers <francis.deslauriers@efficios.com>
Tested-by: jenkins <jenkins@lttng.org>
Reviewed-by: Francis Deslauriers <francis.deslauriers@efficios.com>
This page took 0.026192 seconds and 4 git commands to generate.