Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 1,982 for whence (0.21 sec)

  1. src/bytes/reader.go

    // Seek implements the [io.Seeker] interface.
    func (r *Reader) Seek(offset int64, whence int) (int64, error) {
    	r.prevRune = -1
    	var abs int64
    	switch whence {
    	case io.SeekStart:
    		abs = offset
    	case io.SeekCurrent:
    		abs = r.i + offset
    	case io.SeekEnd:
    		abs = int64(len(r.s)) + offset
    	default:
    		return 0, errors.New("bytes.Reader.Seek: invalid whence")
    	}
    	if abs < 0 {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Oct 13 17:10:31 GMT 2023
    - 3.9K bytes
    - Viewed (0)
  2. src/archive/tar/tar_test.go

    	return len(b), nil
    }
    
    func (f *testFile) Seek(pos int64, whence int) (int64, error) {
    	if pos == 0 && whence == io.SeekCurrent {
    		return f.pos, nil
    	}
    	if len(f.ops) == 0 {
    		return 0, errors.New("unexpected Seek operation")
    	}
    	s, ok := f.ops[0].(int64)
    	if !ok {
    		return 0, errors.New("unexpected Seek operation")
    	}
    
    	if s != pos || whence != io.SeekCurrent {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Mar 15 16:01:50 GMT 2024
    - 24K bytes
    - Viewed (0)
  3. internal/s3select/select.go

    		offset:        0,
    		reader:        nil,
    	}
    }
    
    // Seek call to implement io.Seeker
    func (rsc *ObjectReadSeekCloser) Seek(offset int64, whence int) (int64, error) {
    	// fmt.Printf("actual: %v offset: %v (%v) whence: %v\n", rsc.size, offset, rsc.offset, whence)
    	switch whence {
    	case io.SeekStart:
    		rsc.offset = offset
    	case io.SeekCurrent:
    		rsc.offset += offset
    	case io.SeekEnd:
    		rsc.offset = rsc.size + offset
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Nov 06 22:26:08 GMT 2023
    - 21K bytes
    - Viewed (0)
  4. cmd/dummy-data-generator_test.go

    	if d.idx >= d.length {
    		extraBytes := d.idx - d.length
    		n -= int(extraBytes)
    		if n < 0 {
    			n = 0
    		}
    		err = io.EOF
    	}
    	return
    }
    
    func (d *DummyDataGen) Seek(offset int64, whence int) (int64, error) {
    	switch whence {
    	case io.SeekStart:
    		if offset < 0 {
    			return 0, errors.New("Invalid offset")
    		}
    		d.idx = offset
    	case io.SeekCurrent:
    		if d.idx+offset < 0 {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Sep 19 18:05:16 GMT 2022
    - 4.8K bytes
    - Viewed (0)
  5. clause/where.go

    	OrWithSpace  = " OR "
    )
    
    // Where where clause
    type Where struct {
    	Exprs []Expression
    }
    
    // Name where clause name
    func (where Where) Name() string {
    	return "WHERE"
    }
    
    // Build build where clause
    func (where Where) Build(builder Builder) {
    	if len(where.Exprs) == 1 {
    		if andCondition, ok := where.Exprs[0].(AndConditions); ok {
    			where.Exprs = andCondition.Exprs
    		}
    	}
    
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Thu Apr 25 12:22:53 GMT 2024
    - 5.1K bytes
    - Viewed (0)
  6. clause/where_test.go

    				Exprs: []clause.Expression{clause.Or(clause.Neq{Column: "name", Value: "jinzhu"}), clause.Eq{Column: clause.PrimaryColumn, Value: "1"}, clause.Gt{Column: "age", Value: 18}},
    			}},
    			"SELECT * FROM `users` WHERE `users`.`id` = ? OR `name` <> ? AND `age` > ?",
    			[]interface{}{"1", "jinzhu", 18},
    		},
    		{
    			[]clause.Interface{clause.Select{}, clause.From{}, clause.Where{
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Thu Apr 25 12:22:53 GMT 2024
    - 6.2K bytes
    - Viewed (0)
  7. api/go1.20.txt

    pkg syscall (freebsd-riscv64), type Flock_t struct, Sysid int32 #53466
    pkg syscall (freebsd-riscv64), type Flock_t struct, Type int16 #53466
    pkg syscall (freebsd-riscv64), type Flock_t struct, Whence int16 #53466
    pkg syscall (freebsd-riscv64), type Fsid struct #53466
    pkg syscall (freebsd-riscv64), type Fsid struct, Val [2]int32 #53466
    pkg syscall (freebsd-riscv64), type ICMPv6Filter struct #53466
    Plain Text
    - Registered: Tue May 07 11:14:38 GMT 2024
    - Last Modified: Fri Feb 17 21:23:32 GMT 2023
    - 602.6K bytes
    - Viewed (0)
  8. api/go1.16.txt

    pkg syscall (darwin-arm64), type Flock_t struct, Pid int32
    pkg syscall (darwin-arm64), type Flock_t struct, Start int64
    pkg syscall (darwin-arm64), type Flock_t struct, Type int16
    pkg syscall (darwin-arm64), type Flock_t struct, Whence int16
    pkg syscall (darwin-arm64), type Fsid struct
    pkg syscall (darwin-arm64), type Fsid struct, Val [2]int32
    pkg syscall (darwin-arm64), type Fstore_t struct
    Plain Text
    - Registered: Tue May 07 11:14:38 GMT 2024
    - Last Modified: Fri Dec 02 16:30:41 GMT 2022
    - 479.2K bytes
    - Viewed (0)
  9. api/go1.14.txt

    pkg syscall (freebsd-arm64), type Flock_t struct, Sysid int32
    pkg syscall (freebsd-arm64), type Flock_t struct, Type int16
    pkg syscall (freebsd-arm64), type Flock_t struct, Whence int16
    pkg syscall (freebsd-arm64), type Fsid struct
    pkg syscall (freebsd-arm64), type Fsid struct, Val [2]int32
    pkg syscall (freebsd-arm64), type ICMPv6Filter struct
    Plain Text
    - Registered: Tue May 07 11:14:38 GMT 2024
    - Last Modified: Fri Feb 17 20:31:46 GMT 2023
    - 508.9K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/io/Closeables.java

       * propagating it.
       *
       * <p>While it's not safe in the general case to ignore exceptions that are thrown when closing an
       * I/O resource, it should generally be safe in the case of a resource that's being used only for
       * reading, such as an {@code InputStream}. Unlike with writable resources, there's no chance that
       * a failure that occurs when closing the stream indicates a meaningful problem such as a failure
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed May 17 14:35:11 GMT 2023
    - 4.7K bytes
    - Viewed (0)
Back to top