PPTConnection Class Reference

#include <PPTConnection.h>

Inheritance diagram for PPTConnection:

Inheritance graph
[legend]
Collaboration diagram for PPTConnection:

Collaboration graph
[legend]
List of all members.

Public Member Functions

virtual ~PPTConnection ()
virtual void initConnection ()=0
virtual void closeConnection ()=0
virtual void send (const string &buffer)
virtual void sendExit ()
virtual bool receive (ostream *strm=0)
virtual void dump (ostream &strm) const
 dumps information about this object
virtual SocketgetSocket ()
virtual bool isConnected ()
virtual void setOutputStream (ostream *strm)
virtual ostream * getOutputStream ()
virtual void brokenPipe ()

Protected Member Functions

 PPTConnection (int timeout)
void writeBuffer (const string &buffer)
int readBuffer (char *inBuff)
int readBufferNonBlocking (char *inBuff)

Protected Attributes

Socket_mySock
ostream * _out
bool _brokenPipe

Detailed Description

Definition at line 40 of file PPTConnection.h.


Constructor & Destructor Documentation

PPTConnection::PPTConnection ( int  timeout  )  [inline, protected]

Definition at line 47 of file PPTConnection.h.

virtual PPTConnection::~PPTConnection (  )  [inline, virtual]

Definition at line 54 of file PPTConnection.h.


Member Function Documentation

void PPTConnection::writeBuffer ( const string &  buffer  )  [protected]

Definition at line 63 of file PPTConnection.cc.

References Connection::_mySock, and Socket::send().

Referenced by PPTClient::initConnection(), send(), and sendExit().

Here is the call graph for this function:

int PPTConnection::readBuffer ( char *  inBuff  )  [protected]

Definition at line 289 of file PPTConnection.cc.

References Connection::_mySock, PPT_PROTOCOL_BUFFER_SIZE, and Socket::receive().

Referenced by readBufferNonBlocking(), and receive().

Here is the call graph for this function:

int PPTConnection::readBufferNonBlocking ( char *  inBuff  )  [protected]

Definition at line 295 of file PPTConnection.cc.

References Connection::getSocket(), Socket::getSocketDescriptor(), and readBuffer().

Referenced by PPTClient::initConnection().

Here is the call graph for this function:

virtual void PPTConnection::initConnection (  )  [pure virtual]

Implements Connection.

Implemented in PPTClient, and PPTServer.

virtual void PPTConnection::closeConnection (  )  [pure virtual]

Implements Connection.

Implemented in PPTClient, and PPTServer.

void PPTConnection::send ( const string &  buffer  )  [virtual]

Implements Connection.

Definition at line 47 of file PPTConnection.cc.

References PPTProtocol::PPT_COMPLETE_DATA_TRANSMITION, and writeBuffer().

Referenced by CmdClient::executeCommand().

Here is the call graph for this function:

void PPTConnection::sendExit (  )  [virtual]

Implements Connection.

Definition at line 57 of file PPTConnection.cc.

References PPTProtocol::PPT_EXIT_NOW, and writeBuffer().

Referenced by PPTClient::closeConnection().

Here is the call graph for this function:

bool PPTConnection::receive ( ostream *  strm = 0  )  [virtual]

Implements Connection.

Definition at line 136 of file PPTConnection.cc.

References Connection::_out, PPTMarkFinder::getMarkIndex(), PPTMarkFinder::markCheck(), PPTProtocol::PPT_COMPLETE_DATA_TRANSMITION, PPTProtocol::PPT_EXIT_NOW, PPT_PROTOCOL_BUFFER_SIZE, and readBuffer().

Referenced by CmdClient::executeCommand().

Here is the call graph for this function:

void PPTConnection::dump ( ostream &  strm  )  const [virtual]

dumps information about this object

Displays the pointer value of this instance

Parameters:
strm C++ i/o stream to dump the information to

Reimplemented from Connection.

Reimplemented in PPTClient, and PPTServer.

Definition at line 338 of file PPTConnection.cc.

References Connection::dump(), BESIndent::Indent(), BESIndent::LMarg(), and BESIndent::UnIndent().

Referenced by PPTServer::dump(), and PPTClient::dump().

Here is the call graph for this function:

virtual Socket* Connection::getSocket (  )  [inline, virtual, inherited]

Definition at line 66 of file Connection.h.

References Connection::_mySock.

Referenced by readBufferNonBlocking().

virtual bool Connection::isConnected (  )  [inline, virtual, inherited]

Definition at line 71 of file Connection.h.

References Connection::_mySock, and Socket::isConnected().

Referenced by CmdClient::isConnected().

Here is the call graph for this function:

virtual void Connection::setOutputStream ( ostream *  strm  )  [inline, virtual, inherited]

Definition at line 78 of file Connection.h.

References Connection::_out.

virtual ostream* Connection::getOutputStream (  )  [inline, virtual, inherited]

Definition at line 82 of file Connection.h.

References Connection::_out.

virtual void Connection::brokenPipe (  )  [inline, virtual, inherited]

Definition at line 87 of file Connection.h.

References Connection::_brokenPipe.

Referenced by CmdClient::brokenPipe().


Member Data Documentation

Socket* Connection::_mySock [protected, inherited]

Definition at line 48 of file Connection.h.

Referenced by PPTServer::closeConnection(), PPTClient::closeConnection(), Connection::dump(), Connection::getSocket(), PPTServer::initConnection(), Connection::isConnected(), PPTClient::PPTClient(), readBuffer(), writeBuffer(), and PPTClient::~PPTClient().

ostream* Connection::_out [protected, inherited]

Definition at line 49 of file Connection.h.

Referenced by Connection::dump(), Connection::getOutputStream(), receive(), and Connection::setOutputStream().

bool Connection::_brokenPipe [protected, inherited]

Definition at line 50 of file Connection.h.

Referenced by Connection::brokenPipe(), PPTClient::closeConnection(), and Connection::dump().


The documentation for this class was generated from the following files:
Generated on Fri Nov 30 12:14:47 2007 for OPeNDAP Back End Server (BES) by  doxygen 1.5.1