FileDocCategorySizeDatePackage
MockRequest.javaAPI DocAndroid 5.1 API2732Thu Mar 12 22:22:56 GMT 2015com.android.volley.mock

MockRequest

public class MockRequest extends com.android.volley.Request

Fields Summary
private Map
mPostParams
private String
mCacheKey
public boolean
deliverResponse_called
public boolean
parseResponse_called
public boolean
deliverError_called
public boolean
cancel_called
private Priority
mPriority
Constructors Summary
public MockRequest()

        super(Request.Method.GET, "http://foo.com", null);
    
public MockRequest(String url, com.android.volley.Response.ErrorListener listener)

        super(Request.Method.GET, url, listener);
    
Methods Summary
public voidcancel()


    
       
        cancel_called = true;
        super.cancel();
    
public voiddeliverError(com.android.volley.VolleyError error)


    
        
        super.deliverError(error);
        deliverError_called = true;
    
protected voiddeliverResponse(byte[] response)


    
        
        deliverResponse_called = true;
    
public java.lang.StringgetCacheKey()

        return mCacheKey;
    
public java.util.MapgetPostParams()

        return mPostParams;
    
public PrioritygetPriority()

        return mPriority;
    
protected com.android.volley.ResponseparseNetworkResponse(com.android.volley.NetworkResponse response)

        parseResponse_called = true;
        return Response.success(response.data, CacheTestUtils.makeRandomCacheEntry(response.data));
    
public voidsetCacheKey(java.lang.String cacheKey)


        
        mCacheKey = cacheKey;
    
public voidsetPostParams(java.util.Map postParams)


         
        mPostParams = postParams;
    
public voidsetPriority(Priority priority)


        
        mPriority = priority;