nidas  v1.2-1520
Public Member Functions | List of all members
nidas::core::Polled Class Referenceabstract

Interface for objects with a file descriptor, providing a virtual method to be called when system calls such as select, poll, or epoll indicate an event is pending on the file descriptor. More...

#include <Polled.h>

Inheritance diagram for nidas::core::Polled:
Inheritance graph
[legend]

Public Member Functions

virtual ~Polled ()
 
virtual int getFd () const =0
 
virtual bool handlePollEvents (uint32_t events)=0 throw ()
 

Detailed Description

Interface for objects with a file descriptor, providing a virtual method to be called when system calls such as select, poll, or epoll indicate an event is pending on the file descriptor.

Constructor & Destructor Documentation

virtual nidas::core::Polled::~Polled ( )
inlinevirtual

Member Function Documentation

virtual int nidas::core::Polled::getFd ( ) const
pure virtual
virtual bool nidas::core::Polled::handlePollEvents ( uint32_t  events)
throw (
)
pure virtual
Returns
: true: read consumed all available data, false otherwise. This return value is required for edge-triggered polling with epoll, since a read event won't be re-triggered on a file descriptor until all available data is read.

Implemented in nidas::core::SensorHandler::NotifyPipe, nidas::core::SensorHandler::PolledDSMSensor, nidas::core::RemoteSerialConnection, and nidas::core::RemoteSerialListener.

Referenced by nidas::core::SensorHandler::run().


The documentation for this class was generated from the following file: