Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 44 for flush (0.17 sec)

  1. okhttp/src/test/java/okhttp3/ServerTruncatesRequestTest.kt

        override fun contentType(): MediaType? = null
    
        override fun writeTo(sink: BufferedSink) {
          for (i in 0 until 50) {
            sink.writeUtf8("abc")
            sink.flush()
            Thread.sleep(100)
          }
          fail("")
        }
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 9.5K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/DuplexTest.kt

          requestBody.flush()
          val responseBody = response.body.source()
          assertThat(responseBody.readUtf8Line())
            .isEqualTo("response B")
          requestBody.writeUtf8("request C\n")
          requestBody.flush()
          assertThat(responseBody.readUtf8Line())
            .isEqualTo("response D")
          requestBody.writeUtf8("request E\n")
          requestBody.flush()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 23.9K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/URLConnectionTest.kt

        testFlushAfterStreamTransmitted(TransferKind.END_OF_STREAM)
      }
    
      /**
       * We explicitly permit apps to close the upload stream even after it has been transmitted.  We
       * also permit flush so that buffered streams can do a no-op flush when they are closed.
       * http://b/3038470
       */
      private fun testFlushAfterStreamTransmitted(transferKind: TransferKind) {
        server.enqueue(
          MockResponse(body = "abc"),
        )
    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)
  4. okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Stream.kt

          }
        }
    
        @Throws(IOException::class)
        override fun flush() {
          lock.assertNotHeld()
    
          ******@****.***ck {
            checkOutNotClosed()
          }
          // TODO(jwilson): flush the connection?!
          while (sendBuffer.size > 0L) {
            emitFrame(false)
            connection.flush()
          }
        }
    
        override fun timeout(): Timeout = writeTimeout
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 23.2K bytes
    - Viewed (1)
  5. okhttp/src/main/kotlin/okhttp3/internal/cache/DiskLruCache.kt

          cleanupQueue.schedule(cleanupTask)
          return null
        }
    
        // Flush the journal before creating files to prevent file leaks.
        val journalWriter = this.journalWriter!!
        journalWriter.writeUtf8(DIRTY)
          .writeByte(' '.code)
          .writeUtf8(key)
          .writeByte('\n'.code)
        journalWriter.flush()
    
        if (hasJournalErrors) {
          return null // Don't edit; the journal can't be written.
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 34.7K bytes
    - Viewed (0)
  6. okhttp-testing-support/src/main/kotlin/okhttp3/JsseDebugLogging.kt

            override fun publish(record: LogRecord) {
              val param = record.parameters?.firstOrNull() as? String
              debugHandler(JsseDebugMessage(record.message, param))
            }
    
            override fun flush() {
            }
    
            override fun close() {
            }
          },
        )
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.8K bytes
    - Viewed (0)
  7. okhttp/src/test/java/okhttp3/internal/http/ThreadInterruptTest.kt

                  override fun contentType() = null
    
                  override fun writeTo(sink: BufferedSink) {
                    for (i in 0..9) {
                      sink.writeByte(0)
                      sink.flush()
                      sleep(100)
                    }
                    fail("Expected connection to be closed")
                  }
                },
              )
              .build(),
          )
        interruptLater(500)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 4.6K bytes
    - Viewed (0)
  8. mockwebserver/src/main/kotlin/mockwebserver3/MockWebServer.kt

      ) {
        for ((name, value) in headers) {
          sink.writeUtf8(name)
          sink.writeUtf8(": ")
          sink.writeUtf8(value)
          sink.writeUtf8("\r\n")
        }
        sink.writeUtf8("\r\n")
        sink.flush()
      }
    
      /** Returns a sink that applies throttling and disconnecting. */
      private fun Sink.withThrottlingAndSocketPolicy(
        policy: MockResponse,
        disconnectHalfway: Boolean,
        expectedByteCount: Long,
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Mar 31 17:16:15 GMT 2024
    - 37.4K bytes
    - Viewed (0)
  9. samples/guide/src/main/java/okhttp3/recipes/kt/WiresharkExample.kt

                if (message == "Produced ClientHello handshake message") {
                  random = readClientRandom(parameter)
                }
              }
            }
    
            override fun flush() {}
    
            override fun close() {}
          }
    
        private fun readClientRandom(param: String): String? {
          val matchResult = randomRegex.find(param)
    
          return if (matchResult != null) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 10.7K bytes
    - Viewed (1)
  10. okhttp/api/okhttp.api

    	public fun close ()V
    	public final fun delete ()V
    	public final fun directory ()Ljava/io/File;
    	public final fun directoryPath ()Lokio/Path;
    	public final fun evictAll ()V
    	public fun flush ()V
    	public final fun hitCount ()I
    	public final fun initialize ()V
    	public final fun isClosed ()Z
    	public static final fun key (Lokhttp3/HttpUrl;)Ljava/lang/String;
    	public final fun maxSize ()J
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 15 13:41:01 GMT 2024
    - 70.2K bytes
    - Viewed (0)
Back to top