21 lines
438 B
C++
21 lines
438 B
C++
#ifndef PLATFORM_MESSAGE_QUEUE_H
|
|
#define PLATFORM_MESSAGE_QUEUE_H
|
|
|
|
namespace sp {
|
|
|
|
struct SysEvent;
|
|
|
|
// Interface for platform specific event queue.
|
|
class PlatformEventQueue
|
|
{
|
|
public :
|
|
|
|
// Poll one event from the platform's event queue.
|
|
// Returns false if there was no events.
|
|
// NOTE: This method is guaranteed to be non-blocking.
|
|
virtual bool poll(SysEvent& event) = 0;
|
|
};
|
|
|
|
} // namespace sp
|
|
|
|
#endif /* PLATFORM_MESSAGE_QUEUE_H */
|