- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for cacheUrlOverride (0.38 sec)
-
okhttp/src/commonJvmAndroid/kotlin/okhttp3/Request.kt
* * Note that POST requests will not be sent to the server if this URL is set * and matches a cached response. */ fun cacheUrlOverride(cacheUrlOverride: HttpUrl?) = apply { this.cacheUrlOverride = cacheUrlOverride } /** * Configures this request's body to be compressed when it is transmitted. This also adds the * 'Content-Encoding: gzip' header.
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 16 09:39:51 UTC 2025 - 13.1K bytes - Viewed (1) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/cache/CacheInterceptor.kt
} } private fun Request.requestForCache(): Request { val cacheUrlOverride = cacheUrlOverride return if (cacheUrlOverride != null && (method == "GET" || method == "POST")) { newBuilder() .get() .url(cacheUrlOverride) .cacheUrlOverride(null) .build() } else { this }
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed Mar 19 19:25:20 UTC 2025 - 10.3K bytes - Viewed (0) -
okhttp-dnsoverhttps/src/main/kotlin/okhttp3/dnsoverhttps/DnsOverHttps.kt
.apply { val query = DnsRecordCodec.encodeQuery(hostname, type) val dnsUrl: HttpUrl = ******@****.*** if (post) { url(dnsUrl) .cacheUrlOverride( dnsUrl .newBuilder() .addQueryParameter("hostname", hostname) .build(), ).post(query.toRequestBody(DNS_MESSAGE)) } else {
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat May 10 11:15:14 UTC 2025 - 8.6K bytes - Viewed (0) -
okhttp/src/jvmTest/kotlin/okhttp3/CacheTest.kt
fun postWithOverrideResponse() { val url = server.url("/abc?token=123") val cacheUrlOverride = url.newBuilder().removeAllQueryParameters("token").build() val request = Request .Builder() .url(url) .method("POST", "XYZ".toRequestBody()) .cacheUrlOverride(cacheUrlOverride) .build() val response = testBasicCachingRules(request)
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 16 09:39:51 UTC 2025 - 113.6K bytes - Viewed (0) -
okhttp/api/jvm/okhttp.api
public final fun body ()Lokhttp3/RequestBody; public final fun cacheControl ()Lokhttp3/CacheControl; public final fun cacheUrlOverride ()Lokhttp3/HttpUrl; public final fun header (Ljava/lang/String;)Ljava/lang/String; public final fun headers ()Lokhttp3/Headers; public final fun headers (Ljava/lang/String;)Ljava/util/List;
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 16 09:39:51 UTC 2025 - 69.4K bytes - Viewed (0) -
CHANGELOG.md
of OkHttp 5. * Breaking: Reorder the parameters in the Cache constructor that was introduced in 5.0.0-alpha.3. * New: `Request.Builder.cacheUrlOverride()` customizes the cache key used for a request. This can be used to make canonical URLs for the cache that omit insignificant query parameters or other irrelevant data.
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Mon Jul 07 19:32:33 UTC 2025 - 31.6K bytes - Viewed (1) -
okhttp/api/android/okhttp.api
public final fun body ()Lokhttp3/RequestBody; public final fun cacheControl ()Lokhttp3/CacheControl; public final fun cacheUrlOverride ()Lokhttp3/HttpUrl; public final fun header (Ljava/lang/String;)Ljava/lang/String; public final fun headers ()Lokhttp3/Headers; public final fun headers (Ljava/lang/String;)Ljava/util/List;
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 16 09:39:51 UTC 2025 - 69.4K bytes - Viewed (0)