26#ifndef GOBY_MIDDLEWARE_TRANSPORT_POLLER_H
27#define GOBY_MIDDLEWARE_TRANSPORT_POLLER_H
55 int _transporter_poll(std::unique_ptr<std::unique_lock<std::mutex> >& lock)
override
58 int inner_poll_items = 0;
64 if (!inner_poll_items)
65 poll_items +=
static_cast<Transporter*
>(
this)->_poll(lock);
69 return inner_poll_items + poll_items;
73 PollerInterface* inner_poller_;
Defines the common interface for polling for data on Goby transporters.
std::shared_ptr< std::mutex > poll_mutex()
access the mutex used for poll synchronization
std::shared_ptr< std::condition_variable > cv()
access the condition variable used for poll synchronization
Utility class for allowing the various Goby middleware transporters to poll the underlying transport ...
Poller(PollerInterface *inner_poller=nullptr)
Construct this Poller with a pointer to the inner Poller (unless this is the innermost Poller)
PollerInterface * inner_poller()
The global namespace for the Goby project.