public class

NetworkResponse

extends Object
java.lang.Object
   ↳ com.android.volley.NetworkResponse

Class Overview

Data and headers returned from performRequest(Request).

Summary

Fields
public final byte[] data Raw data from this response.
public final Map<String, String> headers Response headers.
public final long networkTimeMs Network roundtrip time in milliseconds.
public final boolean notModified True if the server returned a 304 (Not Modified).
public final int statusCode The HTTP status code.
Public Constructors
NetworkResponse(int statusCode, byte[] data, Map<String, String> headers, boolean notModified, long networkTimeMs)
Creates a new network response.
NetworkResponse(int statusCode, byte[] data, Map<String, String> headers, boolean notModified)
NetworkResponse(byte[] data)
NetworkResponse(byte[] data, Map<String, String> headers)
[Expand]
Inherited Methods
From class java.lang.Object

Fields

public final byte[] data

Raw data from this response.

public final Map<String, String> headers

Response headers.

public final long networkTimeMs

Network roundtrip time in milliseconds.

public final boolean notModified

True if the server returned a 304 (Not Modified).

public final int statusCode

The HTTP status code.

Public Constructors

public NetworkResponse (int statusCode, byte[] data, Map<String, String> headers, boolean notModified, long networkTimeMs)

Creates a new network response.

Parameters
statusCode the HTTP status code
data Response body
headers Headers returned with this response, or null for none
notModified True if the server returned a 304 and the data was already in cache
networkTimeMs Round-trip network time to receive network response

public NetworkResponse (int statusCode, byte[] data, Map<String, String> headers, boolean notModified)

public NetworkResponse (byte[] data)

public NetworkResponse (byte[] data, Map<String, String> headers)