SFAdvancedSyncUpTarget Protocol Reference
Declared in | SFAdvancedSyncUpTarget.h |
---|
Overview
Protocol for advanced sync up target where records are not simply created, updated, or deleted.
With advanced sync up target, sync manager simply calls the syncUpRecords
method.
maxBatchSize
required method
Maximum number of records that can be passed to syncUpRecords
at once.
@property (nonatomic, readonly) NSUInteger maxBatchSize
Declared In
SFAdvancedSyncUpTarget.h
– syncUpRecords:records:fieldlist:mergeMode:syncSoupName:completionBlock:failBlock:
required method
Sync up locally created, updated, or deleted records to the server.
- (void)syncUpRecords:(SFMobileSyncSyncManager *)syncManager records:(NSArray<NSMutableDictionary*> *)records fieldlist:(NSArray *)fieldlist mergeMode:(SFSyncStateMergeMode)mergeMode syncSoupName:(NSString *)syncSoupName completionBlock:(SFSyncUpTargetCompleteBlock)completionBlock failBlock:(SFSyncUpTargetErrorBlock)failBlock
Parameters
syncManager |
Sync manager doing the sync |
---|---|
records |
Records being synced |
fieldlist |
List of fields to send to server |
mergeMode |
Merge mode–either “OVERWRITE” or “LEAVE_IF_CHANGED”. |
syncSoupName |
Soup being synced. |
completionBlock |
Block to execute after the server call completes. |
failBlock |
Block to execute if the server call fails. |
Declared In
SFAdvancedSyncUpTarget.h