- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for checkDuration (0.06 sec)
-
okhttp/src/jvmTest/kotlin/okhttp3/internal/UtilTest.kt
assertThat(checkDuration("timeout", 1.milliseconds)).isEqualTo(1) assertThat( assertThrows<IllegalStateException> { checkDuration("timeout", (-1).milliseconds) }, ).hasMessage("timeout < 0") assertThat( assertThrows<IllegalArgumentException> { checkDuration("timeout", 1.nanoseconds) }, ).hasMessage("timeout too small")
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Fri Dec 27 13:39:56 UTC 2024 - 3K bytes - Viewed (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http/RealInterceptorChain.kt
return copy(connectTimeoutMillis = checkDuration("connectTimeout", timeout.toLong(), unit)) } override fun readTimeoutMillis(): Int = readTimeoutMillis override fun withReadTimeout( timeout: Int, unit: TimeUnit, ): Interceptor.Chain { check(exchange == null) { "Timeouts can't be adjusted in a network interceptor" } return copy(readTimeoutMillis = checkDuration("readTimeout", timeout.toLong(), unit)) }
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Fri Dec 27 13:39:56 UTC 2024 - 4.2K bytes - Viewed (0)