Loading Android.mk +2 −1 Original line number Diff line number Diff line Loading @@ -235,7 +235,7 @@ LOCAL_INTERMEDIATE_SOURCES := \ $(framework_res_source_path)/com/android/internal/R.java LOCAL_NO_STANDARD_LIBRARIES := true LOCAL_JAVA_LIBRARIES := bouncycastle core core-junit ext LOCAL_JAVA_LIBRARIES := bouncycastle core core-junit ext okhttp LOCAL_MODULE := framework LOCAL_MODULE_CLASS := JAVA_LIBRARIES Loading Loading @@ -401,6 +401,7 @@ framework_docs_LOCAL_INTERMEDIATE_SOURCES := \ framework_docs_LOCAL_JAVA_LIBRARIES := \ bouncycastle \ core \ okhttp \ ext \ framework \ mms-common \ Loading core/java/android/net/http/HttpResponseCache.java +8 −7 Original line number Diff line number Diff line Loading @@ -17,21 +17,21 @@ package android.net.http; import android.content.Context; import com.android.okhttp.OkResponseCache; import com.android.okhttp.ResponseSource; import com.android.okhttp.internal.DiskLruCache; import java.io.Closeable; import java.io.File; import java.io.IOException; import java.net.CacheRequest; import java.net.CacheResponse; import java.net.ExtendedResponseCache; import java.net.HttpURLConnection; import java.net.ResponseCache; import java.net.ResponseSource; import java.net.URI; import java.net.URLConnection; import java.util.List; import java.util.Map; import javax.net.ssl.HttpsURLConnection; import libcore.io.DiskLruCache; import libcore.io.IoUtils; import org.apache.http.impl.client.DefaultHttpClient; Loading Loading @@ -152,12 +152,12 @@ import org.apache.http.impl.client.DefaultHttpClient; * }}</pre> */ public final class HttpResponseCache extends ResponseCache implements Closeable, ExtendedResponseCache { implements Closeable, OkResponseCache { private final libcore.net.http.HttpResponseCache delegate; private final com.android.okhttp.internal.http.HttpResponseCache delegate; private HttpResponseCache(File directory, long maxSize) throws IOException { this.delegate = new libcore.net.http.HttpResponseCache(directory, maxSize); this.delegate = new com.android.okhttp.internal.http.HttpResponseCache(directory, maxSize); } /** Loading Loading @@ -274,7 +274,8 @@ public final class HttpResponseCache extends ResponseCache } /** @hide */ @Override public void update(CacheResponse conditionalCacheHit, HttpURLConnection connection) { @Override public void update(CacheResponse conditionalCacheHit, HttpURLConnection connection) throws IOException { delegate.update(conditionalCacheHit, connection); } Loading Loading
Android.mk +2 −1 Original line number Diff line number Diff line Loading @@ -235,7 +235,7 @@ LOCAL_INTERMEDIATE_SOURCES := \ $(framework_res_source_path)/com/android/internal/R.java LOCAL_NO_STANDARD_LIBRARIES := true LOCAL_JAVA_LIBRARIES := bouncycastle core core-junit ext LOCAL_JAVA_LIBRARIES := bouncycastle core core-junit ext okhttp LOCAL_MODULE := framework LOCAL_MODULE_CLASS := JAVA_LIBRARIES Loading Loading @@ -401,6 +401,7 @@ framework_docs_LOCAL_INTERMEDIATE_SOURCES := \ framework_docs_LOCAL_JAVA_LIBRARIES := \ bouncycastle \ core \ okhttp \ ext \ framework \ mms-common \ Loading
core/java/android/net/http/HttpResponseCache.java +8 −7 Original line number Diff line number Diff line Loading @@ -17,21 +17,21 @@ package android.net.http; import android.content.Context; import com.android.okhttp.OkResponseCache; import com.android.okhttp.ResponseSource; import com.android.okhttp.internal.DiskLruCache; import java.io.Closeable; import java.io.File; import java.io.IOException; import java.net.CacheRequest; import java.net.CacheResponse; import java.net.ExtendedResponseCache; import java.net.HttpURLConnection; import java.net.ResponseCache; import java.net.ResponseSource; import java.net.URI; import java.net.URLConnection; import java.util.List; import java.util.Map; import javax.net.ssl.HttpsURLConnection; import libcore.io.DiskLruCache; import libcore.io.IoUtils; import org.apache.http.impl.client.DefaultHttpClient; Loading Loading @@ -152,12 +152,12 @@ import org.apache.http.impl.client.DefaultHttpClient; * }}</pre> */ public final class HttpResponseCache extends ResponseCache implements Closeable, ExtendedResponseCache { implements Closeable, OkResponseCache { private final libcore.net.http.HttpResponseCache delegate; private final com.android.okhttp.internal.http.HttpResponseCache delegate; private HttpResponseCache(File directory, long maxSize) throws IOException { this.delegate = new libcore.net.http.HttpResponseCache(directory, maxSize); this.delegate = new com.android.okhttp.internal.http.HttpResponseCache(directory, maxSize); } /** Loading Loading @@ -274,7 +274,8 @@ public final class HttpResponseCache extends ResponseCache } /** @hide */ @Override public void update(CacheResponse conditionalCacheHit, HttpURLConnection connection) { @Override public void update(CacheResponse conditionalCacheHit, HttpURLConnection connection) throws IOException { delegate.update(conditionalCacheHit, connection); } Loading