Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 146 for sina (0.07 sec)

  1. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/connection/BufferedSocket.kt

      override val source: BufferedSource
      override val sink: BufferedSink
    }
    
    fun JavaNetSocket.asBufferedSocket(): BufferedSocket = asOkioSocket().asBufferedSocket()
    
    fun OkioSocket.asBufferedSocket(): BufferedSocket =
      object : BufferedSocket {
        private val delegate = this@asBufferedSocket
        override val source = delegate.source.buffer()
        override val sink = delegate.sink.buffer()
    
        override fun cancel() {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Thu Jul 31 04:18:40 UTC 2025
    - 1.3K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/io/ByteSink.java

      /**
       * Writes all the given bytes to this sink.
       *
       * @throws IOException if an I/O occurs while writing to this sink
       */
      public void write(byte[] bytes) throws IOException {
        checkNotNull(bytes);
    
        try (OutputStream out = openStream()) {
          out.write(bytes);
        }
      }
    
      /**
       * Writes all the bytes from the given {@code InputStream} to this sink. Does not close {@code
       * input}.
       *
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Sat Dec 21 03:10:51 UTC 2024
    - 4.9K bytes
    - Viewed (0)
  3. guava/src/com/google/common/io/ByteSink.java

      /**
       * Writes all the given bytes to this sink.
       *
       * @throws IOException if an I/O occurs while writing to this sink
       */
      public void write(byte[] bytes) throws IOException {
        checkNotNull(bytes);
    
        try (OutputStream out = openStream()) {
          out.write(bytes);
        }
      }
    
      /**
       * Writes all the bytes from the given {@code InputStream} to this sink. Does not close {@code
       * input}.
       *
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Sat Dec 21 03:10:51 UTC 2024
    - 4.9K bytes
    - Viewed (0)
  4. okhttp/src/jvmTest/kotlin/okhttp3/internal/cache2/FileOperatorTest.kt

        randomAccessFile!!.getChannel().force(false)
        val source = file!!.source().buffer()
        return source.readByteString()
      }
    
      private fun write(data: ByteString) {
        val sink = file!!.sink().buffer()
        sink.write(data)
        sink.close()
      }
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Dec 27 13:39:56 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  5. okhttp/src/jvmTest/kotlin/okhttp3/internal/publicsuffix/PublicSuffixListGenerator.kt

      }
    
      private suspend fun updateLocalFile() =
        withContext(Dispatchers.IO) {
          client.newCall(request).executeAsync().use { response ->
            fileSystem.sink(publicSuffixListDotDat).buffer().use { sink ->
              sink.writeAll(response.body.source())
            }
          }
        }
    
      private suspend fun readImportResults(): ImportResults =
        withContext(Dispatchers.IO) {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Aug 06 05:33:11 UTC 2025
    - 6.1K bytes
    - Viewed (0)
  6. docs/recipes.md

              }
    
              @Override public void writeTo(BufferedSink sink) throws IOException {
                BufferedSink bufferedSink = Okio.buffer(sink(sink));
                delegate.writeTo(bufferedSink);
                bufferedSink.flush();
              }
    
              public Sink sink(Sink sink) {
                return new ForwardingSink(sink) {
                  private long totalBytesWritten = 0L;
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Aug 30 17:01:12 UTC 2025
    - 47.8K bytes
    - Viewed (0)
  7. okhttp/src/jvmTest/kotlin/okhttp3/ServerTruncatesRequestTest.kt

      private object SlowRequestBody : RequestBody() {
        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("")
        }
      }
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Jun 20 11:46:46 UTC 2025
    - 9.4K bytes
    - Viewed (0)
  8. okhttp/src/jvmTest/kotlin/okhttp3/internal/io/FaultyFileSystem.kt

        file: Path,
        mustExist: Boolean,
      ): Sink = FaultySink(super.appendingSink(file, mustExist), file)
    
      override fun sink(
        file: Path,
        mustCreate: Boolean,
      ): Sink = FaultySink(super.sink(file, mustCreate), file)
    
      inner class FaultySink(
        sink: Sink,
        private val file: Path,
      ) : ForwardingSink(sink) {
        override fun write(
          source: Buffer,
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 2.8K bytes
    - Viewed (0)
  9. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/connection/Exchange.kt

        eventListener.requestBodyStart(call)
    
        return object : Socket {
          override fun cancel() {
            ******@****.***()
          }
    
          override val sink = RequestBodySink(codec.socket.sink, -1L)
          override val source = ResponseBodySource(codec.socket.source, -1L)
        }
      }
    
      fun noNewExchangesOnConnection() {
        codec.carrier.noNewExchanges()
      }
    
      fun cancel() {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Tue Jul 29 22:04:11 UTC 2025
    - 9.7K bytes
    - Viewed (0)
  10. mockwebserver/src/main/kotlin/mockwebserver3/internal/TriggerSink.kt

     *
     */
    package mockwebserver3.internal
    
    import okio.Buffer
    import okio.Sink
    
    /**
     * A sink that executes [trigger] after [triggerByteCount] bytes are written, and then skips all
     * subsequent bytes.
     */
    internal class TriggerSink(
      private val delegate: Sink,
      private val triggerByteCount: Long,
      private val trigger: () -> Unit,
    ) : Sink by delegate {
      private var bytesWritten = 0L
    
      override fun write(
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 1.4K bytes
    - Viewed (0)
Back to top