Home · All Classes · All Namespaces · Modules · Functions · Files
Public Slots | Signals | Public Member Functions | Static Public Member Functions | Protected Member Functions
Tp::Client::ConnectionInterfaceMailNotificationInterface Class Reference

#include <TelepathyQt4/Connection>

Inherits Tp::AbstractInterface.

List of all members.

Public Slots

Signals

Public Member Functions

Static Public Member Functions

Protected Member Functions


Detailed Description

Proxy class providing a 1:1 mapping of the D-Bus interface "org.freedesktop.Telepathy.Connection.Interface.MailNotification."


Constructor & Destructor Documentation

Tp::Client::ConnectionInterfaceMailNotificationInterface::ConnectionInterfaceMailNotificationInterface ( const QString busName,
const QString objectPath,
QObject parent = 0 
)

Creates a ConnectionInterfaceMailNotificationInterface associated with the given object on the session bus.

Parameters:
busNameName of the service the object is on.
objectPathPath to the object on the service.
parentPassed to the parent class constructor.
Tp::Client::ConnectionInterfaceMailNotificationInterface::ConnectionInterfaceMailNotificationInterface ( const QDBusConnection connection,
const QString busName,
const QString objectPath,
QObject parent = 0 
)

Creates a ConnectionInterfaceMailNotificationInterface associated with the given object on the given bus.

Parameters:
connectionThe bus via which the object can be reached.
busNameName of the service the object is on.
objectPathPath to the object on the service.
parentPassed to the parent class constructor.
Tp::Client::ConnectionInterfaceMailNotificationInterface::ConnectionInterfaceMailNotificationInterface ( Tp::DBusProxy proxy)

Creates a ConnectionInterfaceMailNotificationInterface associated with the same object as the given proxy.

Parameters:
proxyThe proxy to use. It will also be the QObject::parent() for this object.
Tp::Client::ConnectionInterfaceMailNotificationInterface::ConnectionInterfaceMailNotificationInterface ( const Tp::Client::ConnectionInterface mainInterface) [explicit]

Creates a ConnectionInterfaceMailNotificationInterface associated with the same object as the given proxy. Additionally, the created proxy will have the same parent as the given proxy.

Parameters:
mainInterfaceThe proxy to use.
Tp::Client::ConnectionInterfaceMailNotificationInterface::ConnectionInterfaceMailNotificationInterface ( const Tp::Client::ConnectionInterface mainInterface,
QObject parent 
)

Creates a ConnectionInterfaceMailNotificationInterface associated with the same object as the given proxy. However, a different parent object can be specified.

Parameters:
mainInterfaceThe proxy to use.
parentPassed to the parent class constructor.

Member Function Documentation

static QLatin1String Tp::Client::ConnectionInterfaceMailNotificationInterface::staticInterfaceName ( ) [inline, static]

Returns the name of the interface "org.freedesktop.Telepathy.Connection.Interface.MailNotification", which this class represents.

Returns:
The D-Bus interface name.
Tp::PendingVariant* Tp::Client::ConnectionInterfaceMailNotificationInterface::requestPropertyMailNotificationFlags ( ) const [inline]

Asynchronous getter for the remote object property MailNotificationFlags of type uint.

Integer representing the bitwise-OR of supported features for e-mails notification on this server. This property MUST NOT change after the Connection becomes CONNECTED. This property indicates the behavior and availability of the other properties and signals within this interface. A connection manager that cannot at least set one of the flags in the Mail_Notification_Flags SHOULD NOT provide this interface.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariant* Tp::Client::ConnectionInterfaceMailNotificationInterface::requestPropertyUnreadMailCount ( ) const [inline]

Asynchronous getter for the remote object property UnreadMailCount of type uint.

The number of unread messages in the Inbox. Change notification is via UnreadMailsChanged() .

This property is only useful if Supports_Unread_Mail_Count is set in the MailNotificationFlags ; otherwise, it MUST be zero.

If Thread_Based appears in the MailNotificationFlags , this property counts the number of threads, not the number of mails.

Note that this count MAY be bigger than the number of items in UnreadMails . See UnreadMails for more details.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariant* Tp::Client::ConnectionInterfaceMailNotificationInterface::requestPropertyUnreadMails ( ) const [inline]

Asynchronous getter for the remote object property UnreadMails of type Tp::MailList.

An array of unread Mails. Change notification is via UnreadMailsChanged. This property is only useful if Supports_Unread_Mails is set in MailNotificationFlags; otherwise, it MUST be an empty list. The array size MAY be shorter than UnreadMailCount. Some servers may limits the amount of detailed e-mails sent. This can significantly reduce the network traffic for large inbox. For this reason, it is normal that UnreadMailCount be bigger or equal to the size of this array.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariant* Tp::Client::ConnectionInterfaceMailNotificationInterface::requestPropertyMailAddress ( ) const [inline]

Asynchronous getter for the remote object property MailAddress of type QString.

A string representing the e-mail address of the account. The CMs MUST provide this information. In close integration of MailNotification with other e-mail services, the e-mail address can be used has a unique identifier for the account. Possible integration could be between Telepathy and Evolution where the e-mail address is the common information in both interfaces.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariantMap* Tp::Client::ConnectionInterfaceMailNotificationInterface::requestAllProperties ( ) const [inline]

Request all of the DBus properties on the interface.

Returns:
A pending variant map which will emit finished when the properties have been retrieved.
QDBusPendingReply<Tp::MailURL> Tp::Client::ConnectionInterfaceMailNotificationInterface::RequestInboxURL ( int  timeout = -1) [inline, slot]

Begins a call to the D-Bus method RequestInboxURL on the remote object.

This method creates and returns a URL and an optional POST data that allow opening the Inbox folder of a webmail account. This URL MAY contain tokens with a short lifetime, so clients SHOULD request a new URL for each visit to the webmail interface. This method is implemented only if the Supports_Request_Inbox_URL flag is set in MailNotificationFlags. We are not using properties here because the tokens are unsuitable for sharing between clients, and network round-trips may be required to obtain the information that leads to authentication free webmail access.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
timeoutThe timeout in milliseconds.
Returns:

A struture containing a URL and optional additional data to open a webmail client, without re-authentication if possible.

QDBusPendingReply<Tp::MailURL> Tp::Client::ConnectionInterfaceMailNotificationInterface::RequestMailURL ( const QString ID,
const QDBusVariant URLData,
int  timeout = -1 
) [inline, slot]

Begins a call to the D-Bus method RequestMailURL on the remote object.

This method creates and returns a URL and optional POST data that allow opening a specific mail in a webmail interface. This method is implemented only if Supports_Request_Mail_URL flag is set in MailNotificationFlags. See RequestInboxURL for design rationale.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
IDThe mail's id as found in the Mail structure, or the empty string if no id key was provided.
URLDataWhatever url-data was found in the Mail structure, or the boolean value False (D-Bus type 'b') if no url-data was provided in the Mail.
timeoutThe timeout in milliseconds.
Returns:

A struture that contains a URL and optional additional data to open a webmail client, without re-authentication if possible.

void Tp::Client::ConnectionInterfaceMailNotificationInterface::MailsReceived ( const Tp::MailList mails) [signal]

Represents the signal MailsReceived on the remote object.

Emitted when new e-mails messages arrive to the inbox associated with this connection. This signal is used for protocols that are not able to maintain the UnreadMails list, but do provide real-time notification about newly arrived e-mails. It MUST NOT be emitted unless Emits_Mails_Received is set in MailNotificationFlags.

Parameters:
mails

An array of Mails. Those e-mail MUST NOT have the "id" key.

On connections that emit this signal, it's impossible to tell when a mail has been removed, and hence when "id" has become invalid.

void Tp::Client::ConnectionInterfaceMailNotificationInterface::UnreadMailsChanged ( uint  count,
const Tp::MailList mailsAdded,
const QStringList mailsRemoved 
) [signal]

Represents the signal UnreadMailsChanged on the remote object.

Emitted when UnreadMails or UnreadMailCount have changed. It MUST NOT be emited if Supports_Unread_Mail_Count flag is not set in MailNotificationFlags .

Mails_Added and Mails_Removed MUST be empty if the Supports_Unread_Mails flag is not set.

Parameters:
countNumber of unread messages in the inbox (the new value of UnreadMailCount).
mailsAdded

A list of Mail that are being added or updated in UnreadMails .

Mails may be updated when the URL information (URL and POST data) have changed, or senders were added or removed from an e-mail thread.

If the Supports_Unread_Mails flag is not set, this list MUST be empty, even if Count has increased.

mailsRemovedA list of e-mail IDs that are being removed from UnreadMails. If the Supports_Unread_Mails flag is not set, this list MUST be empty, even if Count has decreased.
void Tp::Client::ConnectionInterfaceMailNotificationInterface::invalidate ( Tp::DBusProxy proxy,
const QString error,
const QString message 
) [protected, virtual]

Reimplemented from Tp::AbstractInterface.


Copyright © 2008-2011 Collabora Ltd. and Nokia Corporation
Telepathy-Qt4 0.6.5