-class DummySink : public bt2::UserSinkComponent<DummySink>
-{
-public:
- static constexpr auto name = "dummy";
-
- explicit DummySink(const bt2::SelfSinkComponent self, bt2::ConstMapValue, void *) :
- bt2::UserSinkComponent<DummySink>(self, "DUMMY-SINK")
- {
- this->_addInputPort("in");
- }
-
- void _graphIsConfigured()
- {
- _mMsgIter = this->_createMessageIterator(this->_inputPorts()["in"]);
- }
-
- bool _consume()
- {
- return _mMsgIter->next().has_value();
- }
-
-private:
- bt2::MessageIterator::Shared _mMsgIter;
-};
-