#include <XmlRpcSource.h>
Inheritance diagram for XmlRpc::XmlRpcSource:
Public Member Functions | |
virtual void | close () |
Close the owned fd. If deleteOnClose was specified at construction, the object is deleted. | |
int | getfd () const |
Return the file descriptor being monitored. | |
bool | getKeepOpen () const |
Return whether the file descriptor should be kept open if it is no longer monitored. | |
virtual unsigned | handleEvent (unsigned eventType)=0 |
Return true to continue monitoring this source. | |
void | setfd (int fd) |
Specify the file descriptor to monitor. | |
void | setKeepOpen (bool b=true) |
Specify whether the file descriptor should be kept open if it is no longer monitored. | |
XmlRpcSource (int fd=-1, bool deleteOnClose=false) | |
virtual | ~XmlRpcSource () |
Destructor. | |
Private Attributes | |
bool | _deleteOnClose |
int | _fd |
bool | _keepOpen |
|
Constructor
00010 : _fd(fd), _deleteOnClose(deleteOnClose), _keepOpen(false) 00011 { 00012 }
|
|
Destructor.
00015 { 00016 }
|
|
Close the owned fd. If deleteOnClose was specified at construction, the object is deleted.
Reimplemented in XmlRpc::XmlRpcClient. 00021 { 00022 if (_fd != -1) { 00023 XmlRpcUtil::log(2,"XmlRpcSource::close: closing socket %d.", _fd); 00024 XmlRpcSocket::close(_fd); 00025 XmlRpcUtil::log(2,"XmlRpcSource::close: done closing socket %d.", _fd); 00026 _fd = -1; 00027 } 00028 if (_deleteOnClose) { 00029 XmlRpcUtil::log(2,"XmlRpcSource::close: deleting this"); 00030 _deleteOnClose = false; 00031 delete this; 00032 } 00033 }
|
|
Return the file descriptor being monitored.
00025 { return _fd; }
|
|
Return whether the file descriptor should be kept open if it is no longer monitored.
00030 { return _keepOpen; }
|
|
Return true to continue monitoring this source.
Implemented in XmlRpc::XmlRpcClient, XmlRpc::XmlRpcServer, and XmlRpc::XmlRpcServerConnection. |
|
Specify the file descriptor to monitor.
00027 { _fd = fd; }
|
|
Specify whether the file descriptor should be kept open if it is no longer monitored.
00032 { _keepOpen = b; }
|
|
|
|
|
|
|