package
0.0.0-20240318153351-c9fddc1e2fb5
Repository: https://github.com/dennwc/cas.git
Documentation: pkg.go.dev
# Functions
DecodeConfig reads and decodes config from a specified stream.
EncodeConfig encodes a storage config to a specified writer.
No description provided by the author
NewBlobIndexer emulates a blob indexer on top of a base storage.
No description provided by the author
RegisterConfig registers a new storage config.
VerifyReader wraps a reader and calculates a ref of the data on EOF.
No description provided by the author
# Variables
ErrBlobCompleted is returned for BlobWriter operations after the blob was completed.
ErrBlobDiscarded is returned for BlobWriter operations after the blob was discarded with Close.
ErrInvalidRef is returned when a passed Ref was invalid (zero, for example).
ErrNotFound is returned when a blob or a pin does not exists.
ErrReadOnly is returned when trying to perform a mutation ona read-only storage.
# Structs
ErrRefMissmatch is returned when the streamed content doesn't match an expected blob ref.
ErrSizeMissmatch is returned when the size of a streamed content doesn't match an expected size.
# Interfaces
BaseIterator is a common interface for all iterators.
BlobIndexer is an optional interface for Storage implementations that index schema blobs by type.
BlobSource is a read-only interface for a blob storage.
BlobStorage is a minimal interface for storing and retrieving blobs.
BlobWriter is an interface that allows to write immutable blobs to the storage.
Config is an interface for storage configuration objects.
Iterator iterates over raw blobs and list their sizes and refs.
PinIterator iterates over all pins and lists their names and associated refs.
PinStorage is a minimal interface for implementing a mutable storage over immutable storage.
SchemaIterator iterates over CAS schema blobs.
Storage is a minimal interface for a Content Addressable Storage.