aqhome: started rewriting IPC module.
started with basic event interface using unix fd and timers.
This commit is contained in:
36
aqhome/events2/fdobject.h
Normal file
36
aqhome/events2/fdobject.h
Normal file
@@ -0,0 +1,36 @@
|
||||
/****************************************************************************
|
||||
* This file is part of the project Gwenhywfar.
|
||||
* Gwenhywfar (c) by 2023 Martin Preuss, all rights reserved.
|
||||
*
|
||||
* The license for this file can be found in the file COPYING which you
|
||||
* should have received along with this file.
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef AQH_FDOBJECT_H
|
||||
#define AQH_FDOBJECT_H
|
||||
|
||||
|
||||
#include <aqhome/events2/object.h>
|
||||
|
||||
|
||||
enum {
|
||||
AQH_FDOBJECT_FDMODE_READ=1,
|
||||
AQH_FDOBJECT_FDMODE_WRITE
|
||||
};
|
||||
|
||||
|
||||
enum {
|
||||
AQH_FDOBJECT_SIGNAL_ISREADY=AQH_OBJECT_SIGNAL_LAST
|
||||
};
|
||||
|
||||
|
||||
|
||||
AQHOME_API AQH_OBJECT *AQH_FdObject_new(AQH_EVENT_LOOP *eventLoop, int fd, int mode);
|
||||
|
||||
AQHOME_API int AQH_FdObject_GetFdMode(const AQH_OBJECT *o);
|
||||
AQHOME_API void AQH_FdObject_SetFdMode(AQH_OBJECT *o, int i);
|
||||
|
||||
AQHOME_API int AQH_FdObject_GetFd(const AQH_OBJECT *o);
|
||||
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user