Search Options

Results per page
Sort
Preferred Languages
Advance

Results 91 - 100 of 1,081 for readArg (0.14 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/cache2/Relay.kt

         *
         * ## Upstream
         *
         * In this case the current thread is assigned as the upstream reader. We read bytes from
         * upstream and copy them to both the file and to the buffer. Finally we release the upstream
         * reader lock and return the new bytes.
         *
         * ## The file
         *
         * In this case we copy bytes from the file to the [sink].
         *
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 11.8K bytes
    - Viewed (0)
  2. cmd/erasure-healing.go

    	var found int
    	var notFound int
    	var foundNotEmpty int
    	var otherFound int
    	for _, readErr := range errs {
    		switch {
    		case readErr == nil:
    			found++
    		case readErr == errFileNotFound || readErr == errVolumeNotFound:
    			notFound++
    		case readErr == errVolumeNotEmpty:
    			foundNotEmpty++
    		default:
    			otherFound++
    		}
    	}
    	found = found + foundNotEmpty + otherFound
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Mon Jun 10 15:51:27 UTC 2024
    - 33.8K bytes
    - Viewed (0)
  3. src/net/textproto/reader_test.go

    package textproto
    
    import (
    	"bufio"
    	"bytes"
    	"io"
    	"net"
    	"reflect"
    	"runtime"
    	"strings"
    	"sync"
    	"testing"
    )
    
    func reader(s string) *Reader {
    	return NewReader(bufio.NewReader(strings.NewReader(s)))
    }
    
    func TestReadLine(t *testing.T) {
    	r := reader("line1\nline2\n")
    	s, err := r.ReadLine()
    	if s != "line1" || err != nil {
    		t.Fatalf("Line 1: %s, %v", s, err)
    	}
    	s, err = r.ReadLine()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Mar 05 18:31:56 UTC 2024
    - 14.7K bytes
    - Viewed (0)
  4. staging/src/k8s.io/apimachinery/pkg/util/proxy/upgradeaware.go

    }
    
    // getResponseCode reads a http response from the given reader, returns the response,
    // the bytes read from the reader, and any error encountered
    func getResponse(r io.Reader) (*http.Response, []byte, error) {
    	rawResponse := bytes.NewBuffer(make([]byte, 0, 256))
    	// Save the bytes read while reading the response headers into the rawResponse buffer
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Mar 04 19:10:30 UTC 2024
    - 19.6K bytes
    - Viewed (0)
  5. src/bufio/bufio.go

    // NewReaderSize returns a new [Reader] whose buffer has at least the specified
    // size. If the argument io.Reader is already a [Reader] with large enough
    // size, it returns the underlying [Reader].
    func NewReaderSize(rd io.Reader, size int) *Reader {
    	// Is it already a Reader?
    	b, ok := rd.(*Reader)
    	if ok && len(b.buf) >= size {
    		return b
    	}
    	r := new(Reader)
    	r.reset(make([]byte, max(size, minReadBufferSize)), rd)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 12 14:39:08 UTC 2023
    - 21.8K bytes
    - Viewed (0)
  6. pkg/file/file.go

    // limitations under the License.
    
    package file
    
    import (
    	"bytes"
    	"errors"
    	"fmt"
    	"io"
    	"io/fs"
    	"os"
    	"path/filepath"
    )
    
    // AtomicCopy copies file by reading the file then writing atomically into the target directory
    func AtomicCopy(srcFilepath, targetDir, targetFilename string) error {
    	in, err := os.Open(srcFilepath)
    	if err != nil {
    		return err
    	}
    	defer in.Close()
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Apr 11 21:42:29 UTC 2024
    - 3K bytes
    - Viewed (0)
  7. src/go/parser/interface.go

    // otherwise it returns an error. If src == nil, readSource returns
    // the result of reading the file specified by filename.
    func readSource(filename string, src any) ([]byte, error) {
    	if src != nil {
    		switch s := src.(type) {
    		case string:
    			return []byte(s), nil
    		case []byte:
    			return s, nil
    		case *bytes.Buffer:
    			// is io.Reader, but src is already available in []byte form
    			if s != nil {
    				return s.Bytes(), nil
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 12:02:03 UTC 2023
    - 7.5K bytes
    - Viewed (0)
  8. pkg/config/analysis/local/istiod_analyze.go

    	ResourceName string
    }
    
    // ReaderSource is a tuple of a io.Reader and filepath.
    type ReaderSource struct {
    	// Name is the name of the source (commonly the path to a file, but can be "-" for sources read from stdin or "" if completely synthetic).
    	Name string
    	// Reader is the reader instance to use.
    	Reader io.Reader
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Apr 02 21:06:13 UTC 2024
    - 21.6K bytes
    - Viewed (0)
  9. src/internal/trace/generation.go

    			if err != nil {
    				return fmt.Errorf("reading frame %d's PC for stack %d: %w", i+1, id, err)
    			}
    			funcID, err := binary.ReadUvarint(r)
    			if err != nil {
    				return fmt.Errorf("reading frame %d's funcID for stack %d: %w", i+1, id, err)
    			}
    			fileID, err := binary.ReadUvarint(r)
    			if err != nil {
    				return fmt.Errorf("reading frame %d's fileID for stack %d: %w", i+1, id, err)
    			}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 22:14:45 UTC 2024
    - 12.1K bytes
    - Viewed (0)
  10. src/internal/zstd/fse.go

    	}
    
    	return nil
    }
    
    // fseBaselineEntry is an entry in an FSE baseline table.
    // We use these for literal/match/length values.
    // Those require mapping the symbol to a baseline value,
    // and then reading zero or more bits and adding the value to the baseline.
    // Rather than looking these up in separate tables,
    // we convert the FSE table to an FSE baseline table.
    type fseBaselineEntry struct {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Nov 17 16:44:06 UTC 2023
    - 12.2K bytes
    - Viewed (0)
Back to top