gloox
1.0
|
#include <stanza.h>
Public Member Functions | |
virtual | ~Stanza () |
void | setFrom (const JID &from) |
const JID & | from () const |
const JID & | to () const |
const std::string & | id () const |
const Error * | error () const |
const std::string & | xmlLang () const |
void | addExtension (const StanzaExtension *se) |
const StanzaExtension * | findExtension (int type) const |
template<class T > | |
const T * | findExtension (int type) const |
const StanzaExtensionList & | extensions () const |
void | removeExtensions () |
virtual Tag * | tag () const =0 |
Protected Member Functions | |
Stanza (Tag *tag) | |
Stanza (const JID &to) |
This is the base class for XMPP stanza abstractions.
~Stanza | ( | ) | [virtual] |
Virtual destructor.
Definition at line 42 of file stanza.cpp.
Creates a new Stanza object and initializes the receiver's JID.
to | The receipient of the Stanza. |
Definition at line 26 of file stanza.cpp.
void addExtension | ( | const StanzaExtension * | se | ) |
Use this function to add a StanzaExtension to this Stanza.
se | The StanzaExtension to add. |
Definition at line 52 of file stanza.cpp.
A convenience function that returns the stanza error condition, if any.
Definition at line 47 of file stanza.cpp.
const StanzaExtensionList& extensions | ( | ) | const [inline] |
const StanzaExtension * findExtension | ( | int | type | ) | const |
Finds a StanzaExtension of a particular type.
type | StanzaExtensionType to search for. |
Definition at line 57 of file stanza.cpp.
const T* findExtension | ( | int | type | ) | const [inline] |
Finds a StanzaExtension of a particular type. Example:
const MyExtension* c = presence.findExtension<MyExtension>( ExtMyExt );
type | The extension type to look for. |
const std::string& id | ( | ) | const [inline] |
void removeExtensions | ( | ) |
Removes (deletes) all the stanza's extensions.
Definition at line 64 of file stanza.cpp.
Sets the 'from' address of the Stanza. This useful for Components .
from | The from address. |
const std::string& xmlLang | ( | ) | const [inline] |