23 lines
538 B
C++
23 lines
538 B
C++
#ifndef EVENTQUEUE_H
|
|
#define EVENTQUEUE_H
|
|
|
|
#include <pthread.h>
|
|
#include <unistd.h>
|
|
#include <iostream>
|
|
#include <list>
|
|
|
|
class EventQueue
|
|
{
|
|
public:
|
|
bool EventQueue_AddEvent(int tInputCmd, void *pInputParam);
|
|
bool EventQueue_AddEventToFront(int tInputCmd, void *pInputParam);
|
|
bool EventQueue_PeekEvent(int *pOutputCmd, void **ppOutputParam);
|
|
void EventQueue_PopEvent(void);
|
|
bool EventQueue_GetEvent(int *pOutputCmd, void **ppOutputParam);
|
|
|
|
private:
|
|
std::list<int> cmdList;
|
|
std::list<void *> cmdParam;
|
|
};
|
|
|
|
#endif |