AudioSink.WriteException


public final class AudioSink.WriteException extends Exception


Thrown when a failure occurs writing to the sink.

Summary

Public fields

final int

The error value returned from the sink implementation.

final Format

The input Format of the sink when the error occurs.

final boolean

If the exception can be recovered by recreating the sink.

Public constructors

WriteException(int errorCode, Format format, boolean isRecoverable)

Creates an instance.

Inherited methods

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 fields

errorCode

public final int errorCode

The error value returned from the sink implementation. If the sink writes to a platform AudioTrack, this will be the error value returned from write or write. Otherwise, the meaning of the error code depends on the sink implementation.

format

public final Format format

The input Format of the sink when the error occurs.

isRecoverable

public final boolean isRecoverable

If the exception can be recovered by recreating the sink.

Public constructors

WriteException

public WriteException(int errorCode, Format format, boolean isRecoverable)

Creates an instance.

Parameters
int errorCode

The error value returned from the sink implementation.

Format format

The input format of the sink when the error occurs.

boolean isRecoverable

Whether the exception can be recovered by recreating the sink.