Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for NewReaderSize (0.08 sec)

  1. src/bufio/bufio_test.go

    	const BufSize = 1000
    	b := NewReaderSize(strings.NewReader("hello world"), BufSize)
    	// Does it recognize itself?
    	b1 := NewReaderSize(b, BufSize)
    	if b1 != b {
    		t.Error("NewReaderSize did not detect underlying Reader")
    	}
    	// Does it wrap if existing buffer is too small?
    	b2 := NewReaderSize(b, 2*BufSize)
    	if b2 == b {
    		t.Error("NewReaderSize did not enlarge buffer")
    	}
    }
    
    Registered: Tue Nov 05 11:13:11 UTC 2024
    - Last Modified: Fri Nov 01 21:52:12 UTC 2024
    - 51.6K bytes
    - Viewed (0)
  2. internal/s3select/json/preader.go

    // Should only be used for LINES types.
    func NewPReader(readCloser io.ReadCloser, args *ReaderArgs) *PReader {
    	r := &PReader{
    		args:       args,
    		buf:        bufio.NewReaderSize(readCloser, jsonSplitSize*2),
    		readCloser: readCloser,
    		close:      make(chan struct{}),
    	}
    	r.startReaders()
    	return r
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Sep 23 19:35:41 UTC 2024
    - 6.5K bytes
    - Viewed (0)
  3. cmd/storage-rest-client.go

    // The reader will be buffered.
    // Return with readMsgpReaderPoolPut when done.
    func msgpNewReader(r io.Reader) *msgp.Reader {
    	p := readMsgpReaderPool.Get().(*msgp.Reader)
    	if p.R == nil {
    		p.R = xbufio.NewReaderSize(r, 32<<10)
    	} else {
    		p.R.Reset(r)
    	}
    	return p
    }
    
    // readMsgpReaderPoolPut can be used to reuse a *msgp.Reader.
    func readMsgpReaderPoolPut(r *msgp.Reader) {
    	if r != nil {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Oct 13 13:07:21 UTC 2024
    - 30.2K bytes
    - Viewed (0)
  4. cmd/object-multipart-handlers.go

    			in := io.Reader(hashReader)
    			if size > encryptBufferThreshold {
    				// The encryption reads in blocks of 64KB.
    				// We add a buffer on bigger files to reduce the number of syscalls upstream.
    				in = bufio.NewReaderSize(hashReader, encryptBufferSize)
    			}
    
    			var nonce [12]byte
    			tmp := sha256.Sum256([]byte(fmt.Sprint(uploadID, partID)))
    			copy(nonce[:], tmp[:12])
    
    			reader, err = sio.EncryptReader(in, sio.Config{
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sat Aug 31 18:25:48 UTC 2024
    - 39.2K bytes
    - Viewed (0)
  5. cmd/encryption-v1.go

    	if r.ContentLength > encryptBufferThreshold {
    		// The encryption reads in blocks of 64KB.
    		// We add a buffer on bigger files to reduce the number of syscalls upstream.
    		content = bufio.NewReaderSize(content, encryptBufferSize)
    	}
    
    	var (
    		key   []byte
    		keyID string
    		ctx   kms.Context
    		err   error
    	)
    	kind, _ := crypto.IsRequested(r.Header)
    	if kind == crypto.SSEC {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Oct 13 13:06:08 UTC 2024
    - 37.2K bytes
    - Viewed (0)
Back to top