Public Member Functions | Public Attributes

nsIAutoSyncState Interface Reference

import "nsIAutoSyncState.idl";

Collaboration diagram for nsIAutoSyncState:

List of all members.

Public Member Functions

void rollback ()
 Puts the download queue offset to its previous position.
void resetDownloadQ ()
 Clears the download queue.
void tryCurrentGroupAgain (in unsigned long aRetryCount)
 Rollbacks the offset to the previous position and changes the state to ready-to-download.
void resetRetryCounter ()
 Resets the retry counter.
boolean isSibling (in nsIAutoSyncState aAnotherStateObj)
 Tests whether the given folder has the same imap server.
void downloadMessagesForOffline (in nsIArray aMessageList)
 Downloads the bodies of the given messages from the server.
nsIMutableArray getNextGroupOfMessages (in unsigned long aSuggestedGroupSizeLimit, out unsigned long aActualGroupSize)
 Populates the given array with the keys of the messages that will be downloaded next.
unsigned long processExistingHeaders (in unsigned long aNumberOfHeadersToProcess)
 Iterates through the existing headers of the folder to find the messages not downloaded yet.

Public Attributes

const long stCompletedIdle = 0
 Auto-Sync states.
const long stStatusIssued = 1
 STATUS issued.
const long stUpdateIssued = 2
 Update issued.
const long stDownloadInProgress = 3
 Message body download in progress.
const long stReadyToDownload = 4
 ready to download the next group of messages
readonly attribute PRTime lastSyncTime
 Last time the existing headers are completely processed.
attribute PRTime lastUpdateTime
 Last time the owner folder is updated.
attribute long state
 Download operation state.
readonly attribute long pendingMessageCount
 Number of messages waiting to be downloaded.
readonly attribute long totalMessageCount
 Total number of messages in the download queue.
readonly attribute nsIMsgFolder ownerFolder
 The folder this auto-sync object is related to.

Member Function Documentation

void nsIAutoSyncState::downloadMessagesForOffline ( in nsIArray  aMessageList  ) 

Downloads the bodies of the given messages from the server.

nsIMutableArray nsIAutoSyncState::getNextGroupOfMessages ( in unsigned long  aSuggestedGroupSizeLimit,
out unsigned long  aActualGroupSize 
)

Populates the given array with the keys of the messages that will be downloaded next.

Parameters:
aSuggestedGroupSizeLimit suggested size per group in bytes
aActualGroupSize total size of the messages in bytes in the group
boolean nsIAutoSyncState::isSibling ( in nsIAutoSyncState  aAnotherStateObj  ) 

Tests whether the given folder has the same imap server.

unsigned long nsIAutoSyncState::processExistingHeaders ( in unsigned long  aNumberOfHeadersToProcess  ) 

Iterates through the existing headers of the folder to find the messages not downloaded yet.

Parameters:
aNumberOfHeadersToProcess number of headers to be processed at this pass
Returns:
the number of headers left to process
void nsIAutoSyncState::resetDownloadQ (  ) 

Clears the download queue.

Resets the offsets.

void nsIAutoSyncState::resetRetryCounter (  ) 

Resets the retry counter.

void nsIAutoSyncState::rollback (  ) 

Puts the download queue offset to its previous position.

void nsIAutoSyncState::tryCurrentGroupAgain ( in unsigned long  aRetryCount  ) 

Rollbacks the offset to the previous position and changes the state to ready-to-download.


Member Data Documentation

Last time the existing headers are completely processed.

Last time the owner folder is updated.

The folder this auto-sync object is related to.

readonly attribute long nsIAutoSyncState::pendingMessageCount

Number of messages waiting to be downloaded.

attribute long nsIAutoSyncState::state

Download operation state.

Auto-Sync states.

sync'd and no pending messages

Message body download in progress.

ready to download the next group of messages

STATUS issued.

Will check to see if any counts changed since last STATUS

Update issued.

Will figure out if there are any bodies to download

readonly attribute long nsIAutoSyncState::totalMessageCount

Total number of messages in the download queue.


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