- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 122 for readVal (0.24 sec)
-
src/math/rand/rand.go
switch src := r.src.(type) { case *lockedSource: return src.read(p, &r.readVal, &r.readPos) case *runtimeSource: return src.read(p, &r.readVal, &r.readPos) } return read(p, r.src, &r.readVal, &r.readPos) } func read(p []byte, src Source, readVal *int64, readPos *int8) (n int, err error) { pos := *readPos val := *readVal rng, _ := src.(*rngSource) for n = 0; n < len(p); n++ { if pos == 0 {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 22 22:09:08 UTC 2024 - 16.9K bytes - Viewed (0) -
src/internal/trace/internal/oldtrace/parser.go
if _, err := p.readVal(); err != nil { return errMalformedVarint } ln, err := p.readVal() if err != nil { return err } if !p.discard(ln) { return fmt.Errorf("failed to read trace: %w", io.EOF) } } else { // String dictionary entry [ID, length, string]. id, err := p.readVal() if err != nil { return err }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 24 21:15:28 UTC 2024 - 46.8K bytes - Viewed (0) -
cmd/storage-rest-common.go
storageRESTMethodCreateFile = "/createfile" storageRESTMethodWriteAll = "/writeall" storageRESTMethodReadVersion = "/readversion" storageRESTMethodReadXL = "/readxl" storageRESTMethodReadAll = "/readall" storageRESTMethodReadFile = "/readfile" storageRESTMethodReadFileStream = "/readfilestream" storageRESTMethodListDir = "/listdir" storageRESTMethodDeleteVersions = "/deleteverions"
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Mon Jun 10 15:51:27 UTC 2024 - 2.9K bytes - Viewed (0) -
src/io/io.go
// ReadAt blocks until either all the data is available or an error occurs. // In this respect ReadAt is different from Read. // // If the n = len(p) bytes returned by ReadAt are at the end of the // input source, ReadAt may return either err == EOF or err == nil. // // If ReadAt is reading from an input source with a seek offset, // ReadAt should not affect nor be affected by the underlying
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Apr 15 17:34:10 UTC 2024 - 21.6K bytes - Viewed (0) -
cmd/naughty-disk_test.go
return err } return d.disk.WriteAll(ctx, volume, path, b) } func (d *naughtyDisk) ReadAll(ctx context.Context, volume string, path string) (buf []byte, err error) { if err := d.calcError(); err != nil { return nil, err } return d.disk.ReadAll(ctx, volume, path) } func (d *naughtyDisk) ReadXL(ctx context.Context, volume string, path string, readData bool) (rf RawFileInfo, err error) {
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Mon Jun 10 15:51:27 UTC 2024 - 9.4K bytes - Viewed (0) -
cmd/storage-interface.go
// Write all data, syncs the data to disk. // Should be used for smaller payloads. WriteAll(ctx context.Context, volume string, path string, b []byte) (err error) // Read all. ReadAll(ctx context.Context, volume string, path string) (buf []byte, err error) GetDiskLoc() (poolIdx, setIdx, diskIdx int) // Retrieve location indexes.
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Mon Jun 10 15:51:27 UTC 2024 - 5K bytes - Viewed (0) -
src/testing/fstest/testfs.go
// Read entire file. f, err := t.fsys.Open(file) if err != nil { t.errorf("%s: Open: %w", file, err) return } data, err := io.ReadAll(f) if err != nil { f.Close() t.errorf("%s: Open+ReadAll: %w", file, err) return } if err := f.Close(); err != nil { t.errorf("%s: Close: %w", file, err) } // Check that closing twice doesn't crash.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 16.3K bytes - Viewed (0) -
src/io/ioutil/ioutil.go
"io/fs" "os" "slices" "strings" ) // ReadAll reads from r until an error or EOF and returns the data it read. // A successful call returns err == nil, not err == EOF. Because ReadAll is // defined to read from src until EOF, it does not treat an EOF from Read // as an error to be reported. // // Deprecated: As of Go 1.16, this function simply calls [io.ReadAll]. func ReadAll(r io.Reader) ([]byte, error) { return io.ReadAll(r) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 3.2K bytes - Viewed (0) -
cmd/xl-storage.go
buf = make([]byte, sz) } // Read file... _, err = io.ReadFull(f, buf) return buf, stat.ModTime().UTC(), osErrToFileErr(err) } // ReadAll is a raw call, reads content at any path and returns the buffer. func (s *xlStorage) ReadAll(ctx context.Context, volume string, path string) (buf []byte, err error) { // Specific optimization to avoid re-read from the drives for `format.json`
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Mon Jun 10 15:51:27 UTC 2024 - 85.3K bytes - Viewed (0) -
src/net/http/clientserver_test.go
if err != nil { t.Fatal(err) } firstRead = firstRead[:n] close(cancel) rest, err := io.ReadAll(res.Body) all := string(firstRead) + string(rest) if all != "Hello" { t.Errorf("Read %q (%q + %q); want Hello", all, firstRead, rest) } if err != ExportErrRequestCanceled { t.Errorf("ReadAll error = %v; want %v", err, ExportErrRequestCanceled) } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 46.6K bytes - Viewed (0)