docs/doc/reference/com/google/android/exoplayer2/testutil/WebServerDispatcher.Resource.html
Package com.google.android.exoplayer2.testutil
Enclosing class:WebServerDispatcher
public static classWebServerDispatcher.Resourceextends[Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")
A resource served by WebServerDispatcher.
Nested Classes | Modifier and Type | Class | Description |
| --- | --- | --- |
| static class | WebServerDispatcher.Resource.Builder |
Builder for WebServerDispatcher.Resource.
|
Fields | Modifier and Type | Field | Description |
| --- | --- | --- |
| static int | GZIP_SUPPORT_DISABLED |
The server doesn't support gzip.
|
| static int | GZIP_SUPPORT_ENABLED |
The server supports gzip.
|
| static int | GZIP_SUPPORT_FORCED |
The server supports gzip.
|
All Methods Instance Methods Concrete Methods | Modifier and Type | Method | Description |
| --- | --- | --- |
| WebServerDispatcher.Resource.Builder | buildUpon() |
Returns a new WebServerDispatcher.Resource.Builder initialized with the values from this instance.
|
| byte[] | getData() |
Returns the data served by this resource.
|
| @com.google.android.exoplayer2.testutil.WebServerDispatcher.Resource.GzipSupport int | getGzipSupport() |
Returns the level of gzip support the server should provide for this resource.
|
| String | getPath() |
Returns the path this resource is available at.
|
| boolean | resolvesToUnknownLength() |
Returns true if the resource should resolve to an unknown length.
|
| boolean | supportsRangeRequests() |
Returns true if RFC 7233 range requests should be supported for this resource.
|
-
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
public static final int GZIP_SUPPORT_DISABLED
The server doesn't support gzip. See Also:Constant Field Values
-
public static final int GZIP_SUPPORT_ENABLED
The server supports gzip. Responses are only compressed if the request signals "gzip" is an acceptable content-coding using an Accept-Encoding header.
See Also:Constant Field Values
-
public static final int GZIP_SUPPORT_FORCED
The server supports gzip. Responses are compressed if the request contains no Accept-Encoding header or one that accepts "gzip".
RFC 2616 14.3 recommends a server use "identity" content-coding if no Accept-Encoding is present, but some servers will still compress responses in this case. This option mimics that behaviour.
See Also:Constant Field Values
-
public[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")getPath()
Returns the path this resource is available at.
-
public byte[] getData()
Returns the data served by this resource.
-
public boolean supportsRangeRequests()
Returns true if RFC 7233 range requests should be supported for this resource.
-
public boolean resolvesToUnknownLength()
Returns true if the resource should resolve to an unknown length.
-
public @com.google.android.exoplayer2.testutil.WebServerDispatcher.Resource.GzipSupport int getGzipSupport()
Returns the level of gzip support the server should provide for this resource.
-
public[WebServerDispatcher.Resource.Builder](WebServerDispatcher.Resource.Builder.html "class in com.google.android.exoplayer2.testutil")buildUpon()
Returns a new WebServerDispatcher.Resource.Builder initialized with the values from this instance.