final
ContentProviderClient
|
acquireContentProviderClient(
Uri uri)
|
final
ContentProviderClient
|
acquireContentProviderClient(
String name)
|
final
ContentProviderClient
|
acquireUnstableContentProviderClient(
Uri uri)
|
final
ContentProviderClient
|
acquireUnstableContentProviderClient(
String name)
|
static void
|
addPeriodicSync(
Account account,
String authority,
Bundle extras, long pollFrequency)
Specifies that a sync should be requested with the specified the account, authority, and extras at the given frequency.
|
static
Object
|
addStatusChangeListener(int mask,
SyncStatusObserver callback)
Request notifications when the different aspects of the SyncManager change.
|
ContentProviderResult[]
|
applyBatch(
String authority,
ArrayList<
ContentProviderOperation> operations)
|
final int
|
bulkInsert(
Uri url,
ContentValues[] values)
Inserts multiple rows into a table at the given URL.
|
final
Bundle
|
call(
Uri uri,
String method,
String arg,
Bundle extras)
Call a provider-defined method.
|
static void
|
cancelSync(
Account account,
String authority)
Cancel any active or pending syncs that match account and authority.
|
void
|
cancelSync(
Uri uri)
|
final int
|
delete(
Uri url,
String where,
String[] selectionArgs)
Deletes row(s) specified by a content URI.
|
static
SyncInfo
|
getCurrentSync()
This method was deprecated in API level 11. Since multiple concurrent syncs are now supported you should use getCurrentSyncs() to get the accurate list of current syncs. This method returns the first item from the list of current syncs or null if there are none.
|
static
List<
SyncInfo>
|
getCurrentSyncs()
Returns a list with information about all the active syncs.
|
static int
|
getIsSyncable(
Account account,
String authority)
Check if this account/provider is syncable.
|
static boolean
|
getMasterSyncAutomatically()
Gets the master auto-sync setting that applies to all the providers and accounts.
|
static
List<
PeriodicSync>
|
getPeriodicSyncs(
Account account,
String authority)
Get the list of information about the periodic syncs for the given account and authority.
|
String[]
|
getStreamTypes(
Uri url,
String mimeTypeFilter)
|
static
SyncAdapterType[]
|
getSyncAdapterTypes()
Get information about the SyncAdapters that are known to the system.
|
static boolean
|
getSyncAutomatically(
Account account,
String authority)
Check if the provider should be synced when a network tickle is received
This method requires the caller to hold the permission READ_SYNC_SETTINGS .
|
final
String
|
getType(
Uri url)
Return the MIME type of the given content URL.
|
final
Uri
|
insert(
Uri url,
ContentValues values)
Inserts a row into a table at the given URL.
|
static boolean
|
isSyncActive(
Account account,
String authority)
Returns true if there is currently a sync operation for the given account or authority in the pending list, or actively being processed.
|
static boolean
|
isSyncPending(
Account account,
String authority)
Return true if the pending status is true of any matching authorities.
|
void
|
notifyChange(
Uri uri,
ContentObserver observer, boolean syncToNetwork)
Notify registered observers that a row was updated.
|
void
|
notifyChange(
Uri uri,
ContentObserver observer)
Notify registered observers that a row was updated and attempt to sync changes to the network.
|
final
AssetFileDescriptor
|
openAssetFileDescriptor(
Uri uri,
String mode)
Open a raw file descriptor to access data under a URI.
|
final
ParcelFileDescriptor
|
openFileDescriptor(
Uri uri,
String mode)
Open a raw file descriptor to access data under a URI.
|
final
InputStream
|
openInputStream(
Uri uri)
Open a stream on to the content associated with a content URI.
|
final
OutputStream
|
openOutputStream(
Uri uri)
|
final
OutputStream
|
openOutputStream(
Uri uri,
String mode)
Open a stream on to the content associated with a content URI.
|
final
AssetFileDescriptor
|
openTypedAssetFileDescriptor(
Uri uri,
String mimeType,
Bundle opts)
Open a raw file descriptor to access (potentially type transformed) data from a "content:" URI.
|
final
Cursor
|
query(
Uri uri,
String[] projection,
String selection,
String[] selectionArgs,
String sortOrder)
Query the given URI, returning a Cursor over the result set.
|
final
Cursor
|
query(
Uri uri,
String[] projection,
String selection,
String[] selectionArgs,
String sortOrder,
CancellationSignal cancellationSignal)
Query the given URI, returning a Cursor over the result set.
|
final void
|
registerContentObserver(
Uri uri, boolean notifyForDescendents,
ContentObserver observer)
Register an observer class that gets callbacks when data identified by a given content URI changes.
|
static void
|
removePeriodicSync(
Account account,
String authority,
Bundle extras)
Remove a periodic sync.
|
static void
|
removeStatusChangeListener(
Object handle)
Remove a previously registered status change listener.
|
static void
|
requestSync(
Account account,
String authority,
Bundle extras)
Start an asynchronous sync operation.
|
static void
|
setIsSyncable(
Account account,
String authority, int syncable)
Set whether this account/provider is syncable.
|
static void
|
setMasterSyncAutomatically(boolean sync)
Sets the master auto-sync setting that applies to all the providers and accounts.
|
static void
|
setSyncAutomatically(
Account account,
String authority, boolean sync)
Set whether or not the provider is synced when it receives a network tickle.
|
void
|
startSync(
Uri uri,
Bundle extras)
|
final void
|
unregisterContentObserver(
ContentObserver observer)
Unregisters a change observer.
|
final int
|
update(
Uri uri,
ContentValues values,
String where,
String[] selectionArgs)
Update row(s) in a content URI.
|
static void
|
validateSyncExtrasBundle(
Bundle extras)
Check that only values of the following types are in the Bundle:
- Integer
- Long
- Boolean
- Float
- Double
- String
- Account
- null
|