NetworkResponsepublic class NetworkResponse extends Object Data and headers returned from {@link Network#performRequest(Request)}. |
Fields Summary |
---|
public final int | statusCodeThe HTTP status code. | public final byte[] | dataRaw data from this response. | public final Map | headersResponse headers. | public final boolean | notModifiedTrue if the server returned a 304 (Not Modified). |
Constructors Summary |
---|
public NetworkResponse(int statusCode, byte[] data, Map headers, boolean notModified)Creates a new network response.
this.statusCode = statusCode;
this.data = data;
this.headers = headers;
this.notModified = notModified;
| public NetworkResponse(byte[] data)
this(HttpStatus.SC_OK, data, Collections.<String, String>emptyMap(), false);
| public NetworkResponse(byte[] data, Map headers)
this(HttpStatus.SC_OK, data, headers, false);
|
|