Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 70 for 0L (0.9 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/http/HttpHeaders.kt

     */
    private fun Buffer.readToken(): String? {
      var tokenSize = indexOfElement(TOKEN_DELIMITERS)
      if (tokenSize == -1L) tokenSize = size
    
      return when {
        tokenSize != 0L -> readUtf8(tokenSize)
        else -> null
      }
    }
    
    fun CookieJar.receiveHeaders(
      url: HttpUrl,
      headers: Headers,
    ) {
      if (this === CookieJar.NO_COOKIES) return
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 7.2K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/KotlinDeprecationErrorTest.kt

      fun mockWebServer() {
        val mockWebServer = MockWebServer()
        var port: Int = mockWebServer.getPort()
        mockWebServer.setServerSocketFactory(ServerSocketFactory.getDefault())
        mockWebServer.setBodyLimit(0L)
        mockWebServer.setProtocolNegotiationEnabled(false)
        mockWebServer.setProtocols(listOf(Protocol.HTTP_1_1))
        var requestCount: Int = mockWebServer.getRequestCount()
      }
    
      @Test @Disabled
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 13.3K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/HeadersKotlinTest.kt

        assertThat(builder["e"]).isNull()
      }
    
      @Test fun builderSetOperator() {
        val builder = Headers.Builder()
        builder["a"] = "b"
        builder["c"] = "d"
        builder["e"] = Date(0L)
        builder["g"] = Instant.EPOCH
        assertThat(builder["a"]).isEqualTo("b")
        assertThat(builder["c"]).isEqualTo("d")
        assertThat(builder["e"]).isEqualTo("Thu, 01 Jan 1970 00:00:00 GMT")
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Dec 21 01:54:49 GMT 2023
    - 2K bytes
    - Viewed (0)
  4. okhttp/src/main/kotlin/okhttp3/internal/http/CallServerInterceptor.kt

            "close".equals(response.header("Connection"), ignoreCase = true)
          ) {
            exchange.noNewExchangesOnConnection()
          }
          if ((code == 204 || code == 205) && response.body.contentLength() > 0L) {
            throw ProtocolException(
              "HTTP $code had non-zero Content-Length: ${response.body.contentLength()}",
            )
          }
          return response
        } catch (e: IOException) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 6.3K bytes
    - Viewed (1)
  5. okhttp/src/main/kotlin/okhttp3/internal/ws/RealWebSocket.kt

      private val messageAndCloseQueue = ArrayDeque<Any>()
    
      /** The total size in bytes of enqueued but not yet transmitted messages. */
      private var queueSize = 0L
    
      /** True if we've enqueued a close frame. No further message frames will be enqueued. */
      private var enqueuedClose = false
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 01 14:21:25 GMT 2024
    - 22.1K bytes
    - Viewed (0)
  6. okhttp/src/main/kotlin/okhttp3/FormBody.kt

       * length-in-digits of an encoded integer.
       */
      private fun writeOrCountBytes(
        sink: BufferedSink?,
        countBytes: Boolean,
      ): Long {
        var byteCount = 0L
        val buffer: Buffer = if (countBytes) Buffer() else sink!!.buffer
    
        for (i in 0 until encodedNames.size) {
          if (i > 0) buffer.writeByte('&'.code)
          buffer.writeUtf8(encodedNames[i])
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Tue Jan 09 12:33:05 GMT 2024
    - 4.3K bytes
    - Viewed (0)
  7. okhttp/src/test/java/okhttp3/URLConnectionTest.kt

        assertThat(zeroLengthPayload.method).isEqualTo(method)
        assertThat(zeroLengthPayload.headers["content-length"]).isEqualTo("0")
        assertThat(zeroLengthPayload.bodySize).isEqualTo(0L)
      }
    
      @Test
      fun setProtocols() {
        server.enqueue(
          MockResponse(body = "A"),
        )
        client =
          client.newBuilder()
            .protocols(Arrays.asList(Protocol.HTTP_1_1))
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 131.7K bytes
    - Viewed (0)
  8. okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/DerHeader.kt

        const val TAG_CLASS_APPLICATION = 0b0100_0000
        const val TAG_CLASS_CONTEXT_SPECIFIC = 0b1000_0000
        const val TAG_CLASS_PRIVATE = 0b1100_0000
    
        const val TAG_END_OF_CONTENTS = 0L
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.3K bytes
    - Viewed (0)
  9. samples/guide/src/main/java/okhttp3/recipes/Progress.java

          }
          return bufferedSource;
        }
    
        private Source source(Source source) {
          return new ForwardingSource(source) {
            long totalBytesRead = 0L;
    
            @Override public long read(Buffer sink, long byteCount) throws IOException {
              long bytesRead = super.read(sink, byteCount);
    Java
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 12 03:31:36 GMT 2019
    - 3.9K bytes
    - Viewed (0)
  10. native-image-tests/src/main/kotlin/okhttp3/RunTests.kt

        launcher.execute(request)
      } finally {
        DotListener.uninstall()
      }
    
      val summary = summaryListener.summary
      summary.printTo(PrintWriter(System.out))
    
      exitProcess(if (summary.testsFailedCount != 0L) -1 else 0)
    }
    
    /**
     * Builds the Junit Test Engine for the native image.
     */
    fun buildTestEngine(): TestEngine = JupiterTestEngine()
    
    /**
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 5.3K bytes
    - Viewed (0)
Back to top