- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for isInDir (0.12 sec)
-
cmd/metacache-entries_test.go
want: true, }, } for _, tt := range tests { t.Run(tt.testName, func(t *testing.T) { e := metaCacheEntry{ name: tt.entry, } if got := e.isInDir(tt.dir, tt.sep); got != tt.want { t.Errorf("isInDir() = %v, want %v", got, tt.want) } }) } } func Test_metaCacheEntries_resolve(t *testing.T) { baseTime, err := time.Parse("2006/01/02", "2015/02/25") if err != nil {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sun Jan 02 17:15:06 UTC 2022 - 31.6K bytes - Viewed (0) -
cmd/metacache-entries.go
} return other, false } } // If we match, return e if prefer == nil { prefer = e } return prefer, true } // isInDir returns whether the entry is in the dir when considering the separator. func (e metaCacheEntry) isInDir(dir, separator string) bool { if len(dir) == 0 { // Root idx := strings.Index(e.name, separator) return idx == -1 || idx == len(e.name)-len(separator) }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 08 15:29:58 UTC 2024 - 24.1K bytes - Viewed (0) -
cmd/metacache-set.go
continue } if o.Marker != "" && entry.name < o.Marker { continue } if !strings.HasPrefix(entry.name, o.Prefix) { continue } if !o.Recursive && !entry.isInDir(o.Prefix, o.Separator) { continue } if !o.InclDeleted && entry.isObject() && entry.isLatestDeletemarker() && !entry.isObjectDir() { continue }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Jul 12 16:23:16 UTC 2024 - 30.7K bytes - Viewed (0)