The interface for an object which generates Events (such as CaptureSession).
More...
#include <EventProvider.h>
List of all members.
Detailed Description
The interface for an object which generates Events (such as CaptureSession).
Any generated Events are initially stored by the provider itself, and they are not copied out to public EventQueues until waitForEvents() is called. If at any time there is an event type offered by a provider that is not accepted by an active EventQueue created by that provider, all events of that type will be discarded.
Definition at line 47 of file EventProvider.h.
Constructor & Destructor Documentation
Argus::IEventProvider::~IEventProvider |
( |
| ) |
|
|
inlineprotected |
Member Function Documentation
virtual EventQueue* Argus::IEventProvider::createEventQueue |
( |
const std::vector< EventType > & |
eventTypes, |
|
|
Status * |
status = NULL |
|
) |
| |
|
pure virtual |
Creates an event queue for events of the given type(s)
- Parameters:
-
[in] | eventTypes | The list of event types for the queue. |
[out] | status | An optional pointer to return success/status. |
- Returns:
- the new EventQueue object, or NULL on failure.
virtual Status Argus::IEventProvider::getAvailableEventTypes |
( |
std::vector< EventType > * |
types | ) |
const |
|
pure virtual |
Returns a list of event types that this provider can generate.
- Parameters:
-
[out] | types,a | vector that will be populated by the available event types. |
- Returns:
- success/status of the call.
static const InterfaceID& Argus::IEventProvider::id |
( |
| ) |
|
|
inlinestatic |
Waits for and transfers any pending events from the provider to the provided queues.
Ownership of all events transfered to a queue will be passed from the provider to the queue, and these event object pointers will remain valid until the queue is destroyed or until the next call to this function with that queue. In other words, any events in a queue will be destroyed when the queue is provided to another call of this function, regardless of whether or not it receives any new events, or when the queue is destroyed.
If more than one given queue accepts events of the same type, only the first of these queues will receive events of that type.
Any events that are not copied to queues by this function are left in the provider until they are queried using a queue receiving events of that type.
If there are no pending events of the requested types at the time this function is called, it will block until one is available or a timeout occurs.
- Parameters:
-
[in] | queues | The list of queues to transfer events to. |
[in] | timeout | The maximum time (in nanoseconds) to wait for new events. |
- Returns:
- success/status of the call.
The documentation for this class was generated from the following file: