java.lang.Object | |
↳ | android.webkit.WebResourceResponse |
A WebResourceResponse is return by
shouldInterceptRequest(WebView, String)
and
contains the response information for a particular resource.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Construct a response with the given mime type, encoding, and data.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Set the input stream containing the data for this resource.
| |||||||||||
Set the encoding of the response data (i.e.
| |||||||||||
Set the mime type of the response data (i.e.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Construct a response with the given mime type, encoding, and data.
mimeType | The mime type of the data (i.e. text/html). |
---|---|
encoding | The encoding of the bytes read from data. |
data | An InputStream for reading custom data. The implementation
must implement read(byte[]) .
|
Set the input stream containing the data for this resource.
data | An InputStream for reading custom data. The implementation
must implement read(byte[]) .
|
---|
Set the encoding of the response data (i.e. utf-8). This will be used to decode the raw bytes from the input stream.
Set the mime type of the response data (i.e. text/html).