45 Class implementing a synchronization handler using FTP. |
45 Class implementing a synchronization handler using FTP. |
46 </p><h3>Signals</h3> |
46 </p><h3>Signals</h3> |
47 <dl> |
47 <dl> |
48 <dt>syncError(message)</dt> |
48 <dt>syncError(message)</dt> |
49 <dd> |
49 <dd> |
50 emitted for a general error with the error message (string) |
50 emitted for a general error with the error |
|
51 message (string) |
51 </dd><dt>syncFinished(type_, done, download)</dt> |
52 </dd><dt>syncFinished(type_, done, download)</dt> |
52 <dd> |
53 <dd> |
53 emitted after a synchronization has |
54 emitted after a |
54 finished (string one of "bookmarks", "history", "passwords", "useragents" or |
55 synchronization has finished (string one of "bookmarks", "history", |
55 "speeddial", boolean, boolean) |
56 "passwords", "useragents" or "speeddial", boolean, boolean) |
56 </dd><dt>syncMessage(message)</dt> |
57 </dd><dt>syncMessage(message)</dt> |
57 <dd> |
58 <dd> |
58 emitted to send a message about synchronization (string) |
59 emitted to send a message about |
|
60 synchronization (string) |
59 </dd><dt>syncStatus(type_, message)</dt> |
61 </dd><dt>syncStatus(type_, message)</dt> |
60 <dd> |
62 <dd> |
61 emitted to indicate the synchronization |
63 emitted to indicate the synchronization |
62 status (string one of "bookmarks", "history", "passwords", "useragents" or |
64 status (string one of "bookmarks", "history", "passwords", |
63 "speeddial", string) |
65 "useragents" or "speeddial", string) |
64 </dd> |
66 </dd> |
65 </dl> |
67 </dl> |
66 <h3>Derived from</h3> |
68 <h3>Derived from</h3> |
67 SyncHandler |
69 SyncHandler |
68 <h3>Class Attributes</h3> |
70 <h3>Class Attributes</h3> |
189 Private method to downlaod the given file. |
191 Private method to downlaod the given file. |
190 </p><dl> |
192 </p><dl> |
191 <dt><i>type_</i></dt> |
193 <dt><i>type_</i></dt> |
192 <dd> |
194 <dd> |
193 type of the synchronization event (string one |
195 type of the synchronization event (string one |
194 of "bookmarks", "history", "passwords", "useragents" or "speeddial") |
196 of "bookmarks", "history", "passwords", "useragents" or |
|
197 "speeddial") |
195 </dd><dt><i>fileName</i></dt> |
198 </dd><dt><i>fileName</i></dt> |
196 <dd> |
199 <dd> |
197 name of the file to be downloaded (string) |
200 name of the file to be downloaded (string) |
198 </dd><dt><i>timestamp</i></dt> |
201 </dd><dt><i>timestamp</i></dt> |
199 <dd> |
202 <dd> |
200 time stamp in seconds of the file to be downloaded (int) |
203 time stamp in seconds of the file to be downloaded |
|
204 (integer) |
201 </dd> |
205 </dd> |
202 </dl><a NAME="FtpSyncHandler.__downloadFileCallback" ID="FtpSyncHandler.__downloadFileCallback"></a> |
206 </dl><a NAME="FtpSyncHandler.__downloadFileCallback" ID="FtpSyncHandler.__downloadFileCallback"></a> |
203 <h4>FtpSyncHandler.__downloadFileCallback</h4> |
207 <h4>FtpSyncHandler.__downloadFileCallback</h4> |
204 <b>__downloadFileCallback</b>(<i>buffer, data</i>) |
208 <b>__downloadFileCallback</b>(<i>buffer, data</i>) |
205 <p> |
209 <p> |
234 Private method to do the initial synchronization of the given file. |
238 Private method to do the initial synchronization of the given file. |
235 </p><dl> |
239 </p><dl> |
236 <dt><i>type_</i></dt> |
240 <dt><i>type_</i></dt> |
237 <dd> |
241 <dd> |
238 type of the synchronization event (string one |
242 type of the synchronization event (string one |
239 of "bookmarks", "history", "passwords", "useragents" or "speeddial") |
243 of "bookmarks", "history", "passwords", "useragents" or |
|
244 "speeddial") |
240 </dd><dt><i>fileName</i></dt> |
245 </dd><dt><i>fileName</i></dt> |
241 <dd> |
246 <dd> |
242 name of the file to be synchronized (string) |
247 name of the file to be synchronized (string) |
243 </dd> |
248 </dd> |
244 </dl><a NAME="FtpSyncHandler.__syncFile" ID="FtpSyncHandler.__syncFile"></a> |
249 </dl><a NAME="FtpSyncHandler.__syncFile" ID="FtpSyncHandler.__syncFile"></a> |
248 Private method to synchronize the given file. |
253 Private method to synchronize the given file. |
249 </p><dl> |
254 </p><dl> |
250 <dt><i>type_</i></dt> |
255 <dt><i>type_</i></dt> |
251 <dd> |
256 <dd> |
252 type of the synchronization event (string one |
257 type of the synchronization event (string one |
253 of "bookmarks", "history", "passwords", "useragents" or "speeddial") |
258 of "bookmarks", "history", "passwords", "useragents" or |
|
259 "speeddial") |
254 </dd><dt><i>fileName</i></dt> |
260 </dd><dt><i>fileName</i></dt> |
255 <dd> |
261 <dd> |
256 name of the file to be synchronized (string) |
262 name of the file to be synchronized (string) |
257 </dd> |
263 </dd> |
258 </dl><a NAME="FtpSyncHandler.__uploadFile" ID="FtpSyncHandler.__uploadFile"></a> |
264 </dl><a NAME="FtpSyncHandler.__uploadFile" ID="FtpSyncHandler.__uploadFile"></a> |
262 Private method to upload the given file. |
268 Private method to upload the given file. |
263 </p><dl> |
269 </p><dl> |
264 <dt><i>type_</i></dt> |
270 <dt><i>type_</i></dt> |
265 <dd> |
271 <dd> |
266 type of the synchronization event (string one |
272 type of the synchronization event (string one |
267 of "bookmarks", "history", "passwords", "useragents" or "speeddial") |
273 of "bookmarks", "history", "passwords", "useragents" or |
|
274 "speeddial") |
268 </dd><dt><i>fileName</i></dt> |
275 </dd><dt><i>fileName</i></dt> |
269 <dd> |
276 <dd> |
270 name of the file to be uploaded (string) |
277 name of the file to be uploaded (string) |
271 </dd> |
278 </dd> |
272 </dl><dl> |
279 </dl><dl> |
280 <p> |
287 <p> |
281 Public method to do the initial check. |
288 Public method to do the initial check. |
282 </p><dl> |
289 </p><dl> |
283 <dt><i>forceUpload=</i></dt> |
290 <dt><i>forceUpload=</i></dt> |
284 <dd> |
291 <dd> |
285 flag indicating a forced upload of the files (boolean) |
292 flag indicating a forced upload of the files |
|
293 (boolean) |
286 </dd> |
294 </dd> |
287 </dl><a NAME="FtpSyncHandler.shutdown" ID="FtpSyncHandler.shutdown"></a> |
295 </dl><a NAME="FtpSyncHandler.shutdown" ID="FtpSyncHandler.shutdown"></a> |
288 <h4>FtpSyncHandler.shutdown</h4> |
296 <h4>FtpSyncHandler.shutdown</h4> |
289 <b>shutdown</b>(<i></i>) |
297 <b>shutdown</b>(<i></i>) |
290 <p> |
298 <p> |