Yate
Public Member Functions | Public Attributes
XMPPFeatureList Class Reference

JID feature list. More...

#include <xmpputils.h>

Inheritance diagram for XMPPFeatureList:
ObjList GenObject

List of all members.

Public Member Functions

bool add (int xml, int feature, bool required=false)
bool add (int feature)
bool add (XMPPFeature *feature)
void reset ()
void add (XMPPFeatureList &list)
void fromStreamFeatures (XmlElement &xml)
void fromDiscoInfo (XmlElement &xml)
void remove (int feature)
XMPPFeatureget (int feature)
XMPPFeatureget (const String &feature)
XMPPFeatureSaslgetSasl ()
XMPPFeatureCompressgetCompress ()
XmlElementbuildStreamFeatures ()
XmlElementbuildDiscoInfo (const char *from, const char *to, const char *id, const char *node=0, const char *cap=0)
void add (XmlElement &xml)
void updateEntityCaps ()

Public Attributes

JIDIdentityList m_identities
String m_entityCapsHash

Detailed Description

JID feature list.

This class holds a list of JID features


Member Function Documentation

bool add ( int  xml,
int  feature,
bool  required = false 
) [inline]

Add a feature to the list

Parameters:
xmlXML element tag as enumeration
featureThe feature to add as enumeration
requiredTrue if this feature is required
Returns:
False if the given feature already exists
bool add ( int  feature) [inline]

Add a feature to the list

Parameters:
featureThe feature to add as enumeration
Returns:
False if the given feature already exists
bool add ( XMPPFeature feature) [inline]

Add a feature to the list. Destroy the received parameter if already in the list

Parameters:
featureThe feature to add
Returns:
False if the given feature already exists

References TelEngine::destruct().

void add ( XMPPFeatureList list)

Move a list of features to this list. Don't check duplicates

Parameters:
listThe source list
void add ( XmlElement xml)

Add this list to an xml element

Parameters:
xmlDestination element
XmlElement* buildDiscoInfo ( const char *  from,
const char *  to,
const char *  id,
const char *  node = 0,
const char *  cap = 0 
)

Build an iq query disco info result from this list

Parameters:
fromThe 'from' attribute
toThe 'to' attribute
idThe 'id' attribute
nodeOptional 'node' attribute
capOptional capability to be set as 'node' suffix
Returns:
XmlElement pointer

Build stream features from this list

Returns:
XmlElement pointer
void fromDiscoInfo ( XmlElement xml)

Re-build this list from disco info responses

Parameters:
xmlThe element to parse
void fromStreamFeatures ( XmlElement xml)

Re-build this list from stream features

Parameters:
xmlThe features element to parse
XMPPFeature* get ( int  feature)

Get a feature from the list

Parameters:
featureThe feature to get
Returns:
Pointer to the feature or 0 if it doesn't exists
XMPPFeature* get ( const String feature) [inline]

Get a feature from the list

Parameters:
featureThe feature name to find
Returns:
Pointer to the feature or 0 if it doesn't exists

References ObjList::get().

Get a XMPPFeatureCompress feature from list

Returns:
XMPPFeatureCompress pointer or 0 if not found

References TelEngine::YOBJECT().

XMPPFeatureSasl* getSasl ( ) [inline]

Get a XMPPFeatureSasl feature from list

Returns:
XMPPFeatureSasl pointer or 0 if not found

References TelEngine::YOBJECT().

void remove ( int  feature) [inline]

Remove a feature from the list

Parameters:
featureThe feature to remove

References ObjList::remove().

void reset ( ) [inline]

Clear data

void updateEntityCaps ( )

Update the entity capabilities hash


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