|
xrootd
|


Public Member Functions | |
| PollPoll (int &rc, int numfd, int pFD[2]) | |
| ~PollPoll () | |
Protected Member Functions | |
| void | Begin (XrdSysSemaphore *syncp, int &rc, const char **eMsg) |
| void | Exclude (Channel *cP, bool &isLocked, bool dover=1) |
| bool | Include (Channel *cP, int &eNum, const char **eTxt, bool &isLocked) |
| bool | Modify (Channel *cP, int &eNum, const char **eTxt, bool &isLocked) |
| void | Shutdown () |
Private Member Functions | |
| void | Dispatch (int ptent, int pollEv) |
| void | FDMod (int ptnum, int fd, int events) |
| void | FDRem (int ptnum) |
| bool | Process () |
Private Attributes | |
| XrdSysRecMutex | pollMutex |
| struct pollfd * | pollTab |
| int | pollMax |
| int | pollNum |
| struct pollfd * | pnewTab |
| Channel ** | chnlTab |
| int | chnlMax |
| int | chnlNum |
Static Private Attributes | |
| static const int | disFD = 0x80000000 |
| XrdSys::IOEvents::PollPoll::PollPoll | ( | int & | rc, |
| int | numfd, | ||
| int | pFD[2] | ||
| ) |
| XrdSys::IOEvents::PollPoll::~PollPoll | ( | ) | [inline] |
| void XrdSys::IOEvents::PollPoll::Begin | ( | XrdSysSemaphore * | syncp, |
| int & | rc, | ||
| const char ** | eTxt | ||
| ) | [protected, virtual] |
Start the polling event loop. An implementation must be supplied. Begin() is called via the internal BootStrap class from a new thread.
Implements XrdSys::IOEvents::Poller.
References XrdSysSemaphore::Post().
| void XrdSys::IOEvents::PollPoll::Dispatch | ( | int | ptent, |
| int | pollEv | ||
| ) | [private] |
| void XrdSys::IOEvents::PollPoll::Exclude | ( | Channel * | cP, |
| bool & | isLocked, | ||
| bool | dover = 1 |
||
| ) | [protected, virtual] |
Remove a channel to the poll set. An implementation must be supplied. The channel is locked when this method is called but must be unlocked by the method if a command is sent to the poller thread and isLocked set to false.
Implements XrdSys::IOEvents::Poller.
References XrdSys::IOEvents::Channel::GetFD(), and ISPOLLER.
| void XrdSys::IOEvents::PollPoll::FDMod | ( | int | ptnum, |
| int | fd, | ||
| int | events | ||
| ) | [private] |
| void XrdSys::IOEvents::PollPoll::FDRem | ( | int | ptnum | ) | [private] |
| bool XrdSys::IOEvents::PollPoll::Include | ( | Channel * | cP, |
| int & | eNum, | ||
| const char ** | eTxt, | ||
| bool & | isLocked | ||
| ) | [protected, virtual] |
Add a channel to the poll set. An implementation must be supplied. The channel is locked when this method is called but must be unlocked by the method if a command is sent to the poller thread and isLocked set to false.
Implements XrdSys::IOEvents::Poller.
References XrdSys::IOEvents::Channel::GetEvents(), XrdSys::IOEvents::Channel::GetFD(), and ISPOLLER.
| bool XrdSys::IOEvents::PollPoll::Modify | ( | Channel * | cP, |
| int & | eNum, | ||
| const char ** | eTxt, | ||
| bool & | isLocked | ||
| ) | [protected, virtual] |
Modify the event status of a channel. An implementation must be supplied. The channel is locked when this method is called but must be unlocked by the method if a command is sent to the poller thread and isLocked set to false.
Implements XrdSys::IOEvents::Poller.
References XrdSys::IOEvents::Channel::GetEvents(), XrdSys::IOEvents::Channel::GetFD(), and ISPOLLER.
| bool XrdSys::IOEvents::PollPoll::Process | ( | ) | [private] |
| void XrdSys::IOEvents::PollPoll::Shutdown | ( | ) | [protected, virtual] |
Shutdown the poller. An implementation must be supplied. The shutdown method must release any allocated storage and close private file descriptors. The polling thread will have already been terminated and x-thread pipe closed. Warning: the derived destructor *must* call Stop() and do nothing else!
Implements XrdSys::IOEvents::Poller.
References XrdSysMutex::Lock(), and XrdSysMutex::UnLock().
int XrdSys::IOEvents::PollPoll::chnlMax [private] |
Referenced by PollPoll().
int XrdSys::IOEvents::PollPoll::chnlNum [private] |
Referenced by PollPoll().
Channel** XrdSys::IOEvents::PollPoll::chnlTab [private] |
Referenced by PollPoll().
const int XrdSys::IOEvents::PollPoll::disFD = 0x80000000 [static, private] |
struct pollfd* XrdSys::IOEvents::PollPoll::pnewTab [private] |
Referenced by PollPoll().
int XrdSys::IOEvents::PollPoll::pollMax [private] |
Referenced by PollPoll().
int XrdSys::IOEvents::PollPoll::pollNum [private] |
Referenced by PollPoll().
struct pollfd* XrdSys::IOEvents::PollPoll::pollTab [private] |
Referenced by PollPoll().
1.7.6.1