- Sort Score
- Result 10 results
- Languages All
Results 41 - 50 of 114 for lengthOf (0.16 sec)
-
okhttp/src/test/java/okhttp3/CertificateChainCleanerTest.kt
private fun chainOfLength(length: Int): List<HeldCertificate> { val result = mutableListOf<HeldCertificate>() for (i in 1..length) { result.add( 0, HeldCertificate.Builder() .signedBy(if (result.isNotEmpty()) result[0] else null) .certificateAuthority(length - i) .serialNumber(i.toLong()) .build(), )
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 9.3K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/HttpUrl.kt
*/ @get:JvmName("encodedUsername") val encodedUsername: String get() { if (username.isEmpty()) return "" val usernameStart = scheme.length + 3 // "://".length() == 3. val usernameEnd = url.delimiterOffset(":@", usernameStart, url.length) return url.substring(usernameStart, usernameEnd) } /** * The password, or an empty string if none is set. *
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Tue Jan 09 12:33:05 GMT 2024 - 63.5K bytes - Viewed (1) -
docs/changelogs/changelog_1x.md
* Support asynchronous disconnects by breaking the socket only. This should prevent flakiness from multiple threads concurrently accessing a stream. ## Version 1.5.3 _2014-03-29_ * Fix bug where the Content-Length header was not always dropped when following a redirect from a POST to a GET. * Implement basic support for `Thread.interrupt()`. OkHttp now checks for an interruption before doing a blocking call. If it is interrupted,
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sun Feb 06 02:19:09 GMT 2022 - 6.4K bytes - Viewed (0) -
docs/features/calls.md
the request at a high-level: _“fetch me this URL with these headers.”_ For correctness and efficiency, OkHttp rewrites your request before transmitting it. OkHttp may add headers that are absent from the original request, including `Content-Length`, `Transfer-Encoding`, `User-Agent`, `Host`, `Connection`, and `Content-Type`. It will add an `Accept-Encoding` header for transparent response compression unless the header is already present. If you’ve got cookies, OkHttp will add a `Cookie` header...
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sun Feb 06 02:19:09 GMT 2022 - 3.9K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/CacheCorruptionTest.kt
} @Test fun truncatedMetadataEntry() { val response = testCorruptingCache { corruptMetadata { // truncate metadata to 1/4 of length it.substring(0, it.length / 4) } } assertThat(response.body.string()).isEqualTo("ABC.2") // not cached assertThat(cache.requestCount()).isEqualTo(2) assertThat(cache.networkCount()).isEqualTo(2)
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) -
samples/guide/src/main/java/okhttp3/recipes/CustomCipherSuites.java
TrustManagerFactory.getDefaultAlgorithm()); trustManagerFactory.init((KeyStore) null); TrustManager[] trustManagers = trustManagerFactory.getTrustManagers(); if (trustManagers.length != 1 || !(trustManagers[0] instanceof X509TrustManager)) { throw new IllegalStateException("Unexpected default trust managers:" + Arrays.toString(trustManagers)); }
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Mar 14 21:57:42 GMT 2019 - 6.5K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/Adapters.kt
val bytes = reader.readUnknown() return AnyValue( tagClass = header.tagClass, tag = header.tag, constructed = header.constructed, length = header.length, bytes = bytes, ) } } override fun toDer( writer: DerWriter, value: AnyValue, ) {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 15K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/ws/RealWebSocketTest.kt
val message = repeat('a', RealWebSocket.DEFAULT_MINIMUM_DEFLATE_SIZE.toInt()) server.webSocket!!.send(message) taskFaker.runTasks() assertThat(client.clientSourceBufferSize()) .isGreaterThan(message.length.toLong()) // Not compressed. assertThat(client.processNextFrame()).isTrue() client.listener.assertTextMessage(message) } @Test fun messagesCompressedWhenConfigured() {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 11 01:59:58 GMT 2024 - 18.5K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/http2/HpackTest.kt
bytesIn.writeByte(0x88) // Literal name Huffman encoded 8 bytes // decodes to custom-key which is length 10 bytesIn.write("25a849e95ba97d7f".decodeHex()) bytesIn.writeByte(0x89) // Literal value Huffman encoded 9 bytes // decodes to custom-value which is length 12 bytesIn.write("25a849e95bb8e8b4bf".decodeHex()) } private fun checkReadThirdRequestWithHuffman() {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 38.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/-UtilJvm.kt
currentThread.name = name try { block() } finally { currentThread.name = oldName } } /** Returns the Content-Length as reported by the response headers. */ internal fun Response.headersContentLength(): Long { return headers["Content-Length"]?.toLongOrDefault(-1L) ?: -1L } /** Returns an immutable copy of this. */ internal fun <T> List<T>.toImmutableList(): List<T> {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Tue Jan 09 12:33:05 GMT 2024 - 10.5K bytes - Viewed (0)