Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 230 for io_time (0.26 sec)

  1. internal/store/queuestore.go

    	sort.Slice(files, func(i, j int) bool {
    		ii, err := files[i].Info()
    		if err != nil {
    			return false
    		}
    		ji, err := files[j].Info()
    		if err != nil {
    			return true
    		}
    		return ii.ModTime().Before(ji.ModTime())
    	})
    
    	return files, nil
    }
    
    // Extension will return the file extension used
    // for the items stored in the queue.
    func (store *QueueStore[_]) Extension() string {
    	return store.fileExt
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Mon Mar 25 16:44:20 UTC 2024
    - 7.1K bytes
    - Viewed (0)
  2. src/io/fs/readdir_test.go

    }
    
    func TestFileInfoToDirEntry(t *testing.T) {
    	testFs := fstest.MapFS{
    		"notadir.txt": {
    			Data:    []byte("hello, world"),
    			Mode:    0,
    			ModTime: time.Now(),
    			Sys:     &sysValue,
    		},
    		"adir": {
    			Data:    nil,
    			Mode:    os.ModeDir,
    			ModTime: time.Now(),
    			Sys:     &sysValue,
    		},
    	}
    
    	tests := []struct {
    		path     string
    		wantMode FileMode
    		wantDir  bool
    	}{
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Nov 27 16:25:41 UTC 2023
    - 2.6K bytes
    - Viewed (0)
  3. src/io/fs/readfile_test.go

    	"testing/fstest"
    	"time"
    )
    
    var testFsys = fstest.MapFS{
    	"hello.txt": {
    		Data:    []byte("hello, world"),
    		Mode:    0456,
    		ModTime: time.Now(),
    		Sys:     &sysValue,
    	},
    	"sub/goodbye.txt": {
    		Data:    []byte("goodbye, world"),
    		Mode:    0456,
    		ModTime: time.Now(),
    		Sys:     &sysValue,
    	},
    }
    
    var sysValue int
    
    type readFileOnly struct{ ReadFileFS }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Nov 27 16:25:41 UTC 2023
    - 1.8K bytes
    - Viewed (0)
  4. internal/bucket/lifecycle/lifecycle.go

    func ExpectedExpiryTime(modTime time.Time, days int) time.Time {
    	if days == 0 {
    		return modTime
    	}
    	t := modTime.UTC().Add(time.Duration(days+1) * 24 * time.Hour)
    	return t.Truncate(24 * time.Hour)
    }
    
    // SetPredictionHeaders sets time to expiry and transition headers on w for a
    // given obj.
    func (lc Lifecycle) SetPredictionHeaders(w http.ResponseWriter, obj ObjectOpts) {
    	event := lc.eval(obj, time.Time{})
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu May 23 01:12:48 UTC 2024
    - 17.9K bytes
    - Viewed (0)
  5. cmd/storage-datatypes_test.go

    func BenchmarkDecodeFileInfoMsgp(b *testing.B) {
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Mon Sep 19 18:05:16 UTC 2022
    - 9.4K bytes
    - Viewed (0)
  6. cmd/xl-storage-format-v2_gen.go

    		case "ID":
    			err = dc.ReadExactBytes((z.VersionID)[:])
    			if err != nil {
    				err = msgp.WrapError(err, "VersionID")
    				return
    			}
    		case "MTime":
    			z.ModTime, err = dc.ReadInt64()
    			if err != nil {
    				err = msgp.WrapError(err, "ModTime")
    				return
    			}
    		case "MetaSys":
    			var zb0002 uint32
    			zb0002, err = dc.ReadMapHeader()
    			if err != nil {
    				err = msgp.WrapError(err, "MetaSys")
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Wed May 29 19:14:09 UTC 2024
    - 53.8K bytes
    - Viewed (0)
  7. pkg/serviceaccount/claims.go

    		return nil, errors.New("service account token claims could not be validated due to unexpected private claim")
    	}
    	nowTime := now()
    	err := public.Validate(jwt.Expected{
    		Time: nowTime,
    	})
    	switch err {
    	case nil:
    		// successful validation
    
    	case jwt.ErrExpired:
    		return nil, errors.New("service account token has expired")
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Oct 30 21:15:10 UTC 2023
    - 11.3K bytes
    - Viewed (0)
  8. src/archive/tar/writer.go

    // templateV7Plus or writeRawFile.
    func (tw *Writer) templateV7Plus(hdr *Header, fmtStr stringFormatter, fmtNum numberFormatter) *block {
    	tw.blk.reset()
    
    	modTime := hdr.ModTime
    	if modTime.IsZero() {
    		modTime = time.Unix(0, 0)
    	}
    
    	v7 := tw.blk.toV7()
    	v7.typeFlag()[0] = hdr.Typeflag
    	fmtStr(v7.name(), hdr.Name)
    	fmtStr(v7.linkName(), hdr.Linkname)
    	fmtNum(v7.mode(), hdr.Mode)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 19.6K bytes
    - Viewed (0)
  9. src/testing/fstest/mapfs.go

    type MapFS map[string]*MapFile
    
    // A MapFile describes a single file in a [MapFS].
    type MapFile struct {
    	Data    []byte      // file content
    	Mode    fs.FileMode // fs.FileInfo.Mode
    	ModTime time.Time   // fs.FileInfo.ModTime
    	Sys     any         // fs.FileInfo.Sys
    }
    
    var _ fs.FS = MapFS(nil)
    var _ fs.File = (*openMapFile)(nil)
    
    // Open opens the named file.
    func (fsys MapFS) Open(name string) (fs.File, error) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 7.1K bytes
    - Viewed (0)
  10. cmd/xl-storage-format-v2_test.go

    				}
    			}
    		})
    		t.Run(fmt.Sprintf("modtime-q%d", i), func(t *testing.T) {
    			// Mutate modtime, but rest is consistent.
    			vMod := make([][]xlMetaV2ShallowVersion, 0, len(vers))
    			for i, ver := range vers {
    				newVers := make([]xlMetaV2ShallowVersion, 0, len(ver))
    				for _, v := range ver {
    					v.header.ModTime += int64(i)
    					newVers = append(newVers, v)
    				}
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri Mar 08 17:50:48 UTC 2024
    - 36.4K bytes
    - Viewed (0)
Back to top