@@ -16,12 +16,31 @@ BUILT_ASSUME_NONNULL_BEGIN
1616// MARK: - Clear Hook
1717/* *
1818Removes all the records from offline DB.
19+ //'blt5d4sample2633b' is a dummy Application API key
20+
21+ //Obj-C
22+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
23+ [builtApplication clearOfflineData];
24+
25+ //Swift
26+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
27+ builtApplication.clearOfflineData()
28+
1929@warning Not supported in watchOS
2030 */
2131- (void )clearOfflineData ;
2232
2333/* *
2434 Removes all the records from offline DB for the specified classes.
35+ //'blt5d4sample2633b' is a dummy Application API key
36+
37+ //Obj-C
38+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
39+ [builtApplication clearOfflineDataOfOnly:@[@"task"]];
40+
41+ //Swift
42+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
43+ builtApplication.clearOfflineData(ofOnly: ["task"])
2544
2645 @param onlyClasses Array of class name which need to be removed.
2746 @warning Not supported in watchOS
@@ -30,7 +49,16 @@ Removes all the records from offline DB.
3049
3150/* *
3251 Removes all the records from offline DB except the specified classes.
52+ //'blt5d4sample2633b' is a dummy Application API key
53+
54+ //Obj-C
55+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
56+ [builtApplication clearOfflineDataExcept:@[@"task"]];
3357
58+ //Swift
59+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
60+ builtApplication.clearOfflineData(ofExcept: ["task"])
61+
3462 @param exceptClasses Array of class name which need not to be removed.
3563 @warning Not supported in watchOS
3664 */
@@ -40,13 +68,33 @@ Removes all the records from offline DB.
4068
4169/* *
4270 Sync all classes with the server. If offline is enabled in BuiltConfig it will save all records.
71+ //'blt5d4sample2633b' is a dummy Application API key
72+
73+ //Obj-C
74+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
75+ [builtApplication sync];
76+
77+ //Swift
78+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
79+ builtApplication.sync()
4380
4481 @warning Not supported in watchOS
4582 */
4683- (void )sync ;
4784
4885/* *
4986 Sync all classes with the server from the specified date. If offline is enabled in BuiltConfig it will save all records.
87+ //'blt5d4sample2633b' is a dummy Application API key
88+
89+ //Obj-C
90+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
91+ NSDate *date = [NSDate dateWithTimeIntervalSince1970:10000];
92+ [builtApplication sync:date];
93+
94+ //Swift
95+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
96+ let date:Date = Date.init(timeIntervalSince1970: 10000)
97+ builtApplication.sync(date)
5098
5199 @param date Date from which sync need to be performed.
52100 @warning Not supported in watchOS
@@ -55,6 +103,17 @@ Removes all the records from offline DB.
55103
56104/* *
57105 Sync only classes specified with the server. If offline is enabled in BuiltConfig it will save all records.
106+ //'blt5d4sample2633b' is a dummy Application API key
107+
108+ //Obj-C
109+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
110+ NSDate *date = [NSDate dateWithTimeIntervalSince1970:10000];
111+ [builtApplication syncOnly:@[@"task"]];
112+
113+ //Swift
114+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
115+ let date:Date = Date.init(timeIntervalSince1970: 10000)
116+ builtApplication.syncOnly(["task"])
58117
59118 @param onlyClasses Array of class name which should to be synced.
60119 @warning Not supported in watchOS
@@ -63,6 +122,17 @@ Removes all the records from offline DB.
63122
64123/* *
65124 Sync only classes specified with the server from the specified date. If offline is enabled in BuiltConfig it will save all records.
125+ //'blt5d4sample2633b' is a dummy Application API key
126+
127+ //Obj-C
128+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
129+ NSDate *date = [NSDate dateWithTimeIntervalSince1970:10000];
130+ [application syncOnly:@[@"task"] date:date];
131+
132+ //Swift
133+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
134+ let date:Date = Date.init(timeIntervalSince1970: 10000)
135+ builtApplication.syncOnly(["task"], date: date)
66136
67137 @param onlyClasses Array of class name which should to be synced.
68138 @param date Date from which sync need to be performed.
@@ -72,6 +142,17 @@ Removes all the records from offline DB.
72142
73143/* *
74144 Sync all classes except the specified list with the server. If offline is enabled in BuiltConfig it will save all records.
145+ //'blt5d4sample2633b' is a dummy Application API key
146+
147+ //Obj-C
148+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
149+ NSDate *date = [NSDate dateWithTimeIntervalSince1970:10000];
150+ [builtApplication syncExcept:@[@"project"]];
151+
152+ //Swift
153+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
154+ let date:Date = Date.init(timeIntervalSince1970: 10000)
155+ builtApplication.syncExcept(["project"])
75156
76157 @param exceptClasses Array of class name which should not be synced.
77158 @warning Not supported in watchOS
@@ -80,13 +161,82 @@ Removes all the records from offline DB.
80161
81162/* *
82163 Sync all classes except the specified list with the server from the specified date. If offline is enabled in BuiltConfig it will save all records.
164+ //'blt5d4sample2633b' is a dummy Application API key
165+
166+ //Obj-C
167+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
168+ NSDate *date = [NSDate dateWithTimeIntervalSince1970:10000];
169+ [application syncExcept:@[@"project"] date:date];
83170
171+ //Swift
172+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
173+ let date:Date = Date.init(timeIntervalSince1970: 10000)
174+ builtApplication.syncExcept(["project"], date: date)
175+
84176 @param exceptClasses Array of class name which should not be synced.
85177 @param date Date from which sync need to be performed.
86178 @warning Not supported in watchOS
87179 */
88180- (void )syncExcept : (NSArray *)exceptClasses date : (NSDate *)date ;
89181
182+ /* *
183+ Note: If objects are more than 1000 in a class, then this method will be recommended instead of sync.
184+
185+ Sync all classes with the server with pagination. If offline is enabled in BuiltConfig it will save all records.
186+ //'blt5d4sample2633b' is a dummy Application API key
187+
188+ //Obj-C
189+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
190+ [builtApplication syncWithPagination];
191+
192+ //Swift
193+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
194+ builtApplication.syncWithPagination()
195+
196+ @warning Not supported in watchOS
197+ */
198+ - (void )syncWithPagination ;
199+
200+ /* *
201+ Note: If objects are more than 1000 in a class, then this method will be recommended instead of syncOnly.
202+
203+ Sync only classes specified with the server with pagination. If offline is enabled in BuiltConfig it will save all records.
204+ //'blt5d4sample2633b' is a dummy Application API key
205+
206+ //Obj-C
207+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
208+ [builtApplication syncOnlyWithPagination:@[@"task"]];
209+
210+ //Swift
211+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
212+ builtApplication.syncOnly(withPagination: ["task"])
213+
214+
215+ @param onlyClasses Array of class name which should to be synced.
216+ @warning Not supported in watchOS
217+ */
218+ - (void )syncOnlyWithPagination : (NSArray *)onlyClasses ;
219+
220+ /* *
221+ Note: If objects are more than 1000 in a class, then this method will be recommended instead of syncExcept.
222+
223+ Sync all classes except the specified list with the server with pagination. If offline is enabled in BuiltConfig it will save all records.
224+ //'blt5d4sample2633b' is a dummy Application API key
225+
226+ //Obj-C
227+ BuiltApplication *builtApplication = [Built applicationWithAPIKey:@"blt5d4sample2633b"];
228+ [builtApplication syncExceptWithPagination:@[@"project"]];
229+
230+ //Swift
231+ var builtApplication:BuiltApplication = Built.applicationWithAPIKey("blt5d4sample2633b")
232+ builtApplication.syncExcept(withPagination: ["project"])
233+
234+
235+ @param exceptClasses Array of class name which should not be synced.
236+ @warning Not supported in watchOS
237+ */
238+ - (void )syncExceptWithPagination : (NSArray *)exceptClasses ;
239+
90240@end
91241
92242BUILT_ASSUME_NONNULL_END
0 commit comments