Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 245 for buffer (0.04 sec)

  1. src/bytes/buffer.go

    // The slice aliases the buffer content at least until the next buffer modification,
    // so immediate changes to the slice will affect the result of future reads.
    func (b *Buffer) Bytes() []byte { return b.buf[b.off:] }
    
    // AvailableBuffer returns an empty buffer with b.Available() capacity.
    // This buffer is intended to be appended to and
    Registered: Tue Nov 05 11:13:11 UTC 2024
    - Last Modified: Tue Oct 29 16:47:05 UTC 2024
    - 15.7K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/MultipartBodyTest.kt

        assertThat(body.isOneShot()).isEqualTo(false)
    
        val buffer = Buffer()
        body.writeTo(buffer)
        assertThat(body.contentLength()).isEqualTo(buffer.size)
        assertThat(buffer.readUtf8()).isEqualTo(expected)
    
        val buffer2 = Buffer()
        body.writeTo(buffer2)
        assertThat(body.contentLength()).isEqualTo(buffer2.size)
        assertThat(buffer2.readUtf8()).isEqualTo(expected)
      }
    
      @Test
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 10.4K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/internal/cache2/Relay.kt

            )
    
            synchronized(this@Relay) {
              // Append new upstream bytes into the buffer. Trim it to its max size.
              buffer.write(upstreamBuffer, upstreamBytesRead)
              if (buffer.size > bufferMaxSize) {
                buffer.skip(buffer.size - bufferMaxSize)
              }
    
              // Now that the file and buffer have bytes, adjust upstreamPos.
              ******@****.***amPos += upstreamBytesRead
            }
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 11.8K bytes
    - Viewed (0)
  4. src/main/java/jcifs/internal/smb2/ServerMessageBlock2.java

    
        protected int readHeaderWireFormat ( byte[] buffer, int bufferIndex ) {
            // these are common between SYNC/ASYNC
            SMBUtil.readInt4(buffer, bufferIndex);
            bufferIndex += 4;
            SMBUtil.readInt2(buffer, bufferIndex);
            this.creditCharge = SMBUtil.readInt2(buffer, bufferIndex + 2);
            bufferIndex += 4;
            this.status = SMBUtil.readInt4(buffer, bufferIndex);
            bufferIndex += 4;
    Registered: Sun Nov 03 00:10:13 UTC 2024
    - Last Modified: Sun Sep 30 10:47:31 UTC 2018
    - 19.9K bytes
    - Viewed (0)
  5. src/bufio/bufio.go

    	b.n = 0
    	return nil
    }
    
    // Available returns how many bytes are unused in the buffer.
    func (b *Writer) Available() int { return len(b.buf) - b.n }
    
    // AvailableBuffer returns an empty buffer with b.Available() capacity.
    // This buffer is intended to be appended to and
    // passed to an immediately succeeding [Writer.Write] call.
    // The buffer is only valid until the next write operation on b.
    func (b *Writer) AvailableBuffer() []byte {
    Registered: Tue Nov 05 11:13:11 UTC 2024
    - Last Modified: Thu Oct 12 14:39:08 UTC 2023
    - 21.8K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/internal/http/CancelTest.kt

            .body(
              Buffer()
                .write(ByteArray(responseBodySize)),
            )
            .throttleBody(64 * 1024, 125, MILLISECONDS) // 500 Kbps
            .build(),
        )
        val call = client.newCall(Request(server.url("/")))
        val response = call.execute()
        cancelLater(call, 500)
        val responseBody = response.body.byteStream()
        val buffer = ByteArray(1024)
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Jan 20 10:30:28 UTC 2024
    - 9.9K bytes
    - Viewed (0)
  7. internal/ringbuffer/ring_buffer.go

    	ErrTooMuchDataToWrite = errors.New("too much data to write")
    
    	// ErrIsFull is returned when the buffer is full and not blocking.
    	ErrIsFull = errors.New("ringbuffer is full")
    
    	// ErrIsEmpty is returned when the buffer is empty and not blocking.
    	ErrIsEmpty = errors.New("ringbuffer is empty")
    
    	// ErrIsNotEmpty is returned when the buffer is not empty and not blocking.
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed May 15 00:11:04 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/internal/http2/Http2Test.kt

            for (b in data.toByteArray()) {
              assertThat(b).isEqualTo(2.toByte())
            }
          }
        }
      }
    
      private fun gzip(data: ByteArray): Buffer {
        val buffer = Buffer()
        GzipSink(buffer).buffer().write(data).close()
        return buffer
      }
    
      /** Create a sufficiently large header set to overflow INITIAL_MAX_FRAME_SIZE bytes.  */
      private fun largeHeaders(): List<Header> {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 28.1K bytes
    - Viewed (0)
  9. src/main/java/jcifs/internal/smb1/AndXServerMessageBlock.java

         */
    
        @Override
        public int decode ( byte[] buffer, int bufferIndex ) throws SMBProtocolDecodingException {
            int start = this.headerStart = bufferIndex;
    
            bufferIndex += readHeaderWireFormat(buffer, bufferIndex);
            bufferIndex += readAndXWireFormat(buffer, bufferIndex);
    
            int len = bufferIndex - start;
            this.length = len;
    
    Registered: Sun Nov 03 00:10:13 UTC 2024
    - Last Modified: Mon Nov 28 10:56:27 UTC 2022
    - 14.3K bytes
    - Viewed (0)
  10. src/main/java/jcifs/internal/smb1/com/SmbComNegotiateResponse.java

            this.server.smaxMpxCount = SMBUtil.readInt2(buffer, bufferIndex);
            bufferIndex += 2;
            this.server.maxNumberVcs = SMBUtil.readInt2(buffer, bufferIndex);
            bufferIndex += 2;
            this.server.maxBufferSize = SMBUtil.readInt4(buffer, bufferIndex);
            bufferIndex += 4;
            this.server.maxRawSize = SMBUtil.readInt4(buffer, bufferIndex);
            bufferIndex += 4;
    Registered: Sun Nov 03 00:10:13 UTC 2024
    - Last Modified: Tue Jul 07 10:52:42 UTC 2020
    - 15.4K bytes
    - Viewed (0)
Back to top