PollInterface.h File Reference

Interface between an end point that needs a poll-type interface and a polling event service. More...

#include <isode/compat/manifest.h>
#include "EventSvc.h"
#include "Syncmsg.h"

Go to the source code of this file.

Data Structures

struct  Poll::pollmsg
 Carries the events on the appropriate FD, or that the end point should terminate. More...
 
class  Poll::User
 Poll user object interface. More...
 
struct  Poll::pollAction
 Messages from Poll Provider to self, via event manager. More...
 
class  Poll::Provider
 Poll provider interface. More...
 

Typedefs

typedef SyncEvent< pollmsg, UserPoll::UserEvent
 Defines a type to be used for delivering events to the poller.
 
typedef ::Event::AsyncEventAux< Provider, pollActionPoll::ProviderEvent
 Type for delivering events to the provider.
 

Enumerations

enum  Poll::PollEventTypes {
  Event_In = 0x01 , Poll::Event_Pri = 0x02 , Poll::Event_Out = 0x04 , Poll::Event_Err = 0x08 ,
  Poll::Event_Hup = 0x10 , Poll::Event_Nval = 0x20 , Poll::Event_Terminate = 0x20000
}
 Masks for the events. More...
 

Detailed Description

Interface between an end point that needs a poll-type interface and a polling event service.

Definition in file PollInterface.h.

Typedef Documentation

◆ UserEvent

typedef SyncEvent<pollmsg, User> Poll::UserEvent

Defines a type to be used for delivering events to the poller.

Definition at line 89 of file PollInterface.h.

◆ ProviderEvent

typedef ::Event::AsyncEventAux<Provider,pollAction> Poll::ProviderEvent

Type for delivering events to the provider.

Definition at line 166 of file PollInterface.h.

Enumeration Type Documentation

◆ PollEventTypes

Masks for the events.

Enumerator
Event_Pri 

There is data to read.

Event_Out 

There is urgent data to read.

Event_Err 

Writing now will not block.

Note: all error conditions imply that the FD has been deregistered automatically

Event_Hup 

Error condition.

Event_Nval 

Hung up.

Event_Terminate 

Invalid request: fd not open.

Definition at line 34 of file PollInterface.h.

34 {
35#ifdef POLLIN
36 Event_In = POLLIN,
37#else
38 Event_In = 0x01,
39#endif
40
41#ifdef POLLPRI
42 Event_Pri = POLLPRI,
43#else
44 Event_Pri = 0x02,
45#endif
46
47#ifdef POLLOUT
48 Event_Out = POLLOUT,
49#else
50 Event_Out = 0x04,
51#endif
52
55#ifdef POLLERR
56 Event_Err = POLLERR,
57#else
58 Event_Err = 0x08,
59#endif
60
61#ifdef POLLHUP
62 Event_Hup = POLLHUP,
63#else
64 Event_Hup = 0x10,
65#endif
66
67#ifdef POLLNVAL
68 Event_Nval = POLLNVAL,
69#else
70 Event_Nval = 0x20,
71#endif
72
73 Event_Terminate = 0x20000
74 };
@ Event_Nval
Hung up.
@ Event_Terminate
Invalid request: fd not open.
@ Event_Pri
There is data to read.
@ Event_Hup
Error condition.
@ Event_Err
Writing now will not block.
@ Event_Out
There is urgent data to read.

All rights reserved © 2002 - 2024 Isode Ltd.