Inherits from TICDSOperation : NSOperation
Declared in TICDSVacuumOperation.h

Overview

The TICDSVacuumOperation class describes a generic operation used by the TICoreDataSync framework to clean up unneeded files used to synchronize documents.

The operation carries out the following tasks:

  1. Find out the date of the oldest WholeStore.
  2. Find out the date of the least recent client sync.
  3. Remove all SyncChangeSet files older than whichever date is earlier.

Currently unimplemented, it also needs to carry out the following:
1. Create sync commands to remove the ids of these sync change sets from each client’s AppliedSyncChangeSets.ticdsync file.
2. Remove all SyncCommandSet files older than the least recent sync.
3. Create sync commands to remove the ids of these sync command sets from each client’s AppliedSyncCommandSets.ticdsync file.

Operations are typically created automatically by the relevant document sync manager.

%warning%
Warning: You must use one of the subclasses of TICDSVacuumOperation.

Tasks

Methods Overridden by Subclasses

Callbacks

Properties

Properties

earliestDateForFilesToKeep

The earliest modification date after which files must be kept.

@property (nonatomic, strong) NSDate *earliestDateForFilesToKeep

Declared In

TICDSVacuumOperation.h

Instance Methods

findOutDateOfOldestWholeStore

Determine the modification date of the oldest WholeStore file uploaded by any client.

- (void)findOutDateOfOldestWholeStore

Discussion

This method must call foundOutDateOfOldestWholeStoreFile: when finished.

Declared In

TICDSVacuumOperation.h

findOutLeastRecentClientSyncDate

Determine the date on which the least-recently-synchronized client last performed a sync.

- (void)findOutLeastRecentClientSyncDate

Discussion

This method must call foundOutLeastRecentClientSyncDate: when finished.

Declared In

TICDSVacuumOperation.h

foundOutDateOfOldestWholeStoreFile:

Indicate the date of the oldest WholeStore file.

- (void)foundOutDateOfOldestWholeStoreFile:(NSDate *)aDate

Parameters

aDate

The modification date of the oldest WholeStore file.

Discussion

If an error occurs, call setError: first, then specify nil for aDate. If no client has uploaded a WholeStore, specify [NSDate date].

Declared In

TICDSVacuumOperation.h

foundOutLeastRecentClientSyncDate:

Indicate the date of the least recent sync.

- (void)foundOutLeastRecentClientSyncDate:(NSDate *)aDate

Parameters

aDate

The date of the least recent sync.

Discussion

If an error occurs, call setError: first, then specify nil for aDate.

Declared In

TICDSVacuumOperation.h

removeOldSyncChangeSetFiles

Remove all SyncChangeSet files uploaded by this client which are older than earliestDateForFilesToKeep.

- (void)removeOldSyncChangeSetFiles

Discussion

This method must call removedOldSyncChangeSetFilesWithSuccess: when finished.

Declared In

TICDSVacuumOperation.h

removedOldSyncChangeSetFilesWithSuccess:

Indicate whether the removal of old SyncChangeSet files was successful.

- (void)removedOldSyncChangeSetFilesWithSuccess:(BOOL)success

Parameters

success

YES if the old sync change set files for this operation were removed, otherwise NO.

Discussion

If not, call setError: first, then specify NO for success.

Declared In

TICDSVacuumOperation.h