AssetDataSource.AssetDataSourceException


public final class AssetDataSource.AssetDataSourceException extends DataSourceException


Thrown when an IOException is encountered reading a local asset.

Summary

Public constructors

This method is deprecated.

Use AssetDataSourceException.

Creates a new instance.

Inherited Constants

From androidx.media3.datasource.DataSourceException
static final int

This field is deprecated.

Use ERROR_CODE_IO_READ_POSITION_OUT_OF_RANGE.

Inherited fields

From androidx.media3.datasource.DataSourceException
final int

The reason of this DataSourceException, should be one of the ERROR_CODE_IO_* in PlaybackException.ErrorCode.

Inherited methods

From androidx.media3.datasource.DataSourceException
static boolean

Returns whether the given IOException was caused by a DataSourceException whose reason is ERROR_CODE_IO_READ_POSITION_OUT_OF_RANGE in its cause stack.

From java.lang.Throwable
synchronized final void
synchronized Throwable
synchronized Throwable
String
String
StackTraceElement[]
synchronized final Throwable[]
synchronized Throwable
void
void
setStackTrace(StackTraceElement[] stackTrace)
String

Public constructors

AssetDataSourceException

public AssetDataSourceException(IOException cause)

AssetDataSourceException

public AssetDataSourceException(
    @Nullable Throwable cause,
    @PlaybackException.ErrorCode int errorCode
)

Creates a new instance.

Parameters
@Nullable Throwable cause

The error cause.

@PlaybackException.ErrorCode int errorCode

See PlaybackException.ErrorCode.