Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

OW32::CAsyncMessageSocket Class Reference

Asynchronous socket message support. More...

#include <AsyncSocket.h>

Inheritance diagram for OW32::CAsyncMessageSocket:

OW32::CAsyncSocketBase List of all members.

Public Member Functions

 CAsyncMessageSocket (CAsyncSocketCallback *pCallback, SOCKET s)
 CAsyncMessageSocket (CAsyncSocketCallback *pCallback)
virtual int recv (char *buf, int len)
 Asynchronous recv.
virtual int send (const char *buf, int len)
 Asynchronous send.
virtual int connect (const struct sockaddr *name, int namelen)
 Connect to a remote server (stream) or set a default outgoing address for send (datagram).
virtual int connect (CSockAddrIn &sockaddr_in)
 Connect to a remote server (stream) or set a default outgoing address for send (datagram).

Friends

LRESULT CALLBACK SocketNotifyWndProc (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)

Detailed Description

Asynchronous socket message support.


Member Function Documentation

virtual int OW32::CAsyncMessageSocket::connect CSockAddrIn sockaddr_in  )  [inline, virtual]
 

Connect to a remote server (stream) or set a default outgoing address for send (datagram).

Parameters:
sockaddr_in The address to bind to

Reimplemented from OW32::CAsyncSocketBase.

virtual int OW32::CAsyncMessageSocket::connect const struct sockaddr *  name,
int  namelen
[virtual]
 

Connect to a remote server (stream) or set a default outgoing address for send (datagram).

Parameters:
name The address to connect to
namelen The length of the address

Reimplemented from OW32::CAsyncSocketBase.

virtual int OW32::CAsyncMessageSocket::recv char *  buf,
int  len
[virtual]
 

Asynchronous recv.

onReadCompletion will be called when the read completes.

Parameters:
buf The buffer for data
len The amount of data to try to read
Returns:
SOCKET_ERROR for any errors, or 0 for success. If the function returns SOCKET_ERROR the callback will not be invoked.

Implements OW32::CAsyncSocketBase.

virtual int OW32::CAsyncMessageSocket::send const char *  buf,
int  len
[virtual]
 

Asynchronous send.

onSendCompletion will be called when the send completes.

Parameters:
buf The buffer for data
len The amount of data to try to send
Returns:
SOCKET_ERROR for any errors, or 0 for success. If the function returns SOCKET_ERROR the callback will not be invoked.

Implements OW32::CAsyncSocketBase.


The documentation for this class was generated from the following file:
Generated on Sun Jun 5 01:29:23 2005 for OW32 by  doxygen 1.3.9.1