Versions in this module Expand all Collapse all v0 v0.1.0 Oct 18, 2026 Changes in this version + var ErrInvalidBucket = errors.New("object storage: invalid bucket") + var ErrInvalidKey = errors.New("object storage: invalid key") + var ErrInvalidPart = errors.New("object storage: invalid multipart part") + var ErrInvalidRange = errors.New("object storage: invalid byte range") + var ErrNotFound = errors.New("object storage: not found") + var ErrPrecondition = errors.New("object storage: precondition failed") + func ValidateBucket(bucket Bucket) error + func ValidateKey(key Key) error + func WithProgress(reader io.Reader, total int64, progress ProgressFunc) io.Reader + func WithProgressReadCloser(body io.ReadCloser, total int64, progress ProgressFunc) io.ReadCloser + type BatchDeleter interface + DeleteMany func(context.Context, Bucket, []Key) ([]error, error) + type BatchStater interface + StatMany func(context.Context, Bucket, []Key) ([]StatResult, error) + type Bucket string + type ByteRange struct + Length int64 + Offset int64 + func (byteRange ByteRange) Validate() error + type CompletedPart struct + ETag string + Number int + SHA256 [32]byte + Size int64 + type Copier interface + Copy func(ctx context.Context, srcBucket Bucket, srcKey Key, dstBucket Bucket, ...) (Object, error) + type CopyOptions struct + ContentType string + IfAbsent bool + IfMatchVersion string + Metadata map[string]string + SourceVersion string + func (options CopyOptions) Clone() CopyOptions + type GetOptions struct + IfMatchVersion string + Range *ByteRange + func (options GetOptions) Clone() GetOptions + type Key string + type ListOptions struct + After Key + IncludeMetadata bool + Limit int + Prefix string + type MultipartStore interface + AbortMultipart func(context.Context, Upload) error + BeginMultipart func(context.Context, Bucket, Key, PutOptions) (Upload, error) + CompleteMultipart func(context.Context, Upload, []CompletedPart) (Object, error) + PutPart func(context.Context, Upload, int, io.Reader, int64, [32]byte) (CompletedPart, error) + type Object struct + Bucket Bucket + ETag string + Key Key + Metadata map[string]string + ModifiedAt time.Time + SHA256 [32]byte + SHA256Known bool + Size int64 + Version string + func (object Object) Clone() Object + func (object Object) Digest() ([32]byte, bool) + type Page struct + NextAfter Key + Objects []Object + func (page Page) Clone() Page + type PresignedRequest struct + ExpiresAt time.Time + Header http.Header + Method string + URL string + func (request PresignedRequest) Clone() PresignedRequest + type Presigner interface + PresignGet func(ctx context.Context, bucket Bucket, key Key, expires time.Duration, ...) (PresignedRequest, error) + PresignPut func(ctx context.Context, bucket Bucket, key Key, expires time.Duration, ...) (PresignedRequest, error) + PresignUploadPart func(ctx context.Context, upload Upload, number int, size int64, digest [32]byte, ...) (PresignedRequest, error) + type ProgressFunc func(transferred, total int64) + type PutOptions struct + ContentType string + IfAbsent bool + IfMatchVersion string + Metadata map[string]string + SHA256 *[32]byte + Size int64 + func (options PutOptions) Clone() PutOptions + func (options PutOptions) ValidateSize() error + type StatResult struct + Err error + Object Object + type Store interface + Delete func(context.Context, Bucket, Key, string) error + Get func(context.Context, Bucket, Key, GetOptions) (io.ReadCloser, Object, error) + List func(context.Context, Bucket, ListOptions) (Page, error) + Put func(context.Context, Bucket, Key, io.Reader, PutOptions) (Object, error) + Stat func(context.Context, Bucket, Key) (Object, error) + type Upload struct + Bucket Bucket + ID string + Key Key + Options PutOptions + func (upload Upload) Clone() Upload