#include <BSock.h>
Inheritance diagram for CBSock:
Public Member Functions | |
virtual | ~CBSock () |
~CBSOCK | |
int32 | Process () |
Process. | |
int32 | PeekSize () const |
PeekSize. | |
uint32 | PeekType () const |
Peek. | |
bool | Peek () const |
Peek. | |
CMessage * | ReadNext () |
ReadNext. | |
bool | WriteNext (const CMessage *Msg) |
WriteNext. | |
int32 | GetPendingUDPBytes () |
GetPendingUDPBytes. | |
void | SetAddr (uint8 addr[]) |
buffer to store send mes headers. | |
Protected Member Functions | |
int32 | ProcessRead () |
ProcessRead. | |
int32 | ProcessSend () |
ProcessSend. | |
bool | PingConnection () |
PingConnection. | |
Protected Attributes | |
CBSOCK_PROCESS_STATE | m_MessageInState |
Stores the number of bytes available. | |
int8 * | m_pSendBuffer |
ptr to the ReadQueue msg buffer | |
int8 * | m_pSendMsgBuffer |
ptr to the SendQueue msg buffer | |
int8 * | m_pReadMsgBuffer |
ptr to a copy of the buffer contained in CMessage | |
MSG_HEADER | m_ReadMsgHeader |
ptr to a copy of the buffer contained in CMessage | |
MSG_HEADER | m_SendMsgHeader |
buffer to store read msg headers. | |
Static Protected Attributes | |
static const int32 | TIMEOUT = 10 |
VERSION CONTROL HISTORY
|
Description: A buffered socket class
Limitations: None
|
~CBSOCK Description: CBSock class destructor Limitations: None |
|
GetPendingUDPBytes. Description: This function returns the number of bytes that can can be read by ReadUDP.
|
|
Peek. Description: Returns true if a message is waiting to be read
|
|
PeekSize. Description: Will return the number of bytes in the next message to be read
|
|
Peek. Description: Returns the type of the next message. If no message is available, MSG_INVALID is returned. Always use this function in conjunction with Peek().
|
|
PingConnection. Description: Sends a test message to the connection to see if it is still alive
|
|
Process. Description: This function will read in data from the socket and place it into the queue. It will also write data from the queue and send it out over the socket.
|
|
ProcessRead. Description: This function will read in data from the socket and place it into the queue. It will also write data from the queue and send it out over the socket
|
|
ProcessSend. Description: This function will read in data from the socket and place it into the queue. It will also write data from the queue and send it out over the socket.
|
|
ReadNext. Description: Fills in the arguments passed into it with the values of the next message
|
|
WriteNext. Description: Adds the message into the queue to be sent out the socket
|
|
VERSION CONTROL HISTORY
Revision 1.21 2005/04/15 04:13:33 plh844 Updated the address functions representative of an array of uint8s Revision 1.20 2005/04/14 04:06:25 mab6d5 Fixed the ProcessSend and ProcessRead functions so that they preserve the m_bIsBufferPacked variable value of the messages. Revision 1.19 2005/04/14 03:25:58 plh844 Address functions now use the in_addr struct. Revision 1.18 2005/04/11 01:10:49 plh844 Added public accessors for the address and port variables. Revision 1.17 2005/04/10 21:28:51 plh844 Added functions that return an address/port associated with an accepted socket. Revision 1.16 2005/03/19 00:21:39 kjm266 BSock changed to support new message copying requirements. Timers were added to prevent infinite looping. Extra function returns created for WOULD_BLOCK. etc. Revision 1.15 2005/03/08 05:57:40 plh844 Fixed two compilation bugs. Revision 1.14 2005/03/08 05:04:09 plh844 Updated the includes to point to the right files (case senetive names). Revision 1.13 2005/03/07 16:01:20 tcsvw5 Updated ProcessRead and ProcessSend to send the message buffer along with the message. Revision 1.12 2005/02/15 22:40:10 cafene Travis Service: Updated variable and function names to conform to our standard Revision 1.11 2005/02/15 20:41:47 kjm266 Added functionality to support datagram socket creation. Added the Bind, GetUDPPendingBytes, ReadUDP and WriteUDP functions. Revision 1.10 2005/02/09 21:50:21 bjsk3b Made Send, Recv, and GetPendingBytes pure virtual functions. Made ProcessSend, ProcessRead, and PingConnection non-virtual member functions Revision 1.9 2005/02/08 20:19:31 mab6d5 Fixed a logic error where in the ReadNext function where the message was deleted before it was copied. Revision 1.8 2005/02/08 06:27:56 mab6d5 Fixed the initialization of the mutex variable. Revision 1.7 2005/02/07 02:21:42 cafene Added the Accept pure virtual function. Also changed the type of the MSG_HEADER_SIZE static const to an unsigned int. Revision 1.00. 01/27/2005 09:55PM. Brian Shaver. Initial Revision |