Made to Order Software Corporation Logo

LLChatLib: LLIOSocketReader Class Reference

LLIOSocketReader Class Reference

An LLIOPipe implementation which reads from a socket. More...

#include <lliosocket.h>

Inheritance diagram for LLIOSocketReader:
Collaboration diagram for LLIOSocketReader:

List of all members.

Public Member Functions

 LLIOSocketReader (LLSocket::ptr_t socket)

Protected Member Functions

virtual EStatus process_impl (const LLChannelDescriptors &channels, buffer_ptr_t &buffer, bool &eos, LLSD &context, LLPumpIO *pump)
 Process the data coming in the socket.


Detailed Description

An LLIOPipe implementation which reads from a socket.

See also:
LLIOPipe

An instance of a socket reader wraps around an LLSocket and performs non-blocking reads and passes it to the next pipe in the chain.


Constructor & Destructor Documentation

LLIOSocketReader::LLIOSocketReader ( LLSocket::ptr_t  socket  ) 

Member Function Documentation

LLIOPipe::EStatus LLIOSocketReader::process_impl ( const LLChannelDescriptors channels,
buffer_ptr_t buffer,
bool &  eos,
LLSD context,
LLPumpIO pump 
) [protected, virtual]

Process the data coming in the socket.

Since the socket and next pipe must exist for process to make any sense, this method will return STATUS_PRECONDITION_NOT_MET unless if they are not known. If a STATUS_STOP returned by the next link in the chain, this reader will turn of the socket polling.

Parameters:
buffer Pointer to a buffer which needs processing. Probably NULL.
bytes Number of bytes to in buffer to process. Probably 0.
eos True if this function is the last. Almost always false.
read Number of bytes actually processed.
pump The pump which is calling process. May be NULL.
context A data structure to pass structured data
Returns:
STATUS_OK unless the preconditions are not met.

Implements LLIOPipe.

Here is the call graph for this function:


The documentation for this class was generated from the following files:
  • /home/doug/src/oss/slitechat/trunk/LLChatLib/llmessage/lliosocket.h
  • /home/doug/src/oss/slitechat/trunk/LLChatLib/llmessage/lliosocket.cpp
Generated on Thu Sep 23 17:18:42 2010 for LLChatLib by  doxygen 1.6.3