SyncResult Constructor

Definition

Create a "clean" SyncResult.

[Android.Runtime.Register(".ctor", "()V", "")]
public SyncResult ();
Attributes

Remarks

Create a "clean" SyncResult. If this is returned without any changes then the SyncManager will consider the sync to have completed successfully. The various fields can be set by the SyncAdapter in order to give the SyncManager more information as to the disposition of the sync.

The errors are classified into two broad categories: hard errors and soft errors. Soft errors are retried with exponential backoff. Hard errors are not retried (except when the hard error is for a ContentResolver#SYNC_EXTRAS_UPLOAD request, in which the request is retryed without the ContentResolver#SYNC_EXTRAS_UPLOAD extra set). The SyncManager checks the type of error by calling SyncResult#hasHardError() and SyncResult#hasSoftError(). If both are true then the SyncManager treats it as a hard error, not a soft error.

Java documentation for android.content.SyncResult.SyncResult().

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to