Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for isInDir (0.2 sec)

  1. 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)
  2. 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)
Back to top