![]() |
Home | ![]() |
The QMailMessageServer class provides signals and slots which implement a convenient interface for communicating with the MessageServer process via IPC. More...
#include <QMailMessageServer>
This class is under development and is subject to change.
Inherits QObject.
QMailMessageServer ( QObject * parent = 0 ) | |
~QMailMessageServer () |
void | acknowledgeNewMessages ( const QMailMessageTypeList & types ) (deprecated) |
void | addMessages ( quint64 action, const QMailMessageMetaDataList & messages ) |
void | addMessages ( quint64 action, const QString & filename ) (deprecated) |
void | cancelSearch ( quint64 action ) |
void | cancelTransfer ( quint64 action ) |
void | countMessages ( quint64 action, const QMailMessageKey & filter, const QString & bodyText ) |
void | deleteMessages ( quint64 action, const QMailMessageIdList & mailList ) |
void | exportUpdates ( quint64 action, const QMailAccountId & accountId ) |
void | flagMessages ( quint64 action, const QMailMessageIdList & ids, quint64 setMask, quint64 unsetMask ) |
void | listActions () |
void | moveToFolder ( quint64 action, const QMailMessageIdList & ids, const QMailFolderId & folderId ) |
void | moveToStandardFolder ( quint64 action, const QMailMessageIdList & ids, quint64 standardFolder ) |
void | onlineCopyMessages ( quint64 action, const QMailMessageIdList & mailList, const QMailFolderId & destinationId ) |
void | onlineCreateFolder ( quint64 action, const QString & name, const QMailAccountId & accountId, const QMailFolderId & parentId ) |
void | onlineDeleteFolder ( quint64 action, const QMailFolderId & folderId ) |
void | onlineDeleteMessages ( quint64 action, const QMailMessageIdList & mailList, QMailStore::MessageRemovalOption option ) |
void | onlineFlagMessagesAndMoveToStandardFolder ( quint64 action, const QMailMessageIdList & mailList, quint64 setMask, quint64 unsetMask ) |
void | onlineMoveMessages ( quint64 action, const QMailMessageIdList & mailList, const QMailFolderId & destinationId ) |
void | onlineRenameFolder ( quint64 action, const QMailFolderId & folderId, const QString & name ) |
void | protocolRequest ( quint64 action, const QMailAccountId & accountId, const QString & request, const QVariant & data ) |
void | restoreToPreviousFolder ( quint64 action, const QMailMessageKey & key ) |
void | retrieveAll ( quint64 action, const QMailAccountId & accountId ) |
void | retrieveFolderList ( quint64 action, const QMailAccountId & accountId, const QMailFolderId & folderId, bool descending ) |
void | retrieveMessageList ( quint64 action, const QMailAccountId & accountId, const QMailFolderId & folderId, uint minimum, const QMailMessageSortKey & sort ) |
void | retrieveMessageLists ( quint64 action, const QMailAccountId & accountId, const QMailFolderIdList & folderIds, uint minimum, const QMailMessageSortKey & sort ) |
void | retrieveMessagePart ( quint64 action, const QMailMessagePart::Location & partLocation ) |
void | retrieveMessagePartRange ( quint64 action, const QMailMessagePart::Location & partLocation, uint minimum ) |
void | retrieveMessageRange ( quint64 action, const QMailMessageId & messageId, uint minimum ) |
void | retrieveMessages ( quint64 action, const QMailMessageIdList & messageIds, QMailRetrievalAction::RetrievalSpecification spec ) |
void | rollBackUpdates ( quint64 action, const QMailAccountId & mailAccountId ) |
void | searchMessages ( quint64 action, const QMailMessageKey & filter, const QString & bodyText, QMailSearchAction::SearchSpecification spec, const QMailMessageSortKey & sort ) |
void | searchMessages ( quint64 action, const QMailMessageKey & filter, const QString & bodyText, QMailSearchAction::SearchSpecification spec, quint64 limit, const QMailMessageSortKey & sort ) |
void | shutdown () |
void | synchronize ( quint64 action, const QMailAccountId & accountId ) |
void | transmitMessages ( quint64 action, const QMailAccountId & accountId ) |
void | updateMessages ( quint64 action, const QMailMessageMetaDataList & messages ) |
void | updateMessages ( quint64 action, const QString & filename ) (deprecated) |
void | actionStarted ( QMailActionData data ) |
void | actionsListed ( const QMailActionDataList & list ) |
void | activityChanged ( quint64 action, QMailServiceAction::Activity activity ) |
void | connectionDown () |
void | connectivityChanged ( quint64 action, QMailServiceAction::Connectivity connectivity ) |
void | folderCreated ( quint64 action, const QMailFolderId & folderId ) |
void | folderDeleted ( quint64 action, const QMailFolderId & folderId ) |
void | folderRenamed ( quint64 action, const QMailFolderId & folderId ) |
void | matchingMessageIds ( quint64 action, const QMailMessageIdList & ids ) |
void | messagesAdded ( quint64 action, const QMailMessageIdList & ids ) |
void | messagesCopied ( quint64 action, const QMailMessageIdList & list ) |
void | messagesCount ( quint64 action, uint count ) |
void | messagesDeleted ( quint64 action, const QMailMessageIdList & list ) |
void | messagesFailedTransmission ( quint64 action, const QMailMessageIdList & list, QMailServiceAction::Status::ErrorCode error ) |
void | messagesFlagged ( quint64 action, const QMailMessageIdList & list ) |
void | messagesMoved ( quint64 action, const QMailMessageIdList & list ) |
void | messagesTransmitted ( quint64 action, const QMailMessageIdList & list ) |
void | messagesUpdated ( quint64 action, const QMailMessageIdList & ids ) |
void | newCountChanged ( const QMailMessageCountMap & counts ) (deprecated) |
void | progressChanged ( quint64 action, uint progress, uint total ) |
void | protocolRequestCompleted ( quint64 action ) |
void | protocolResponse ( quint64 action, const QString & response, const QVariant & data ) |
void | reconnectionTimeout () |
void | remainingMessagesCount ( quint64 action, uint count ) |
void | retrievalCompleted ( quint64 action ) |
void | searchCompleted ( quint64 action ) |
void | statusChanged ( quint64 action, const QMailServiceAction::Status status ) |
void | storageActionCompleted ( quint64 action ) |
void | transmissionCompleted ( quint64 action ) |
The QMailMessageServer class provides signals and slots which implement a convenient interface for communicating with the MessageServer process via IPC.
QMF client messaging applications can send and receive messages of various types by communicating with the MessageServer. The MessageServer is a separate process, communicating with clients via inter-process messages. QMailMessageServer acts as a proxy object for the server process, providing an interface for communicating with the MessageServer by the use of signals and slots in the client process. It provides Qt signals corresponding to messages received from the MessageServer application, and Qt slots which send messages to the MessageServer when invoked.
For most messaging client applications, the QMailServiceAction objects offer a simpler interface for requesting actions from the messageserver, and assessing their results.
To send messages, the client should construct instances of the QMailMessage class formulated to contain the desired content. These messages should be stored to the mail store, within the Outbox folder configured for the parent account.
An instance of QMailTransmitAction should be used to request transmission of the outgoing messages.
There are a variety of mechanisms for retrieving messages, at various levels of granularity. In all cases, retrieved messages are added directly to the mail store by the message server, from where clients can retrieve their meta data or content.
An instance of QMailRetrievalAction should be used to request retrieval of folders and messages.
See also QMailServiceAction and QMailStore.
Constructs a QMailMessageServer object with parent parent, and initiates communication with the MessageServer application.
Destroys the QMailMessageServer object.
This function is deprecated.
Requests that the MessageServer reset the counts of 'new' messages to zero, for each message type listed in types.
See also newCountChanged().
Emitted when the action described by data has been started on the messageserver.
Emitted when a list of running actions has been retrieved from the server. The list of running actions is described by list.
Emitted whenever the MessageServer experiences a change in the activity status of the request identified by action. The request's new status is described by activity.
Requests that the MessageServer update the list of messages in the message store, and ensure the durability of the content of messages.
The request has the identifier action.
This function is deprecated.
Requests that the MessageServer add the messages in filename to the message store.
The request has the identifier action.
Requests that the MessageServer cancel any pending search operations for the request identified by action.
This method is obsolete, use cancel transfer instead.
Requests that the MessageServer cancel any pending transfer operations for the request identified by action.
See also transmitMessages() and retrieveMessages().
Signal that is emitted when the connection to the messageserver has been destroyed.
See also reconnectionTimeout().
Emitted whenever the MessageServer has a change in connectivity while servicing the request identified by action. The new server connectivity status is described by connectivity.
Requests that the MessageServer counts the number of messages that match the criteria specified by filter by on the device and remote servers. If bodyText is non-empty, messages containing the specified text in their content will also be matched.
The count of all matching messages is returned via a messagesCount() signal.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also messagesCount().
Requests that the MessageServer delete the messages in mailList, messages will be removed locally from the device, and if necessary information needed to delete messages from an external server is recorded.
Deleting messages using this slot does not initiate communication with any external server; Deletion from the external server will occur when QMailRetrievalAction::exportUpdates is called successfully.
The request has the identifier action.
See also QMailStore::removeMessage().
Requests that the message server update the external server with changes that have been effected on the local device for account accountId. Local changes to QMailMessage::Read, and QMailMessage::Important message status flags should be exported to the external server, and messages that have been removed using the QMailStore::CreateRemovalRecord option should be removed from the external server. The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Asynchronous version of QMailDisconnected::flagMessages()
Disconnected flags the list of messages identified by ids, setting the flags specified by the bit mask setMask to on and setting the flags set by the bit mask unsetMask to off.
For example this function may be used to mark messages as important.
The flagging operation will be propagated to the server by a successful call to QMailRetrievalAction::exportUpdates().
The request has the identifier action.
See also QMailDisconnected::flagMessages().
Emitted when the folder identified by folderId has been created, in response to the request identified by action.
See also onlineCreateFolder().
Emitted when the folder identified by folderId has been deleted, in response to the request identified by action.
See also onlineDeleteFolder().
Emitted when the folder identified by folderId has been renamed, in response to the request identified by action.
See also onlineRenameFolder().
Requests that the MessageServer emits a list of currently executing actions
Emitted by the search operation identified by action; ids contains the list of message identifiers located by the search.
See also searchMessages().
Signal that is emitted when messages have been asynchronously added to the message store.
action is the identifier of the request that caused the messages to be added, and ids is a list of identifiers of messages that have been added.
See also QMailStorageAction::addMessages().
Emitted when the messages identified by list have been copied to the destination folder on the external service, in response to the request identified by action.
See also onlineCopyMessages().
Emitted by search operation identified by action; Returns the count of matching messages on the remote server.
Only applicable for remote searches.
See also countMessages().
Emitted when the messages identified by list have been deleted from the mail store, in response to the request identified by action.
See also deleteMessages() and onlineDeleteMessages().
Emitted when a failed attempt has been made to transmit messages identified by list to the external server, in response to the request identified by action.
The error is described by error.
See also transmitMessages().
Emitted when the messages identified by list have been flagged with the specified set of status flags, in response to the request identified by action.
See also flagMessages(), moveToStandardFolder(), and onlineFlagMessagesAndMoveToStandardFolder().
Emitted when the messages identified by list have been moved to the destination folder on the external service, in response to the request identified by action.
See also moveToFolder(), moveToStandardFolder(), and onlineMoveMessages().
Emitted when the messages identified by list have been transmitted to the external server, in response to the request identified by action.
See also transmitMessages().
Signal that is emitted when messages have been asynchronously updated in the message store.
action is the identifier of the request that caused the messages to be updated, and ids is a list of identifiers of messages that have been updated.
See also QMailStorageAction::updateMessages().
Asynchronous version of QMailDisconnected::moveToFolder()
Disconnected moves the list of messages identified by ids into the folder identified by folderId, setting standard folder flags as appropriate.
Moving to another account is not supported.
The move operation will be propagated to the server by a successful call to QMailRetrievalAction::exportUpdates().
The request has the identifier action.
See also QMailDisconnected::moveToFolder().
Asynchronous version of QMailDisconnected::moveToStandardFolder()
Disconnected moves the list of messages identified by ids into the standard folder standardFolder, setting standard folder flags as appropriate.
The move operation will be propagated to the server by a successful call to QMailRetrievalAction::exportUpdates().
The request has the identifier action.
See also QMailDisconnected::moveToStandardFolder().
This function is deprecated.
Emitted when the count of 'new' messages changes; the new count is described by counts.
See also acknowledgeNewMessages().
Requests that the MessageServer create a copy of each message listed in mailList in the folder identified by destinationId.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
Requests that the MessageServer create a new folder named name, created in the account identified by accountId.
If parentId is a valid folder identifier the new folder will be a child of the parent; otherwise the folder will be have no parent and will be created at the highest level.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also onlineDeleteFolder().
Requests that the MessageServer delete the folder identified by folderId. Any existing folders or messages contained by the folder will also be deleted.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also onlineCreateFolder() and onlineRenameFolder().
Requests that the MessageServer delete the messages in mailList from the external server, if necessary for the relevant message type.
If option is CreateRemovalRecord then a QMailMessageRemovalRecord will be created in the mail store for each deleted message. In this case the function requires the device to be online, it may initiate communication with external servers.
The request has the identifier action.
See also QMailStore::removeMessage().
Requests that the MessageServer flag each message listed in mailList by setting the status flags set in setMask, and unsetting the status flags set in unsetMask. The request has the identifier action.
The protocol must ensure that the local message records are appropriately modified, although the external changes may be buffered and effected at the next invocation of exportUpdates().
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
Requests that the MessageServer move each message listed in mailList from its current location to the folder identified by destinationId.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
Requests that the MessageServer rename the folder identified by folderId to name. The request has the identifier action.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also onlineCreateFolder().
Emitted when the progress of the request identified by action changes; total indicates the extent of the operation to be performed, progress indicates the current degree of completion.
Requests that the MessageServer forward the protocol-specific request request to the QMailMessageSource configured for the account identified by accountId. The request, identified by action, may have associated data, in a protocol-specific form.
Emitted when the protocol request identified by action is completed.
See also protocolRequest().
Emitted when the protocol request identified by action generates the response response, with the associated data.
See also protocolRequest().
Signal that is emitted when the connection to the messageserver has been lost.
See also connectionDown().
Emitted by search operation identified by action; Returns the count of matching messages remaining on the remote server, that is the count of messages that will not be retrieved from the remote server to the device.
Only applicable for remote searches.
See also searchMessages().
Asynchronous version of QMailDisconnected::restoreToPreviousFolder()
Updates all QMailMessages identified by the key key to move the messages back to the previous folder they were contained by.
The request has the identifier action.
See also QMailDisconnected::restoreToPreviousFolder(), QMailMessageServer::moveToFolder(), and QMailMessageServer::moveToStandardFolder().
Emitted when the retrieval operation identified by action is completed.
Requests that the message server retrieve the meta data for all messages available for the account accountId. The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Requests that the message server retrieve the list of folders available for the account accountId. If folderId is valid, the folders within that folder should be retrieved. If descending is true, the search should also recursively retrieve the folders available within the previously retrieved folders. The request has the identifier action.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Requests that the message server retrieve the list of messages available for the account accountId. If folderId is valid, then only messages within that folder should be retrieved; otherwise messages within all folders in the account should be retrieved. If a folder messages are being retrieved from contains at least minimum messages then the messageserver should ensure that at least minimum messages are available from the mail store for that folder; otherwise if the folder contains less than minimum messages the messageserver should ensure all the messages for that folder are available from the mail store.
If sort is not empty, the external service will discover the listed messages in the ordering indicated by the sort criterion, if possible.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Requests that the messageserver retrieve the list of messages available for the account accountId. If folderIds is not empty, then only messages within those folders should be retrieved; otherwise no messages should be retrieved. If a folder messages are being retrieved from contains at least minimum messages then the messageserver should ensure that at least minimum messages are available from the mail store for that folder; otherwise if the folder contains less than minimum messages the messageserver should ensure all the messages for that folder are available from the mail store.
If sort is not empty, the external service will discover the listed messages in the ordering indicated by the sort criterion, if possible.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Requests that the message server retrieve the message part that is indicated by the location partLocation.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Requests that the message server retrieve a subset of the message part that is indicated by the location partLocation. The messageserver should ensure that at least minimum bytes are available from the mail store. The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Requests that the message server retrieve a subset of the message messageId, such that at least minimum bytes are available from the mail store. The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Requests that the message server retrieve data regarding the messages identified by messageIds.
If spec is QMailRetrievalAction::Flags, then the message server should detect if the read or important status of messages identified by messageIds has changed on the server or if the messages have been removed on the server. The QMailMessage::ReadElsewhere, QMailMessage::ImportantElsewhere and QMailMessage::Removed status flags of messages will be updated to reflect the status of the message on the server.
If spec is QMailRetrievalAction::MetaData, then the message server should retrieve the meta data of the each message listed in messageIds.
If spec is QMailRetrievalAction::Content, then the message server should retrieve the entirety of each message listed in messageIds.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Asynchronous version of QMailDisconnected::rollBackUpdates()
Rolls back all disconnected move and copy operations that have been applied to the message store since the most recent synchronization of the message with the account specified by mailAccountId.
The request has the identifier action.
See also QMailDisconnected::updatesOutstanding().
Emitted when the search operation identified by action is completed.
See also searchMessages().
Requests that the MessageServer search for messages that meet the criteria encoded in filter. If bodyText is non-empty, messages containing the specified text in their content will also be matched. If spec is Remote then the MessageServer will extend the search to consider messages held at external servers that are not present on the local device. If sort is not empty, the external service will return matching messages in the ordering indicated by the sort criterion if possible.
The identifiers of all matching messages are returned via matchingMessageIds() signals.
The request has the identifier action.
If a remote search is specified then this function requires the device to be online, it may initiate communication with external servers.
See also matchingMessageIds(), messagesCount(), and remainingMessagesCount().
Requests that the MessageServer search for messages that meet the criteria encoded in filter. If bodyText is non-empty, messages containing the specified text in their content will also be matched. If spec is Remote then the MessageServer will extend the search to consider messages held at external servers that are not present on the local device.
A maximum of limit messages will be retrieved from the remote server.
If sort is not empty, the external service will return matching messages in the ordering indicated by the sort criterion if possible.
The identifiers of all matching messages are returned via matchingMessageIds() signals.
The request has the identifier action.
If a remote search is specified then this function requires the device to be online, it may initiate communication with external servers.
See also matchingMessageIds(), messagesCount(), and remainingMessagesCount().
Requests that the MessageServer shutdown and terminate
Emitted whenever the MessageServer experiences a status change that may be of interest to the client, while servicing the request identified by action. The new server status is described by status.
Emitted when the storage operation identified by action is completed.
Requests that the message server synchronize the messages and folders in the account identified by accountId.
Newly discovered messages should have their meta data retrieved, local changes to QMailMessage::Read, and QMailMessage::Important message status flags should be exported to the external server, and messages that have been removed locally using the QMailStore::CreateRemovalRecord option should be removed from the external server.
The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also retrievalCompleted().
Emitted when the transmit operation identified by action is completed.
See also transmitMessages().
Requests that the MessageServer application transmit any messages belonging to the account identified by accountId that are currently in the Outbox folder. The request has the identifier action.
This function requires the device to be online, it may initiate communication with external servers.
See also transmissionCompleted().
Requests that the MessageServer add the list of messages to the message store, and ensure the durability of the content of messages.
The request has the identifier action.
This function is deprecated.
Requests that the MessageServer update the messages in filename to the message store.
The request has the identifier action.
Copyright © 2010 QtSoftware | Messaging Framework |