Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Backend ¶
type Backend interface { Copy(file string) error Prune(deadline time.Time, pruningPrefix string) (*PruneStats, error) Name() string }
Backend is an interface for defining functions which all storage providers support.
type PruneStats ¶
PruneStats is a wrapper struct for returning stats after pruning
type StorageBackend ¶
StorageBackend is a generic type of storage. Everything here are common properties of all storage types.
func (*StorageBackend) DoPrune ¶
func (b *StorageBackend) DoPrune(context string, lenMatches, lenCandidates int, deadline time.Time, doRemoveFiles func() error) error
DoPrune holds general control flow that applies to any kind of storage. Callers can pass in a thunk that performs the actual deletion of files.
Click to show internal directories.
Click to hide internal directories.