- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 75 for cache1 (0.16 sec)
-
okhttp/src/main/kotlin/okhttp3/internal/-CacheControlCommon.kt
when { name.equals("Cache-Control", ignoreCase = true) -> { if (headerValue != null) { // Multiple cache-control headers means we can't use the raw value. canUseHeaderValue = false } else { headerValue = value } } name.equals("Pragma", ignoreCase = true) -> { // Might specify additional cache-control params. We invalidate just in case.
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Apr 15 13:41:01 GMT 2024 - 7.2K bytes - Viewed (0) -
native-image-tests/src/main/resources/testlist.txt
okhttp3.dnsoverhttps.DnsOverHttpsTest okhttp3.dnsoverhttps.DnsRecordCodecTest okhttp3.internal.UtilTest okhttp3.internal.authenticator.JavaNetAuthenticatorTest okhttp3.internal.cache.DiskLruCacheTest okhttp3.internal.cache2.FileOperatorTest okhttp3.internal.cache2.RelayTest okhttp3.internal.concurrent.TaskLoggerTest okhttp3.internal.concurrent.TaskRunnerRealBackendTest okhttp3.internal.concurrent.TaskRunnerTest
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu May 11 14:48:57 GMT 2023 - 2.8K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/cache2/RelayTest.kt
import java.util.concurrent.Callable import java.util.concurrent.Executors import kotlin.test.assertFailsWith import okhttp3.TestUtil.threadFactory import okhttp3.internal.cache2.Relay.Companion.edit import okhttp3.internal.cache2.Relay.Companion.read import okio.Buffer import okio.ByteString import okio.ByteString.Companion.encodeUtf8 import okio.Pipe import okio.Source import okio.buffer import okio.source
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 11 22:09:35 GMT 2024 - 8.1K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/Response.kt
* the network, such as when the response is fully cached. The body of the returned response * should not be read. */ @get:JvmName("networkResponse") val networkResponse: Response?, /** * Returns the raw response received from the cache. Will be null if this response didn't use * the cache. For conditional get requests the cache response and network response may both be
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Tue Jan 23 14:31:42 GMT 2024 - 15.5K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/CallTest.kt
executeSynchronously("/", "Cache-Control", "only-if-cached") .assertCode(504) .assertBody("") .assertNoNetworkResponse() .assertNoCacheResponse() } @Test fun networkDropsOnConditionalGet() { client = client.newBuilder() .cache(cache) .build() // Seed the cache. server.enqueue( MockResponse(
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Wed Apr 10 19:46:48 GMT 2024 - 142.5K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/cache/CacheInterceptor.kt
import okio.Source import okio.Timeout import okio.buffer /** Serves requests from the cache and writes responses to the cache. */ class CacheInterceptor(internal val cache: Cache?) : Interceptor { @Throws(IOException::class) override fun intercept(chain: Interceptor.Chain): Response { val call = chain.call() val cacheCandidate = cache?.get(chain.request().requestForCache()) val now = System.currentTimeMillis()
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Fri Mar 22 07:09:21 GMT 2024 - 10.2K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/CacheCorruptionTest.kt
cache = buildCache("/cache/".toPath(), Int.MAX_VALUE.toLong(), loggingFileSystem) client = clientTestRule.newClientBuilder() .cache(cache) .cookieJar(JavaNetCookieJar(cookieManager)) .build() } @AfterEach fun tearDown() { ResponseCache.setDefault(null) if (this::cache.isInitialized) { cache.delete() } } @Test
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat Jan 20 10:30:28 GMT 2024 - 6K bytes - Viewed (1) -
docs/features/caching.md
- ConnectionReleased - CallEnd ## Cache directory The cache directory must be exclusively owned by a single instance. Deleting the cache when it is no longer needed can be done. However this may delete the purpose of the cache which is designed to persist between app restarts. ```kotlin cache.delete() ``` ## Pruning the Cache Pruning the entire Cache to clear space temporarily can be done using evictAll.
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sun Feb 06 02:19:09 GMT 2022 - 3.1K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/kt/CacheResponse.kt
*/ package okhttp3.recipes.kt import java.io.File import java.io.IOException import okhttp3.Cache import okhttp3.OkHttpClient import okhttp3.Request class CacheResponse(cacheDirectory: File) { private val client: OkHttpClient = OkHttpClient.Builder() .cache( Cache( directory = cacheDirectory, // 1 MiB. maxSize = 10L * 1024L * 1024L, ),
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 2K bytes - Viewed (2) -
okhttp-android/src/test/kotlin/okhttp3/android/RobolectricOkHttpClientTest.kt
private lateinit var client: OkHttpClient @Before fun setUp() { context = ApplicationProvider.getApplicationContext<Application>() client = OkHttpClient.Builder() .cache(Cache(FakeFileSystem(), "/cache".toPath(), 10_000_000)) .build() } @Test fun testRequestExternal() { assumeNetwork() val request = Request("https://www.google.com/robots.txt".toHttpUrl())
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Wed Apr 10 19:46:48 GMT 2024 - 2.5K bytes - Viewed (0)