#include <xmpp.h>
Inheritance diagram for XMPP::BaseStreamHandler:
Public Member Functions | |
BaseStreamHandler () | |
~BaseStreamHandler () | |
virtual PBoolean | Start (Transport *transport=0) |
virtual PBoolean | Stop (const PString &error=PString::Empty()) |
void | SetAutoReconnect (PBoolean b=true, long timeout=1000) |
PNotifierList & | ElementHandlers () |
Stream * | GetStream () |
virtual PBoolean | Write (const void *buf, PINDEX len) |
virtual PBoolean | Write (const PString &data) |
virtual PBoolean | Write (const PXML &pdu) |
virtual void | OnElement (PXML &pdu) |
virtual void | Main () |
User override function for the main execution routine of the thread. | |
Protected Member Functions | |
PDECLARE_NOTIFIER (Stream, BaseStreamHandler, OnOpen) | |
PDECLARE_NOTIFIER (Stream, BaseStreamHandler, OnClose) | |
Protected Attributes | |
Stream * | m_Stream |
PBoolean | m_AutoReconnect |
PTimeInterval | m_ReconnectTimeout |
PNotifierList | m_ElementHandlers |
XMPP::BaseStreamHandler::BaseStreamHandler | ( | ) |
XMPP::BaseStreamHandler::~BaseStreamHandler | ( | ) |
PNotifierList& XMPP::BaseStreamHandler::ElementHandlers | ( | ) | [inline] |
Stream* XMPP::BaseStreamHandler::GetStream | ( | ) | [inline] |
virtual void XMPP::BaseStreamHandler::Main | ( | ) | [virtual] |
User override function for the main execution routine of the thread.
A descendent class must provide the code that will be executed in the thread within this function.
Note that the correct way for a thread to terminate is to return from this function.
Implements PThread.
virtual void XMPP::BaseStreamHandler::OnElement | ( | PXML & | pdu | ) | [virtual] |
Reimplemented in XMPP::C2S::StreamHandler.
XMPP::BaseStreamHandler::PDECLARE_NOTIFIER | ( | Stream | , | |
BaseStreamHandler | , | |||
OnClose | ||||
) | [protected] |
XMPP::BaseStreamHandler::PDECLARE_NOTIFIER | ( | Stream | , | |
BaseStreamHandler | , | |||
OnOpen | ||||
) | [protected] |
void XMPP::BaseStreamHandler::SetAutoReconnect | ( | PBoolean | b = true , |
|
long | timeout = 1000 | |||
) |
Reimplemented in XMPP::C2S::StreamHandler.
virtual PBoolean XMPP::BaseStreamHandler::Stop | ( | const PString & | error = PString::Empty() |
) | [virtual] |
virtual PBoolean XMPP::BaseStreamHandler::Write | ( | const void * | buf, | |
PINDEX | len | |||
) | [virtual] |
PBoolean XMPP::BaseStreamHandler::m_AutoReconnect [protected] |
Stream* XMPP::BaseStreamHandler::m_Stream [protected] |