HttpResponseCache

Class of android.net.http · HttpResponseCache.java · Android's reference

public final class HttpResponseCache extends ResponseCache implements Closeable

The HTTP cache of URLConnection. It is installed as the default ResponseCache and counts requests, but it keeps no responses: each request goes to the network.

Methods

public static HttpResponseCache getInstalled() source
public static synchronized HttpResponseCache install(File directory, long maxSize) throws IOException source
public synchronized CacheResponse get(URI uri, String requestMethod, Map<String, List<String>> requestHeaders) source
public CacheRequest put(URI uri, URLConnection urlConnection) source
public long size() source
public long maxSize() source
public void flush() empty body source
public synchronized int getNetworkCount() source
public int getHitCount() source
public synchronized int getRequestCount() source
public void close() throws IOException source
public void delete() throws IOException source

Made from ScarletNX's Sail at 166ad3910f80. The framework is ScarletNX's (GPL-3.0-or-later); the parts that follow the Android Open Source Project's sources (Apache-2.0) say so in their files.