gloox  0.9.9.12
Public Member Functions | List of all members
MessageHandler Class Reference

#include <messagehandler.h>

Inheritance diagram for MessageHandler:
Inheritance graph
[legend]

Public Member Functions

virtual ~MessageHandler ()
virtual void handleMessage (Stanza *stanza, MessageSession *session=0)=0

Detailed Description

A virtual interface which can be reimplemented to receive incoming message stanzas.

Derived classes can be registered as MessageHandlers with a ClientBase or MessageSession instance. Upon an incoming Message packet handleMessage() will be called. If registered with a ClientBase this happens for every incoming message, regardless of the sender. With a MessageSession the registered handler will receive all messages originating from the Session's contact. See MessageSession for more details.

Author
Jakob Schroeter js@ca.nosp@m.maya.nosp@m..net

Definition at line 36 of file messagehandler.h.

Constructor & Destructor Documentation

virtual ~MessageHandler ( )
inlinevirtual

Virtual Destructor.

Definition at line 42 of file messagehandler.h.

Member Function Documentation

virtual void handleMessage ( Stanza stanza,
MessageSession session = 0 
)
pure virtual

Reimplement this function if you want to be notified about incoming messages.

Parameters
stanzaThe complete Stanza.
sessionIf this MessageHandler is used with a MessageSession, this parameter holds a pointer to that MessageSession.

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