Class HttpDataSource.InvalidResponseCodeException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.io.IOException
-
- com.google.android.exoplayer2.upstream.DataSourceException
-
- com.google.android.exoplayer2.upstream.HttpDataSource.HttpDataSourceException
-
- com.google.android.exoplayer2.upstream.HttpDataSource.InvalidResponseCodeException
-
- All Implemented Interfaces:
Serializable
- Enclosing interface:
- HttpDataSource
public static final class HttpDataSource.InvalidResponseCodeException extends HttpDataSource.HttpDataSourceException
Thrown when an attempt to open a connection results in a response code not in the 2xx range.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.android.exoplayer2.upstream.HttpDataSource.HttpDataSourceException
HttpDataSource.HttpDataSourceException.Type
-
-
Field Summary
Fields Modifier and Type Field Description Map<String,List<String>>
headerFields
An unmodifiable map of the response header fields and values.byte[]
responseBody
The response body.int
responseCode
The response code that was outside of the 2xx range.String
responseMessage
The http status message.-
Fields inherited from class com.google.android.exoplayer2.upstream.HttpDataSource.HttpDataSourceException
dataSpec, type, TYPE_CLOSE, TYPE_OPEN, TYPE_READ
-
Fields inherited from class com.google.android.exoplayer2.upstream.DataSourceException
POSITION_OUT_OF_RANGE, reason
-
-
Constructor Summary
Constructors Constructor Description InvalidResponseCodeException(int responseCode, String responseMessage, IOException cause, Map<String,List<String>> headerFields, DataSpec dataSpec, byte[] responseBody)
InvalidResponseCodeException(int responseCode, String responseMessage, Map<String,List<String>> headerFields, DataSpec dataSpec)
InvalidResponseCodeException(int responseCode, Map<String,List<String>> headerFields, DataSpec dataSpec)
-
Method Summary
-
Methods inherited from class com.google.android.exoplayer2.upstream.HttpDataSource.HttpDataSourceException
createForIOException
-
Methods inherited from class com.google.android.exoplayer2.upstream.DataSourceException
isCausedByPositionOutOfRange
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Field Detail
-
responseCode
public final int responseCode
The response code that was outside of the 2xx range.
-
responseMessage
@Nullable public final String responseMessage
The http status message.
-
headerFields
public final Map<String,List<String>> headerFields
An unmodifiable map of the response header fields and values.
-
responseBody
public final byte[] responseBody
The response body.
-
-
Constructor Detail
-
InvalidResponseCodeException
@Deprecated public InvalidResponseCodeException(int responseCode, Map<String,List<String>> headerFields, DataSpec dataSpec)
-
InvalidResponseCodeException
@Deprecated public InvalidResponseCodeException(int responseCode, @Nullable String responseMessage, Map<String,List<String>> headerFields, DataSpec dataSpec)
-
-