- Sort Score
- Num 10 results
- Language All
Results 1 - 10 of 18 for cacheControl (0.51 seconds)
-
okhttp/src/commonJvmAndroid/kotlin/okhttp3/Request.kt
/** * Sets this request's `Cache-Control` header, replacing any cache control headers already * present. If [cacheControl] doesn't define any directives, this clears this request's * cache-control headers. */ open fun cacheControl(cacheControl: CacheControl): Builder { val value = cacheControl.toString() return when { value.isEmpty() -> removeHeader("Cache-Control")Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Thu Oct 30 13:46:58 GMT 2025 - 14.7K bytes - Click Count (1) -
okhttp/src/jvmTest/kotlin/okhttp3/KotlinSourceModernTest.kt
val minFreshSeconds: Int = cacheControl.minFreshSeconds val onlyIfCached: Boolean = cacheControl.onlyIfCached val noTransform: Boolean = cacheControl.noTransform val immutable: Boolean = cacheControl.immutable val forceCache: CacheControl = CacheControl.FORCE_CACHE val forceNetwork: CacheControl = CacheControl.FORCE_NETWORK val parse: CacheControl = CacheControl.parse(headersOf()) } @TestCreated: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Wed Nov 05 18:28:35 GMT 2025 - 47K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/RequestCommonTest.kt
} @Test fun cacheControl() { val request = Request .Builder() .cacheControl(CacheControl.Builder().noCache().build()) .url("https://square.com") .build() assertThat(request.headers("Cache-Control")).containsExactly("no-cache") assertThat(request.cacheControl.noCache).isTrue() } @TestCreated: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Fri Oct 24 11:36:14 GMT 2025 - 10.9K bytes - Click Count (0) -
okhttp/api/android/okhttp.api
public final fun maxStale (ILjava/util/concurrent/TimeUnit;)Lokhttp3/CacheControl$Builder; public final fun maxStale-LRDsOJo (J)Lokhttp3/CacheControl$Builder; public final fun minFresh (ILjava/util/concurrent/TimeUnit;)Lokhttp3/CacheControl$Builder; public final fun minFresh-LRDsOJo (J)Lokhttp3/CacheControl$Builder; public final fun noCache ()Lokhttp3/CacheControl$Builder;
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Wed Nov 05 18:28:35 GMT 2025 - 70.3K bytes - Click Count (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/Cache.kt
* Request request = new Request.Builder() * .cacheControl(new CacheControl.Builder() * .maxStale(365, TimeUnit.DAYS) * .build()) * .url("http://publicobject.com/helloworld.txt") * .build(); * ``` * * The [CacheControl] class can configure request caching directives and parse response caching * directives. It even offers convenient constants [CacheControl.FORCE_NETWORK] and
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Fri Oct 03 17:41:45 GMT 2025 - 26.8K bytes - Click Count (0) -
okhttp/api/jvm/okhttp.api
public final fun maxStale (ILjava/util/concurrent/TimeUnit;)Lokhttp3/CacheControl$Builder; public final fun maxStale-LRDsOJo (J)Lokhttp3/CacheControl$Builder; public final fun minFresh (ILjava/util/concurrent/TimeUnit;)Lokhttp3/CacheControl$Builder; public final fun minFresh-LRDsOJo (J)Lokhttp3/CacheControl$Builder; public final fun noCache ()Lokhttp3/CacheControl$Builder;
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Wed Nov 05 18:28:35 GMT 2025 - 70.2K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/RequestTest.kt
} @Test fun cacheControl() { val request = Request .Builder() .cacheControl(CacheControl.Builder().noCache().build()) .url("https://square.com") .build() assertThat(request.headers("Cache-Control")).containsExactly("no-cache") assertThat(request.cacheControl.noCache).isTrue() } @TestCreated: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Fri Oct 24 11:36:14 GMT 2025 - 24.4K bytes - Click Count (0) -
android-test/src/androidTest/java/okhttp/android/test/OkHttpTest.kt
.use { assertEquals(200, it.code) assertNull(it.cacheResponse) assertNotNull(it.networkResponse) assertEquals(3, it.cacheControl.maxAgeSeconds) assertTrue(it.cacheControl.isPublic) } client .newCall(request) .execute() .use { assertEquals(200, it.code)Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 29.9K bytes - Click Count (0) -
cmd/api-headers.go
} // setEventStreamHeaders to allow proxies to avoid buffering proxy responses func setEventStreamHeaders(w http.ResponseWriter) { w.Header().Set(xhttp.ContentType, "text/event-stream") w.Header().Set(xhttp.CacheControl, "no-cache") // nginx to turn off buffering w.Header().Set("X-Accel-Buffering", "no") // nginx to turn off buffering } // Write http common headers func setCommonHeaders(w http.ResponseWriter) {
Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 8.6K bytes - Click Count (0) -
cmd/object-api-datatypes_gen.go
z.Expires, bts, err = msgp.ReadTimeBytes(bts) if err != nil { err = msgp.WrapError(err, "Expires") return } case "CacheControl": z.CacheControl, bts, err = msgp.ReadStringBytes(bts) if err != nil { err = msgp.WrapError(err, "CacheControl") return } case "StorageClass": z.StorageClass, bts, err = msgp.ReadStringBytes(bts) if err != nil {
Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Sun Sep 28 20:59:21 GMT 2025 - 71.7K bytes - Click Count (0)