Home · All Classes · Grouped Classes · Annotated · Functions

QPresence Class Reference

The QPresence class provides presence information for Voice-Over-IP style phone services. More...

    #include <QPresence>

This class is under development and is subject to change.

Inherits QCommInterface.

Public Types

Properties

Public Functions

Public Slots

Signals

Protected Functions

Additional Inherited Members


Detailed Description

The QPresence class provides presence information for Voice-Over-IP style phone services.

Clients can monitor the presence status of other users with startMonitoring(). The monitoredPresence() signal will be emitted whenever the status of the other users change. The client should call stopMonitoring() when it no longer wishes to monitor changes in a remote user's availability.

Clients can also alter the local user's presence status with setLocalPresence(). The presence change will be advertised to any remote user that is currently monitoring the local user.

See also QCommInterface.


Member Type Documentation

enum QPresence::Status

This enum defines whether a Voice-Over-IP user is present or not.

ConstantValueDescription
QPresence::Unavailable0The user is not available.
QPresence::Available1The user is available.


Property Documentation

allMonitoredUris : const QStringList

This property holds the list of all uri's that are being monitored in the system, even by other applications.

Access functions:

localPresence : QPresence::Status

This property holds the presence status for the local user.

Access functions:

monitoredUris : const QStringList

This property holds the list of uri's that are being monitored by this client object.

Access functions:


Member Function Documentation

QPresence::QPresence ( const QString & service = QString(), QObject * parent = 0, QCommInterface::Mode mode = Client )

Construct a new presence monitoring object for service and attach it to parent. The object will be created in client mode if mode is Client, or server mode otherwise.

QPresence::~QPresence ()

Destroy this presence monitoring object. Any remaining monitor requests will be stopped.

void QPresence::localPresenceChanged ()   [signal]

Signal that is emitted when the localPresence() value changes.

See also localPresence() and setLocalPresence().

void QPresence::monitoredPresence ( const QString & uri, QPresence::Status status )   [signal]

Signal that is emitted when the monitored presence status on uri changes. This signal may be emitted for uri's that are being monitored by other applications. The uri should be checked by the caller against the expected values from monitoredUris().

See also startMonitoring() and stopMonitoring().

QPresence::Status QPresence::monitoredUriStatus ( const QString & uri ) const

Returns the current monitoring status associated with uri.

See also monitoredUris() and allMonitoredUris().

bool QPresence::startMonitoring ( const QString & uri )   [virtual slot]

Start monitoring uri for presence changes. The monitoredPresence() signal will be emitted whenever the status changes. Returns false if the uri was already being monitored by this object.

Server implementations that inherit from QPresence should call this base implementation before performing any other action.

See also monitoredPresence() and stopMonitoring().

bool QPresence::stopMonitoring ( const QString & uri )   [virtual slot]

Stop monitoring uri for presence changes. Returns false if uri was not currently being monitored by this object, or there are still remaining references to uri in the system. Monitoring will be implicitly stopped when this object is destroyed.

Server implementations that inherit from QPresence should call this base implementation before performing any other action.

See also monitoredPresence() and startMonitoring().

void QPresence::updateMonitoredPresence ( const QString & uri, QPresence::Status status )   [protected]

Called from server implementations to update the monitoring status of uri. This function will update the global state as seen by monitoredUriStatus() and then emits monitoredPresence().

See also monitoredPresence(), startMonitoring(), and stopMonitoring().


Copyright © 2008 Nokia Trademarks
Qtopia 4.3.3