Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 1,089 for sink (0.58 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/connection/RealConnection.kt

          Http1ExchangeCodec(client, this, source, sink)
        }
      }
    
      @Throws(SocketException::class)
      internal fun newWebSocketStreams(exchange: Exchange): RealWebSocket.Streams {
        val socket = this.socket!!
        val source = this.source!!
        val sink = this.sink!!
    
        socket.soTimeout = 0
        noNewExchanges()
        return object : RealWebSocket.Streams(true, source, sink) {
          override fun close() {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 15.4K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/io/ByteSourceTest.java

        TestByteSink sink = new TestByteSink();
    
        assertFalse(sink.wasStreamOpened() || sink.wasStreamClosed());
    
        assertEquals(bytes.length, source.copyTo(sink));
        assertTrue(source.wasStreamOpened() && source.wasStreamClosed());
        assertTrue(sink.wasStreamOpened() && sink.wasStreamClosed());
    
        assertArrayEquals(bytes, sink.getBytes());
      }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 16.9K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/io/CharSourceTest.java

        TestCharSink sink = new TestCharSink();
    
        assertFalse(sink.wasStreamOpened() || sink.wasStreamClosed());
    
        assertEquals(STRING.length(), source.copyTo(sink));
        assertTrue(source.wasStreamOpened() && source.wasStreamClosed());
        assertTrue(sink.wasStreamOpened() && sink.wasStreamClosed());
    
        assertEquals(STRING, sink.getString());
      }
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 13K bytes
    - Viewed (0)
  4. okhttp/src/main/kotlin/okhttp3/internal/http1/Http1ExchangeCodec.kt

       */
      private inner class ChunkedSink : Sink {
        private val timeout = ForwardingTimeout(sink.timeout())
        private var closed: Boolean = false
    
        override fun timeout(): Timeout = timeout
    
        override fun write(
          source: Buffer,
          byteCount: Long,
        ) {
          check(!closed) { "closed" }
          if (byteCount == 0L) return
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 16.2K bytes
    - Viewed (0)
  5. okhttp/src/main/kotlin/okhttp3/MultipartBody.kt

            byteCount += contentLength
          } else {
            body.writeTo(sink)
          }
    
          sink.write(CRLF)
        }
    
        sink!!.write(DASHDASH)
        sink.write(boundaryByteString)
        sink.write(DASHDASH)
        sink.write(CRLF)
    
        if (countBytes) {
          byteCount += byteCountBuffer!!.size
          byteCountBuffer.clear()
        }
    
        return byteCount
      }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 10.9K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/hash/HashTestUtils.java

            long value = random.nextLong();
            for (PrimitiveSink sink : sinks) {
              sink.putLong(value);
            }
          }
        },
        PUT_FLOAT() {
          @Override
          void performAction(Random random, Iterable<? extends PrimitiveSink> sinks) {
            float value = random.nextFloat();
            for (PrimitiveSink sink : sinks) {
              sink.putFloat(value);
            }
          }
        },
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Oct 10 19:45:10 GMT 2022
    - 25.3K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/Cache.kt

        fun writeTo(editor: DiskLruCache.Editor) {
          editor.newSink(ENTRY_METADATA).buffer().use { sink ->
            sink.writeUtf8(url.toString()).writeByte('\n'.code)
            sink.writeUtf8(requestMethod).writeByte('\n'.code)
            sink.writeDecimalLong(varyHeaders.size.toLong()).writeByte('\n'.code)
            for (i in 0 until varyHeaders.size) {
              sink.writeUtf8(varyHeaders.name(i))
                .writeUtf8(": ")
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 26.8K bytes
    - Viewed (0)
  8. okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Writer.kt

        require(streamId and 0x80000000.toInt() == 0) { "reserved bit set: $streamId" }
        sink.writeMedium(length)
        sink.writeByte(type and 0xff)
        sink.writeByte(flags and 0xff)
        sink.writeInt(streamId and 0x7fffffff)
      }
    
      @Throws(IOException::class)
      override fun close() {
        this.withLock {
          closed = true
          sink.close()
        }
      }
    
      @Throws(IOException::class)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 11.3K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/io/ByteSourceTest.java

        TestByteSink sink = new TestByteSink();
    
        assertFalse(sink.wasStreamOpened() || sink.wasStreamClosed());
    
        assertEquals(bytes.length, source.copyTo(sink));
        assertTrue(source.wasStreamOpened() && source.wasStreamClosed());
        assertTrue(sink.wasStreamOpened() && sink.wasStreamClosed());
    
        assertArrayEquals(bytes, sink.getBytes());
      }
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 16.9K bytes
    - Viewed (0)
  10. okhttp/src/main/kotlin/okhttp3/internal/connection/ConnectPlan.kt

          val source = this.source!!
          val sink = this.sink!!
          val tunnelCodec =
            Http1ExchangeCodec(
              // No client for CONNECT tunnels:
              client = null,
              carrier = this,
              source = source,
              sink = sink,
            )
          source.timeout().timeout(readTimeoutMillis.toLong(), TimeUnit.MILLISECONDS)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 18.6K bytes
    - Viewed (0)
Back to top