Home · All Namespaces · All Classes · Grouped Classes · Modules · Functions codeless banner

QCollectivePresenceInfo Class Reference
[QtBaseModule]

The QCollectivePresenceInfo class holds presence information for a contact. More...

    #include <QCollectivePresenceInfo>

Public Types

Public Functions


Detailed Description

The QCollectivePresenceInfo class holds presence information for a contact.

This class holds the presence information about a particular contact. This information is reported by the QCollectivePresence provider implementation. For protocols that support multiple presence states or multiple presence resources, it is up to the presence provider implementation to report the collated presence information. Presence provider implementations can choose to support custom fields in order to support more complex presence models. These fields can be set and accessed using the setProperties() and properties() methods. The use of such fields is implementation dependent.

See also QCollectivePresence.


Member Type Documentation

enum QCollectivePresenceInfo::PresenceType

This enum specifies the available presence state.

ConstantValueDescription
QCollectivePresenceInfo::None0The presence state is not specified
QCollectivePresenceInfo::Offline1The presence entity is offline
QCollectivePresenceInfo::Away3The presence entity is away for a short time from the resource and cannot have instant communications
QCollectivePresenceInfo::Online2The presence entity is online and available for communications
QCollectivePresenceInfo::ExtendedAway4This presence state signifies that the party is away for an extended period of time
QCollectivePresenceInfo::Hidden5The presence entity is hidden
QCollectivePresenceInfo::Busy6The presence entity is busy and should not be contacted


Member Function Documentation

QCollectivePresenceInfo::QCollectivePresenceInfo ( const QString & uri = QString() )

Constructs a QCollectivePresenceInfo object for a presence account with uri.

See also QCollectivePresence.

QCollectivePresenceInfo::QCollectivePresenceInfo ( const QCollectivePresenceInfo & other )

Creates a new QCollectivePresenceInfo object that is a copy of other.

QCollectivePresenceInfo::~QCollectivePresenceInfo ()

Destroys the presence acount object.

QString QCollectivePresenceInfo::avatar () const

Returns the avatar (buddy icon) filename from this entity.

See also setAvatar().

QStringList QCollectivePresenceInfo::capabilities () const

Returns the capabilities of the entity.

See also setCapabilities().

QString QCollectivePresenceInfo::displayName () const

Returns the display name for this presence account object.

See also setDisplayName().

bool QCollectivePresenceInfo::isNull () const

Returns true if uri() returns an empty string; otherwise returns false.

QDateTime QCollectivePresenceInfo::lastUpdateTime () const

Returns the last updated time of this entity.

See also setLastUpdateTime().

QString QCollectivePresenceInfo::message () const

Returns the message from this entity.

See also setMessage().

QString QCollectivePresenceInfo::presence () const

Returns the presence state string associated with the uri.

Different providers may have different standard strings associated with QCollectivePresenceInfo::PresenceType values.

See also setPresence().

PresenceType QCollectivePresenceInfo::presenceType () const

Returns the presence state type associated with the uri.

The presence state type is the standardized representation of the presence state, which may differ between different presence providers.

See also setPresence().

QVariantMap QCollectivePresenceInfo::properties () const

Returns the custom properties of this entity. These properties might be reported by some implementations of QCollectivePresence and can be used by client applications that have a deeper knowledge of the specific provider.

See also setProperties().

void QCollectivePresenceInfo::setAvatar ( const QString & avatar )

Sets the avatar (buddy icon) filename for this entity.

See also avatar() and message().

void QCollectivePresenceInfo::setCapabilities ( const QStringList & capabilities )

Sets the capabilities of the entity.

See also capabilities().

void QCollectivePresenceInfo::setDisplayName ( const QString & displayName )

Sets the display name of entity to displayName.

See also displayName().

void QCollectivePresenceInfo::setLastUpdateTime ( const QDateTime & lastUpdate )

Sets the last updated time for this entity to lastUpdate.

See also lastUpdateTime().

void QCollectivePresenceInfo::setMessage ( const QString & message )

Sets the message for this entity.

See also message().

void QCollectivePresenceInfo::setPresence ( const QString & presence, PresenceType type )

Sets the presence state and corresponding type associated with the uri.

Presence providers should perform the mapping from the presence provider specific presence state string to the standardized enumeration (QCollectivePresenceInfo::PresenceType).

See also presence().

void QCollectivePresenceInfo::setProperties ( const QVariantMap & properties )

Sets the custom properties of this entity.

See also properties().

void QCollectivePresenceInfo::setUri ( const QString & uri )

Sets the URI for this presence account to uri.

See also uri().

QString QCollectivePresenceInfo::uri () const

Returns the URI for this presence account object.

An account with no URI info is considered to be null.

See also setUri() and isNull().

bool QCollectivePresenceInfo::operator!= ( const QCollectivePresenceInfo & other ) const

Returns true if information in other is not equal to information contained in this object; otherwise returns false.

Note that this does not compare the properties.

QCollectivePresenceInfo & QCollectivePresenceInfo::operator= ( const QCollectivePresenceInfo & other )

Assigns other to this account and returns a reference to this presence account.

bool QCollectivePresenceInfo::operator== ( const QCollectivePresenceInfo & other ) const

Returns true if information in other is equal to information contained in this object; otherwise returns false.

Note that this does not compare the properties.


Copyright © 2009 Trolltech Trademarks
Qt Extended 4.4.3