dodo::io::network::exchange Class Reference
provides communication interface[send/receive data] More...
#include <ioNetworkExchange.h>


Classes | |
| class | __init__ |
| holds info that is passed to accept call, and then inits exchange More... | |
Public Types | |
| enum | operationEnum { OPERATION_CLOSE = 128 } |
defines type of operation for xexec More... | |
Public Member Functions | |
| exchange (short protection=channel::PROTECTION_PROCESS) | |
| constructor | |
| exchange (__init__ &init, short protection=channel::PROTECTION_PROCESS) | |
| constructor | |
| virtual | ~exchange () |
| destructor | |
| virtual bool | isAlive () |
| virtual void | close () |
| close connection | |
Protected Member Functions | |
| virtual int | inDescriptor () const |
| virtual int | outDescriptor () const |
| void | init (int socket, bool blocked, bool blockInherited) |
| init current instance | |
| virtual void | flush () const |
| flush output | |
| virtual unsigned long | _read (char *const data) const |
| virtual unsigned long | _readString (char *const data) const |
| read null- or newline- terminated string | |
| virtual unsigned long | _write (const char *const data) const |
| virtual unsigned long | _writeString (const char *const data) const |
| write null- terminated string | |
Detailed Description
provides communication interface[send/receive data]
Definition at line 51 of file ioNetworkExchange.h.
Member Enumeration Documentation
defines type of operation for xexec
Reimplemented from dodo::io::channel.
Definition at line 70 of file ioNetworkExchange.h.
00070 { 00071 OPERATION_CLOSE = 128, 00072 };
Constructor & Destructor Documentation
| dodo::io::network::exchange::exchange | ( | short | protection = channel::PROTECTION_PROCESS |
) |
constructor
- Parameters:
-
protection defines type of IO protection,
- See also:
- io::channel::protectionEnum
Reimplemented in dodo::io::network::ssl::exchange.
| dodo::io::network::exchange::exchange | ( | __init__ & | init, | |
| short | protection = channel::PROTECTION_PROCESS | |||
| ) |
constructor
- Parameters:
-
init is initial data[got from the accept method] protection defines type of IO protection,
- See also:
- io::channel::protectionEnum
- Note:
- the object that has inited the object of current instance can be used for another connections
Reimplemented in dodo::io::network::ssl::exchange.
| virtual dodo::io::network::exchange::~exchange | ( | ) | [virtual] |
destructor
Reimplemented in dodo::io::network::ssl::exchange.
Member Function Documentation
| virtual unsigned long dodo::io::network::exchange::_read | ( | char *const | data | ) | const [protected, virtual] |
- Returns:
- amount in bytes of successfully read data
- Parameters:
-
data defines buffer that will be filled
- Note:
- not more then bs(including null)
Implements dodo::io::channel.
Reimplemented in dodo::io::network::ssl::exchange.
| virtual unsigned long dodo::io::network::exchange::_readString | ( | char *const | data | ) | const [protected, virtual] |
read null- or newline- terminated string
- Returns:
- amount in bytes of successfully read data
- Parameters:
-
data defines buffer that will be filled
- Note:
- not more then bs(including null)
Implements dodo::io::channel.
Reimplemented in dodo::io::network::ssl::exchange.
| virtual unsigned long dodo::io::network::exchange::_write | ( | const char *const | data | ) | const [protected, virtual] |
- Returns:
- amount in bytes of successfully written data
Implements dodo::io::channel.
Reimplemented in dodo::io::network::ssl::exchange.
| virtual unsigned long dodo::io::network::exchange::_writeString | ( | const char *const | data | ) | const [protected, virtual] |
write null- terminated string
- Returns:
- amount in bytes of successfully written data
- Note:
- puts extra null in the end of the string
Implements dodo::io::channel.
| virtual void dodo::io::network::exchange::close | ( | ) | [virtual] |
close connection
Reimplemented in dodo::io::network::ssl::exchange.
| virtual void dodo::io::network::exchange::flush | ( | ) | const [protected, virtual] |
| virtual int dodo::io::network::exchange::inDescriptor | ( | ) | const [protected, virtual] |
- Returns:
- descriptor of input stream
Implements dodo::io::event::descriptor.
| void dodo::io::network::exchange::init | ( | int | socket, | |
| bool | blocked, | |||
| bool | blockInherited | |||
| ) | [protected] |
init current instance
- Parameters:
-
socket defines socket blocked defines the connection block status blockInherited defines block flag inheritance
| virtual bool dodo::io::network::exchange::isAlive | ( | ) | [virtual] |
- Returns:
- true if connection is alive
Reimplemented in dodo::io::network::ssl::exchange.
| virtual int dodo::io::network::exchange::outDescriptor | ( | ) | const [protected, virtual] |
- Returns:
- descriptor of output stream
Implements dodo::io::event::descriptor.
The documentation for this class was generated from the following file:
- include/libdodo/ioNetworkExchange.h
Generated on Sun Nov 8 03:44:55 2009 for libdodo by
1.6.1

