reSIProcate/stack  9694
Public Types | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | Static Private Attributes | Friends
resip::ConnectionBase Class Reference

Abstracts some of the connection functionality. More...

#include <ConnectionBase.hxx>

Inheritance diagram for resip::ConnectionBase:
Inheritance graph
[legend]
Collaboration diagram for resip::ConnectionBase:
Collaboration graph
[legend]

List of all members.

Public Types

enum  { ChunkSize = 2048 }

Public Member Functions

 ConnectionBase (Transport *transport, const Tuple &who, Compression &compression=Compression::Disabled)
FlowKey getFlowKey () const
virtual Transporttransport () const
Tuplewho ()
const UInt64whenLastUsed ()
void resetLastUsed ()

Protected Types

enum  ConnState {
  NewMessage = 0, ReadingHeaders, PartialBody, SigComp,
  MAX
}
enum  TransmissionFormat { Unknown, Uncompressed, Compressed }

Protected Member Functions

ConnState getCurrentState () const
bool preparseNewBytes (int bytesRead)
void decompressNewBytes (int bytesRead)
std::pair< char *, size_t > getWriteBuffer ()
std::pair< char *, size_t > getCurrentWriteBuffer ()
char * getWriteBufferForExtraBytes (int extraBytes)
void setBuffer (char *bytes, int count)
void setFailureReason (TransportFailure::FailureReason failReason, int subCode)
virtual ~ConnectionBase ()
virtual void onDoubleCRLF ()
virtual void onSingleCRLF ()

Protected Attributes

Data::size_type mSendPos
std::list< SendData * > mOutstandingSends
TransportmTransport
Tuple mWho
TransportFailure::FailureReason mFailureReason
int mFailureSubCode
CompressionmCompression
osc::Stack * mSigcompStack
osc::TcpStream * mSigcompFramer
TransmissionFormat mSendingTransmissionFormat
TransmissionFormat mReceivingTransmissionFormat

Private Member Functions

 ConnectionBase ()
 ConnectionBase (const Connection &)
ConnectionBaseoperator= (const Connection &)

Private Attributes

SipMessagemMessage
char * mBuffer
size_t mBufferPos
size_t mBufferSize
UInt64 mLastUsed
ConnState mConnState
MsgHeaderScanner mMsgHeaderScanner

Static Private Attributes

static char connectionStates [MAX][32] = { "NewMessage", "ReadingHeaders", "PartialBody" }

Friends

EncodeStreamoperator<< (EncodeStream &strm, const resip::ConnectionBase &c)

Detailed Description

Abstracts some of the connection functionality.

Managed connections (see ConnectionManager) derive from Connection. Non-managed connections may be derived from ConnectionBase.

Todo:
check id connectionId makes sense here

Definition at line 35 of file ConnectionBase.hxx.


Member Enumeration Documentation

anonymous enum
Enumerator:
ChunkSize 

Definition at line 51 of file ConnectionBase.hxx.

{ ChunkSize = 2048 }; // !jf! what is the optimal size here?
Enumerator:
NewMessage 
ReadingHeaders 
PartialBody 
SigComp 
MAX 

Definition at line 54 of file ConnectionBase.hxx.

      {
         NewMessage = 0,
         ReadingHeaders,
         PartialBody,
         SigComp, // This indicates that incoming bytes are compressed.
         MAX
      };
Enumerator:
Unknown 
Uncompressed 
Compressed 

Definition at line 63 of file ConnectionBase.hxx.


Constructor & Destructor Documentation

ConnectionBase::ConnectionBase ( Transport transport,
const Tuple who,
Compression compression = Compression::Disabled 
)

Definition at line 30 of file ConnectionBase.cxx.

References resip::Compression::addCompressorsToStack(), DebugLog, resip::Transport::getKey(), resip::Compression::getStateHandler(), resip::Compression::isEnabled(), mCompression, mSigcompStack, mTransport, mWho, resip::Tuple::transport, and resip::Tuple::transportKey.

   : mSendPos(0),
     mTransport(transport),
     mWho(who),
     mFailureReason(TransportFailure::None),
     mFailureSubCode(0),
     mCompression(compression),
// NO: #ifdef USE_SIGCOMP // class def doesn't decl members conditionally
     mSigcompStack(0),
     mSigcompFramer(0),
// NO: #endif
     mSendingTransmissionFormat(Unknown),
     mReceivingTransmissionFormat(Unknown),
     mMessage(0),
     mBuffer(0),
     mBufferPos(0),
     mBufferSize(0),
     mLastUsed(Timer::getTimeMs()),
     mConnState(NewMessage)
{
   DebugLog (<< "ConnectionBase::ConnectionBase, who: " << mWho << " " << this);
#ifdef USE_SIGCOMP
   if (mCompression.isEnabled())
   {
      DebugLog (<< "Compression enabled for connection: " << this);
      mSigcompStack = new osc::Stack(mCompression.getStateHandler());
      mCompression.addCompressorsToStack(mSigcompStack);
   }
   else
   {
      DebugLog (<< "Compression disabled for connection: " << this);
   }
#else
   DebugLog (<< "No compression library available: " << this);
#endif

   // deprecated; stop doing this eventually
   mWho.transport=mTransport;
   mWho.transportKey=mTransport ? mTransport->getKey() : 0;
}

Here is the call graph for this function:

ConnectionBase::~ConnectionBase ( ) [protected, virtual]

Definition at line 71 of file ConnectionBase.cxx.

References resip::TransportFailure::ConnectionUnknown, DebugLog, resip::Transport::fail(), resip::Transport::flowTerminated(), mBuffer, mFailureReason, mFailureSubCode, mMessage, mOutstandingSends, mSigcompStack, mTransport, mWho, and resip::SendData::transactionId.

{
   if(mTransport)
   {
      mTransport->flowTerminated(mWho);
   }

   while (!mOutstandingSends.empty())
   {
      SendData* sendData = mOutstandingSends.front();
      mTransport->fail(sendData->transactionId,
         mFailureReason ? mFailureReason : TransportFailure::ConnectionUnknown,
         mFailureSubCode);
      delete sendData;
      mOutstandingSends.pop_front();
   }
   delete [] mBuffer;
   delete mMessage;
#ifdef USE_SIGCOMP
   delete mSigcompStack;
#endif

   DebugLog (<< "ConnectionBase::~ConnectionBase " << this);
}

Here is the call graph for this function:

resip::ConnectionBase::ConnectionBase ( ) [private]
resip::ConnectionBase::ConnectionBase ( const Connection ) [private]

Member Function Documentation

void resip::ConnectionBase::decompressNewBytes ( int  bytesRead) [protected]

Referenced by resip::Connection::read().

ConnState resip::ConnectionBase::getCurrentState ( ) const [inline, protected]

Definition at line 70 of file ConnectionBase.hxx.

References mConnState.

{ return mConnState; }
std::pair< char *, size_t > ConnectionBase::getCurrentWriteBuffer ( ) [protected]

Definition at line 672 of file ConnectionBase.cxx.

References mBuffer, mBufferPos, and mBufferSize.

Referenced by getWriteBuffer(), and resip::Connection::read().

{
   return std::make_pair(mBuffer + mBufferPos, mBufferSize - mBufferPos);
}
FlowKey ConnectionBase::getFlowKey ( ) const

Definition at line 107 of file ConnectionBase.cxx.

References resip::Tuple::mFlowKey, and mWho.

{
   return mWho.mFlowKey;
}
std::pair< char *, size_t > ConnectionBase::getWriteBuffer ( ) [protected]
char * ConnectionBase::getWriteBufferForExtraBytes ( int  extraBytes) [protected]

Definition at line 678 of file ConnectionBase.cxx.

References resip::MsgHeaderScanner::allocateBuffer(), mBuffer, and mBufferSize.

Referenced by resip::TlsConnection::read().

{
   if (extraBytes > 0)
   {
      char* buffer = MsgHeaderScanner::allocateBuffer((int)mBufferSize + extraBytes);
      memcpy(buffer, mBuffer, mBufferSize);
      delete [] mBuffer;
      mBuffer = buffer;
      buffer += mBufferSize;
      mBufferSize += extraBytes;
      return buffer;
   }
   else
   {
      assert(0);
      return mBuffer;
   }
}

Here is the call graph for this function:

virtual void resip::ConnectionBase::onDoubleCRLF ( ) [inline, protected, virtual]

Reimplemented in resip::Connection.

Definition at line 92 of file ConnectionBase.hxx.

Referenced by preparseNewBytes().

{}
virtual void resip::ConnectionBase::onSingleCRLF ( ) [inline, protected, virtual]

Reimplemented in resip::Connection.

Definition at line 93 of file ConnectionBase.hxx.

Referenced by preparseNewBytes().

{}
ConnectionBase& resip::ConnectionBase::operator= ( const Connection ) [private]

Reimplemented in resip::Connection.

bool ConnectionBase::preparseNewBytes ( int  bytesRead) [protected]

Definition at line 113 of file ConnectionBase.cxx.

References resip::SipMessage::addBuffer(), resip::MsgHeaderScanner::allocateBuffer(), ChunkSize, connectionStates, resip::SipMessage::const_header(), resip::Symbols::CRLF, resip::Symbols::CRLFCRLF, DebugLog, ErrLog, resip::Transport::getExpectedWaitForIncoming(), resip::MsgHeaderScanner::getHeaderCount(), resip::TlsConnection::getPeerNames(), resip::Transport::getRejectionBehaviorForIncoming(), resip::SipMessage::isRequest(), resip::Transport::make503(), mBuffer, mBufferPos, mBufferSize, mConnState, mMessage, mMsgHeaderScanner, mTransport, mWho, NewMessage, onDoubleCRLF(), onSingleCRLF(), PartialBody, resip::MsgHeaderScanner::prepareForMessage(), resip::Transport::pushRxMsgUp(), ReadingHeaders, resip::CongestionManager::REJECTING_NEW_WORK, resip::CongestionManager::REJECTING_NON_ESSENTIAL, resip::resipMax(), resip::resipMin(), resip::MsgHeaderScanner::scanChunk(), resip::MsgHeaderScanner::scrError, resip::MsgHeaderScanner::scrNextChunk, resip::Transport::send(), resip::SipMessage::setBody(), resip::SipMessage::setSource(), resip::SipMessage::setTlsDomain(), resip::SipMessage::setTlsPeerNames(), resip::Transport::stampReceived(), resip::Transport::tlsDomain(), transport(), and WarningLog.

Referenced by resip::Connection::read().

{
   DebugLog(<< "In State: " << connectionStates[mConnState]);
   
  start:   // If there is an overhang come back here, effectively recursing
   
   switch(mConnState)
   {
      case NewMessage:
      {
         if (strncmp(mBuffer + mBufferPos, Symbols::CRLFCRLF, 4) == 0)
         {
            DebugLog(<< "Got incoming double-CRLF keepalive (aka ping).");
            mBufferPos += 4;
            bytesRead -= 4;
            onDoubleCRLF();
            if (bytesRead)
            {
               goto start;
            }
            else
            {
               delete [] mBuffer;
               mBuffer = 0;
               return true;
            }
         }
         else if (strncmp(mBuffer + mBufferPos, Symbols::CRLF, 2) == 0)
         {
            //DebugLog(<< "Got incoming CRLF keepalive response (aka pong).");
            mBufferPos += 2;
            bytesRead -= 2;
            onSingleCRLF();
            if (bytesRead)
            {
               goto start;
            }
            else
            {
               delete [] mBuffer;
               mBuffer = 0;
               return true;
            }
         }

         assert(mTransport);
         mMessage = new SipMessage(mTransport);
         
         DebugLog(<< "ConnectionBase::process setting source " << mWho);
         mMessage->setSource(mWho);
         mMessage->setTlsDomain(mTransport->tlsDomain());

#ifdef USE_SSL
         // Set TlsPeerName if message is from TlsConnection
         TlsConnection *tlsConnection = dynamic_cast<TlsConnection *>(this);
         if(tlsConnection)
         {
            std::list<Data> peerNameList;
            tlsConnection->getPeerNames(peerNameList);
            mMessage->setTlsPeerNames(peerNameList);
         }
#endif
         mMsgHeaderScanner.prepareForMessage(mMessage);
         // Fall through to the next case.
      }
      case ReadingHeaders:
      {
         unsigned int chunkLength = (unsigned int)mBufferPos + bytesRead;
         char *unprocessedCharPtr;
         MsgHeaderScanner::ScanChunkResult scanChunkResult =
            mMsgHeaderScanner.scanChunk(mBuffer,
                                        chunkLength,
                                        &unprocessedCharPtr);
         if (scanChunkResult == MsgHeaderScanner::scrError)
         {
            //.jacob. Not a terribly informative warning.
            WarningLog(<< "Discarding preparse!");
            delete [] mBuffer;
            mBuffer = 0;
            delete mMessage;
            mMessage = 0;
            mConnState=NewMessage;
            return false;
         }

         if (mMsgHeaderScanner.getHeaderCount() > 256)
         {
            WarningLog(<< "Discarding preparse; too many headers");
            delete [] mBuffer;
            mBuffer = 0;
            delete mMessage;
            mMessage = 0;
            mConnState=NewMessage;
            return false;
         }

         unsigned int numUnprocessedChars = 
            (unsigned int)((mBuffer + chunkLength) - unprocessedCharPtr);

         if(numUnprocessedChars > 2048 &&
            scanChunkResult == MsgHeaderScanner::scrNextChunk)
         {
            WarningLog(<< "Discarding preparse; header-field-value (or "
                        "header name) too long");
            delete [] mBuffer;
            mBuffer = 0;
            delete mMessage;
            mMessage = 0;
            mConnState=NewMessage;
            return false;
         }

         if(numUnprocessedChars==chunkLength)
         {
            // .bwc. MsgHeaderScanner wasn't able to parse anything useful;
            // don't bother mMessage yet, but make more room in mBuffer.
            size_t size = numUnprocessedChars*3/2;
            if (size < ConnectionBase::ChunkSize)
            {
               size = ConnectionBase::ChunkSize;
            }
            char* newBuffer = 0;
            try
            {
               newBuffer=MsgHeaderScanner::allocateBuffer((int)size);
            }
            catch(std::bad_alloc&)
            {
               ErrLog(<<"Failed to alloc a buffer during preparse!");
               return false;
            }
            memcpy(newBuffer, unprocessedCharPtr, numUnprocessedChars);
            delete [] mBuffer;
            mBuffer = newBuffer;
            mBufferPos = numUnprocessedChars;
            mBufferSize = size;
            mConnState = ReadingHeaders;
            return true;
         }

         mMessage->addBuffer(mBuffer);
         mBuffer=0;

         if (scanChunkResult == MsgHeaderScanner::scrNextChunk)
         {
            // Message header is incomplete...
            if (numUnprocessedChars == 0)
            {
               // ...but the chunk is completely processed.
               //.jacob. I've discarded the "assigned" concept.
               //DebugLog(<< "Data assigned, not fragmented, not complete");
               try
               {
                  mBuffer = MsgHeaderScanner::allocateBuffer(ChunkSize);
               }
               catch(std::bad_alloc&)
               {
                  ErrLog(<<"Failed to alloc a buffer during preparse!");
                  return false;
               }
               mBufferPos = 0;
               mBufferSize = ChunkSize;
            }
            else
            {
               // ...but some of the chunk must be shifted into the next one.
               size_t size = numUnprocessedChars*3/2;
               if (size < ConnectionBase::ChunkSize)
               {
                  size = ConnectionBase::ChunkSize;
               }
               char* newBuffer = 0;
               try
               {
                  newBuffer = MsgHeaderScanner::allocateBuffer((int)size);
               }
               catch(std::bad_alloc&)
               {
                  ErrLog(<<"Failed to alloc a buffer during preparse!");
                  return false;
               }
               memcpy(newBuffer, unprocessedCharPtr, numUnprocessedChars);
               mBuffer = newBuffer;
               mBufferPos = numUnprocessedChars;
               mBufferSize = size;
            }
            mConnState = ReadingHeaders;
         }
         else
         {
            size_t contentLength = 0;
            
            try
            {
               // The message header is complete.
               contentLength=mMessage->const_header(h_ContentLength).value();
            }
            catch(resip::BaseException& e)  // Could be SipMessage::Exception or ParseException
            {
               WarningLog(<<"Malformed Content-Length in connection-based transport"
                           ". Not much we can do to fix this.  " << e);
               // .bwc. Bad Content-Length. We are hosed.
               delete mMessage;
               mMessage = 0;
               mBuffer = 0;
               // .bwc. mMessage just took ownership of mBuffer, so we don't
               // delete it here. We do zero it though, for completeness.
               //.jacob. Shouldn't the state also be set here?
               return false;
            }
            
            if(contentLength > 10485760 || contentLength < 0)
            {
               // !bwc! No more than 10M, thanks. We should make this
               // configurable.
               WarningLog(<<"Absurdly large Content-Length in connection-based "
                           "transport.");
               delete mMessage;
               mMessage = 0;
               mBuffer = 0;
               // .bwc. mMessage just took ownership of mBuffer, so we don't
               // delete it here. We do zero it though, for completeness.
               //.jacob. Shouldn't the state also be set here?
               return false;
            }

            if (numUnprocessedChars < contentLength)
            {
               // The message body is incomplete.
               DebugLog(<< "partial body received");
               size_t newSize=resipMin(resipMax((size_t)numUnprocessedChars*3/2,
                                             (size_t)ConnectionBase::ChunkSize),
                                    contentLength);
               char* newBuffer = MsgHeaderScanner::allocateBuffer((int)newSize);
               memcpy(newBuffer, unprocessedCharPtr, numUnprocessedChars);
               mBufferPos = numUnprocessedChars;
               mBufferSize = newSize;
               mBuffer = newBuffer;
               
               mConnState = PartialBody;
            }
            else
            {
               // Do this stuff BEFORE we kick the message out the door.
               // Remember, deleting or passing mMessage on invalidates our
               // buffer!
               int overHang = numUnprocessedChars - (int)contentLength;

               mConnState = NewMessage;
               mBuffer = 0;
               if (overHang > 0) 
               {
                  // The next message has been partially read.
                  size_t size = overHang*3/2;
                  if (size < ConnectionBase::ChunkSize)
                  {
                     size = ConnectionBase::ChunkSize;
                  }
                  char* newBuffer = MsgHeaderScanner::allocateBuffer((int)size);
                  memcpy(newBuffer,
                         unprocessedCharPtr + contentLength,
                         overHang);
                  mBuffer = newBuffer;
                  mBufferPos = 0;
                  mBufferSize = size;
                  
                  DebugLog (<< "Extra bytes after message: " << overHang);
                  DebugLog (<< Data(mBuffer, overHang));
                  
                  bytesRead = overHang;
               }

               // The message body is complete.
               mMessage->setBody(unprocessedCharPtr, (UInt32)contentLength);
               CongestionManager::RejectionBehavior b=mTransport->getRejectionBehaviorForIncoming();
               if (b==CongestionManager::REJECTING_NON_ESSENTIAL
                     || (b==CongestionManager::REJECTING_NEW_WORK
                        && mMessage->isRequest()))
               {
                  UInt32 expectedWait(mTransport->getExpectedWaitForIncoming());
                  // .bwc. If this fifo is REJECTING_NEW_WORK, we will drop
                  // requests but not responses ( ?bwc? is this right for ACK?). 
                  // If we are REJECTING_NON_ESSENTIAL, 
                  // we reject all incoming work, since losing something from the 
                  // wire will not cause instability or leaks (see 
                  // CongestionManager.hxx)
                  
                  // .bwc. This handles all appropriate checking for whether
                  // this is a response or an ACK.
                  std::auto_ptr<SendData> tryLater(transport()->make503(*mMessage, expectedWait/1000));
                  if(tryLater.get())
                  {
                     transport()->send(tryLater);
                  }
                  delete mMessage; // dropping message due to congestion
                  mMessage = 0;
               }
               else if (!transport()->basicCheck(*mMessage))
               {
                  delete mMessage;
                  mMessage = 0;
               }
               else
               {
                  Transport::stampReceived(mMessage);
                  DebugLog(<< "##Connection: " << *this << " received: " << *mMessage);
                  assert( mTransport );
                  mTransport->pushRxMsgUp(mMessage);
                  mMessage = 0;
               }

               if (overHang > 0) 
               {
                  goto start;
               }
            }
         }
         break;
      }
      case PartialBody:
      {
         size_t contentLength = 0;

         try
         {
             contentLength = mMessage->const_header(h_ContentLength).value();
         }
         catch(resip::BaseException& e)  // Could be SipMessage::Exception or ParseException
         {
            WarningLog(<<"Malformed Content-Length in connection-based transport"
                        ". Not much we can do to fix this. " << e);
            // .bwc. Bad Content-Length. We are hosed.
            delete [] mBuffer;
            mBuffer = 0;
            delete mMessage;
            mMessage = 0;
            //.jacob. Shouldn't the state also be set here?
            return false;
         }

         mBufferPos += bytesRead;
         if (mBufferPos == contentLength)
         {
            mMessage->addBuffer(mBuffer);
            mMessage->setBody(mBuffer, (UInt32)contentLength);
            mBuffer=0;
            // .bwc. basicCheck takes up substantial CPU. Don't bother doing it
            // if we're overloaded.
            CongestionManager::RejectionBehavior b=mTransport->getRejectionBehaviorForIncoming();
            if (b==CongestionManager::REJECTING_NON_ESSENTIAL
                  || (b==CongestionManager::REJECTING_NEW_WORK
                     && mMessage->isRequest()))
            {
               UInt32 expectedWait(mTransport->getExpectedWaitForIncoming());
               // .bwc. If this fifo is REJECTING_NEW_WORK, we will drop
               // requests but not responses ( ?bwc? is this right for ACK?). 
               // If we are REJECTING_NON_ESSENTIAL, 
               // we reject all incoming work, since losing something from the 
               // wire will not cause instability or leaks (see 
               // CongestionManager.hxx)
               
               // .bwc. This handles all appropriate checking for whether
               // this is a response or an ACK.
               std::auto_ptr<SendData> tryLater = transport()->make503(*mMessage, expectedWait/1000);
               if(tryLater.get())
               {
                  transport()->send(tryLater);
               }
               delete mMessage; // dropping message due to congestion
               mMessage = 0;
            }
            else if (!transport()->basicCheck(*mMessage))
            {
               delete mMessage;
               mMessage = 0;
            }
            else
            {
               DebugLog(<< "##ConnectionBase: " << *this << " received: " << *mMessage);

               Transport::stampReceived(mMessage);
               assert( mTransport );
               mTransport->pushRxMsgUp(mMessage);
               mMessage = 0;
            }
            mConnState = NewMessage;
         }
         else if (mBufferPos == mBufferSize)
         {
            // .bwc. We've filled our buffer; go ahead and make more room.
            size_t newSize = resipMin(mBufferSize*3/2, contentLength);
            char* newBuffer = 0;
            try
            {
               newBuffer=new char[newSize];
            }
            catch(std::bad_alloc&)
            {
               ErrLog(<<"Failed to alloc a buffer while receiving body!");
               return false;
            }
            memcpy(newBuffer, mBuffer, mBufferSize);
            mBufferSize=newSize;
            delete [] mBuffer;
            mBuffer = newBuffer;
         }
         break;
      }
      default:
         assert(0);
   }
   return true;
}

Here is the call graph for this function:

void resip::ConnectionBase::resetLastUsed ( ) [inline]

Definition at line 49 of file ConnectionBase.hxx.

References resip::Timer::getTimeMs(), and mLastUsed.

Referenced by resip::ConnectionManager::touch().

Here is the call graph for this function:

void ConnectionBase::setBuffer ( char *  bytes,
int  count 
) [protected]

Definition at line 698 of file ConnectionBase.cxx.

References mBuffer, mBufferPos, and mBufferSize.

{
   mBuffer = bytes;
   mBufferPos = 0;
   mBufferSize = count;
}
void ConnectionBase::setFailureReason ( TransportFailure::FailureReason  failReason,
int  subCode 
) [protected]

Definition at line 97 of file ConnectionBase.cxx.

References mFailureReason, and mFailureSubCode.

Referenced by resip::Connection::processPollEvent().

{
   if ( failReason > mFailureReason )
   {
      mFailureReason = failReason;
      mFailureSubCode = subCode;
   }
}
Transport * ConnectionBase::transport ( ) const [virtual]
const UInt64& resip::ConnectionBase::whenLastUsed ( ) [inline]

Definition at line 48 of file ConnectionBase.hxx.

References mLastUsed.

{ return mLastUsed; }
Tuple& resip::ConnectionBase::who ( ) [inline]

Definition at line 47 of file ConnectionBase.hxx.

References mWho.

Referenced by resip::ConnectionManager::addConnection(), and resip::TlsConnection::checkState().

{ return mWho; }

Friends And Related Function Documentation

EncodeStream& operator<< ( EncodeStream strm,
const resip::ConnectionBase c 
) [friend]

Member Data Documentation

char ConnectionBase::connectionStates = { "NewMessage", "ReadingHeaders", "PartialBody" } [static, private]

Definition at line 110 of file ConnectionBase.hxx.

Referenced by preparseNewBytes().

Definition at line 112 of file ConnectionBase.hxx.

Referenced by getCurrentState(), getWriteBuffer(), and preparseNewBytes().

Definition at line 97 of file ConnectionBase.hxx.

Referenced by setFailureReason(), and ~ConnectionBase().

Definition at line 111 of file ConnectionBase.hxx.

Referenced by resetLastUsed(), and whenLastUsed().

Definition at line 105 of file ConnectionBase.hxx.

Referenced by preparseNewBytes(), and ~ConnectionBase().

Definition at line 113 of file ConnectionBase.hxx.

Referenced by preparseNewBytes().

Definition at line 102 of file ConnectionBase.hxx.

Referenced by resip::Connection::read().

Definition at line 101 of file ConnectionBase.hxx.

Referenced by resip::Connection::performWrite().

Definition at line 80 of file ConnectionBase.hxx.

Referenced by resip::Connection::performWrite().

osc::TcpStream* resip::ConnectionBase::mSigcompFramer [protected]

Definition at line 100 of file ConnectionBase.hxx.

osc::Stack* resip::ConnectionBase::mSigcompStack [protected]

The documentation for this class was generated from the following files: