Documentation ¶
Index ¶
- Constants
- type FSTree
- func (*FSTree) Close() error
- func (t *FSTree) Delete(prm common.DeletePrm) (common.DeleteRes, error)
- func (t *FSTree) Exists(prm common.ExistsPrm) (common.ExistsRes, error)
- func (t *FSTree) Get(prm common.GetPrm) (common.GetRes, error)
- func (t *FSTree) GetRange(prm common.GetRangePrm) (common.GetRangeRes, error)
- func (t *FSTree) Init() error
- func (t *FSTree) Iterate(prm common.IteratePrm) (common.IterateRes, error)
- func (t *FSTree) NumberOfObjects() (uint64, error)
- func (t *FSTree) Open(ro bool) error
- func (t *FSTree) Path() string
- func (t *FSTree) Put(prm common.PutPrm) (common.PutRes, error)
- func (t *FSTree) PutStream(addr oid.Address, handler func(*os.File) error) error
- func (t *FSTree) SetCompressor(cc *compression.Config)
- func (t *FSTree) SetReportErrorFunc(f func(string, error))
- func (*FSTree) Type() string
- type Info
- type Option
Constants ¶
View Source
const ( // DirNameLen is how many bytes is used to group keys into directories. DirNameLen = 1 // in bytes // MaxDepth is maximum depth of nested directories. MaxDepth = (sha256.Size - 1) / DirNameLen )
View Source
const Type = "fstree"
Type is fstree storage type used in logs and configuration.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FSTree ¶
type FSTree struct { Info *compression.Config Depth uint64 DirNameLen int // contains filtered or unexported fields }
FSTree represents an object storage as a filesystem tree.
func (*FSTree) Exists ¶
Exists returns the path to the file with object contents if it exists in the storage and an error otherwise.
func (*FSTree) GetRange ¶
func (t *FSTree) GetRange(prm common.GetRangePrm) (common.GetRangeRes, error)
GetRange implements common.Storage.
func (*FSTree) Iterate ¶
func (t *FSTree) Iterate(prm common.IteratePrm) (common.IterateRes, error)
Iterate iterates over all stored objects.
func (*FSTree) NumberOfObjects ¶
NumberOfObjects walks the file tree rooted at FSTree's root and returns number of stored objects.
func (*FSTree) SetCompressor ¶
func (t *FSTree) SetCompressor(cc *compression.Config)
SetCompressor implements common.Storage.
func (*FSTree) SetReportErrorFunc ¶
SetReportErrorFunc implements common.Storage.
Click to show internal directories.
Click to hide internal directories.