Class AudioSink.InitializationException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- com.google.android.exoplayer2.audio.AudioSink.InitializationException
-
- All Implemented Interfaces:
Serializable
- Enclosing interface:
- AudioSink
public static final class AudioSink.InitializationException extends Exception
Thrown when a failure occurs initializing the sink.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description intaudioTrackStateThe underlyingAudioTrack's state.FormatformatThe inputFormatof the sink when the error occurs.booleanisRecoverableIf the exception can be recovered by recreating the sink.
-
Constructor Summary
Constructors Constructor Description InitializationException(int audioTrackState, int sampleRate, int channelConfig, int bufferSize, Format format, boolean isRecoverable, Exception audioTrackException)Creates a new instance.
-
Method Summary
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Field Detail
-
audioTrackState
public final int audioTrackState
The underlyingAudioTrack's state.
-
isRecoverable
public final boolean isRecoverable
If the exception can be recovered by recreating the sink.
-
-
Constructor Detail
-
InitializationException
public InitializationException(int audioTrackState, int sampleRate, int channelConfig, int bufferSize, Format format, boolean isRecoverable, @Nullable Exception audioTrackException)Creates a new instance.- Parameters:
audioTrackState- The underlyingAudioTrack's state.sampleRate- The requested sample rate in Hz.channelConfig- The requested channel configuration.bufferSize- The requested buffer size in bytes.format- The input format of the sink when the error occurs.isRecoverable- Whether the exception can be recovered by recreating the sink.audioTrackException- Exception thrown during the creation of theAudioTrack.
-
-