# Print output for @column tags ?>
Developers

- Design
- Develop
- Distribute

Developer Console

## Most visited

## Recently visited

## Results for

# AssetsProvider

`public interface AssetsProvider`
``

android.content.res.loader.AssetsProvider

Provides callbacks that allow for the value of a file-based resources or assets of a `ResourcesProvider` to be specified or overridden.

## Summary

### Public methods
`default AssetFileDescriptor` | `loadAssetFd(String path, int accessMode)` Callback that allows the value of a file-based resources or asset to be specified or overridden.

## Public methods

### loadAssetFd

    public AssetFileDescriptor loadAssetFd (String path,
                    int accessMode)

Callback that allows the value of a file-based resources or asset to be specified or overridden.

The system will take ownership of the file descriptor returned from this method, so `ParcelFileDescriptor#dup()` the file descriptor before returning if the system should not own it.

There are two situations in which this method will be called:

- AssetManager is queried for an InputStream of an asset using APIs like `AssetManager#open` and `AssetManager#openXmlResourceParser`.
- AssetManager is resolving the value of a file-based resource provided by the `ResourcesProvider` this instance is associated with.

If the value retrieved from this callback is null, AssetManager will attempt to find the file-based resource or asset within the APK provided by the ResourcesProvider this instance is associated with.

Parameters
`path` | `String`: the asset path being loaded This value cannot be `null`.
`accessMode` | `int`: the `AssetManager` access mode

Returns
`AssetFileDescriptor` |

See also:

- `AssetManager.open(String)`

Full name *
Email address *
Company / developer name
One of your Play Store app URLs *
Which best describes your business:*
Apps
Games
Apps & Games
*
*