Go to the documentation of this file.
35 #ifndef MESSAGE_FILTERS_CHAIN_H
36 #define MESSAGE_FILTERS_CHAIN_H
68 return boost::static_pointer_cast<F>(filter);
111 class Chain :
public ChainBase,
public SimpleFilter<M>
157 info.add_func = boost::bind((
void(F::*)(
const EventType&))&F::add, filter.get(), boost::placeholders::_1);
158 info.filter = filter;
159 info.passthrough = boost::make_shared<PassThrough<M> >();
162 info.passthrough->connectInput(*filter);
166 filter->connectInput(*
filters_.back().passthrough);
189 return boost::static_pointer_cast<F>(
filters_[index].filter);
255 #endif // MESSAGE_FILTERS_CHAIN_H
Chain()
Default constructor.
virtual boost::shared_ptr< void > getFilterForIndex(size_t index) const
virtual boost::shared_ptr< void > getFilterForIndex(size_t index) const =0
void add(const MConstPtr &msg)
Add a message to the start of this chain.
Encapsulates a connection from one filter to another (or to a user-specified callback)
boost::shared_ptr< void > filter
Connection last_filter_connection_
void lastFilterCB(const EventType &evt)
void connectInput(F &f)
Connect this filter's input to another filter's output.
Connection incoming_connection_
boost::function< void(const EventType &)> EventCallback
void operator()(void const *) const
void incomingCB(const EventType &evt)
boost::shared_ptr< F > getFilter(size_t index) const
Retrieve a filter from this chain by index. Returns an empty shared_ptr if the index is greater than ...
boost::shared_ptr< ChainBase > ChainBasePtr
boost::shared_ptr< F > getFilter(size_t index) const
Retrieve a filter from this chain by index. Returns an empty shared_ptr if the index is greater than ...
boost::function< void(const EventType &)> add_func
boost::shared_ptr< M const > MConstPtr
boost::shared_ptr< PassThrough< M > > passthrough
std::vector< FilterInfo > V_FilterInfo
void signalMessage(const MConstPtr &msg)
Call all registered callbacks, passing them the specified message.
size_t addFilter(F *filter)
Add a filter to this chain, by bare pointer. Returns the index of that filter in the chain.
ros::MessageEvent< M const > EventType
void disconnect()
disconnects this connection
message_filters
Author(s): Josh Faust, Vijay Pradeep, Dirk Thomas
, Jacob Perron
autogenerated on Sat Sep 14 2024 02:59:47