docs/doc/reference/com/google/android/exoplayer2/testutil/AssetContentProvider.html
Package com.google.android.exoplayer2.testutil
All Implemented Interfaces:ComponentCallbacks, ComponentCallbacks2, ContentProvider.PipeDataWriter<Object>
public final classAssetContentProviderextends[ContentProvider](https://developer.android.com/reference/android/content/ContentProvider.html "class or interface in android.content")implements[ContentProvider.PipeDataWriter](https://developer.android.com/reference/android/content/ContentProvider.PipeDataWriter.html "class or interface in android.content")<[Object](https://developer.android.com/reference/java/lang/Object.html?is-external=true "class or interface in java.lang")>
A ContentProvider for reading asset data.
-
ContentProvider.CallingIdentity, ContentProvider.PipeDataWriter<T extends Object>
-
TRIM_MEMORY_BACKGROUND, TRIM_MEMORY_COMPLETE, TRIM_MEMORY_MODERATE, TRIM_MEMORY_RUNNING_CRITICAL, TRIM_MEMORY_RUNNING_LOW, TRIM_MEMORY_RUNNING_MODERATE, TRIM_MEMORY_UI_HIDDEN
Constructors | Constructor | Description |
| --- | --- |
| AssetContentProvider() | |
All Methods Static Methods Instance Methods Concrete Methods | Modifier and Type | Method | Description |
| --- | --- | --- |
| static Uri | buildUri(String filePath, boolean pipeMode) | |
| int | delete(Uri uri, String selection, String[] selectionArgs) | |
| String | getType(Uri uri) | |
| Uri | insert(Uri uri, ContentValues values) | |
| boolean | onCreate() | |
| AssetFileDescriptor | openAssetFile(Uri uri, String mode) | |
| Cursor | query(Uri uri, String[] projection, String selection, String[] selectionArgs, String sortOrder) | |
| int | update(Uri uri, ContentValues values, String selection, String[] selectionArgs) | |
| void | writeDataToPipe(ParcelFileDescriptor output, Uri uri, String mimeType, Bundle opts, Object args) | |
-
applyBatch, applyBatch, attachInfo, bulkInsert, call, call, canonicalize, clearCallingIdentity, delete, dump, getCallingAttributionSource, getCallingAttributionTag, getCallingPackage, getCallingPackageUnchecked, getContext, getPathPermissions, getReadPermission, getStreamTypes, getWritePermission, insert, isTemporary, onCallingPackageChanged, onConfigurationChanged, onLowMemory, onTrimMemory, openAssetFile, openFile, openFile, openFileHelper, openPipeHelper, openTypedAssetFile, openTypedAssetFile, query, query, refresh, requireContext, restoreCallingIdentity, setPathPermissions, setReadPermission, setWritePermission, shutdown, uncanonicalize, update
-
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
public AssetContentProvider()
-
public static[Uri](https://developer.android.com/reference/android/net/Uri.html "class or interface in android.net")buildUri([String](https://developer.android.com/reference/java/lang/String.html?is-external=true "class or interface in java.lang")filePath,
boolean pipeMode)
-
public boolean onCreate()
Specified by:onCreate in class ContentProvider
-
public[Cursor](https://developer.android.com/reference/android/database/Cursor.html "class or interface in android.database")query([Uri](https://developer.android.com/reference/android/net/Uri.html?is-external=true "class or interface in android.net")uri,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")[] projection,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")selection,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")[] selectionArgs,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")sortOrder)
Specified by:query in class ContentProvider
-
public[AssetFileDescriptor](https://developer.android.com/reference/android/content/res/AssetFileDescriptor.html "class or interface in android.content.res")openAssetFile([Uri](https://developer.android.com/reference/android/net/Uri.html?is-external=true "class or interface in android.net")uri,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")mode)
throws[FileNotFoundException](https://developer.android.com/reference/java/io/FileNotFoundException.html "class or interface in java.io")
Overrides:openAssetFile in class ContentProviderThrows:FileNotFoundException
-
public[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")getType([Uri](https://developer.android.com/reference/android/net/Uri.html?is-external=true "class or interface in android.net")uri)
Specified by:getType in class ContentProvider
-
public[Uri](https://developer.android.com/reference/android/net/Uri.html "class or interface in android.net")insert([Uri](https://developer.android.com/reference/android/net/Uri.html?is-external=true "class or interface in android.net")uri,[ContentValues](https://developer.android.com/reference/android/content/ContentValues.html "class or interface in android.content")values)
Specified by:insert in class ContentProvider
-
public int delete([Uri](https://developer.android.com/reference/android/net/Uri.html "class or interface in android.net")uri,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")selection,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")[] selectionArgs)
Specified by:delete in class ContentProvider
-
public int update([Uri](https://developer.android.com/reference/android/net/Uri.html "class or interface in android.net")uri,[ContentValues](https://developer.android.com/reference/android/content/ContentValues.html "class or interface in android.content")values,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")selection,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")[] selectionArgs)
Specified by:update in class ContentProvider
-
public void writeDataToPipe([ParcelFileDescriptor](https://developer.android.com/reference/android/os/ParcelFileDescriptor.html "class or interface in android.os")output,[Uri](https://developer.android.com/reference/android/net/Uri.html "class or interface in android.net")uri,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")mimeType,
@Nullable[Bundle](https://developer.android.com/reference/android/os/Bundle.html "class or interface in android.os")opts,
@Nullable[Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")args)
Specified by:writeDataToPipe in interface ContentProvider.PipeDataWriter<Object>