objstr

package module
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 12, 2025 License: MIT Imports: 20 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewContext

func NewContext(ctx context.Context, os *ObjectStore) context.Context

Types

type Config

type Config struct {
	CopyBufferSize int
	DefaultBackend string
	BackendConfig
	Backends map[string]BackendConfig
}

func (*Config) WithBackend

func (c *Config) WithBackend(scheme string, backendConf BackendConfig) *Config

func (*Config) WithCopyBufferSize

func (c *Config) WithCopyBufferSize(size int) *Config

type ObjectStore

type ObjectStore struct {
	// contains filtered or unexported fields
}

func FromContext

func FromContext(ctx context.Context) *ObjectStore

func FromContextOrDefault

func FromContextOrDefault(ctx context.Context) *ObjectStore

func GetDefault

func GetDefault() *ObjectStore

func MustNewObjectStore

func MustNewObjectStore(ctx context.Context, conf Config) *ObjectStore

func NewObjectStore

func NewObjectStore(ctx context.Context, conf Config) (*ObjectStore, error)

func NewObjectStoreFromURL added in v0.6.0

func NewObjectStoreFromURL(ctx context.Context, u *url.URL) (*ObjectStore, error)

func (*ObjectStore) Close

func (os *ObjectStore) Close() error

func (*ObjectStore) Copy

func (os *ObjectStore) Copy(ctx context.Context, src *url.URL, dst *url.URL) error

func (*ObjectStore) Delete

func (os *ObjectStore) Delete(ctx context.Context, u *url.URL) error

func (*ObjectStore) ListPrefix

func (os *ObjectStore) ListPrefix(ctx context.Context, u *url.URL, optsFunc ...types.ListOption) ([]*types.Object, error)

func (*ObjectStore) Move

func (os *ObjectStore) Move(ctx context.Context, src *url.URL, dst *url.URL) error

func (*ObjectStore) ReadMetadata

func (os *ObjectStore) ReadMetadata(ctx context.Context, u *url.URL) (*types.ObjectMetadata, error)

func (*ObjectStore) Reader

func (os *ObjectStore) Reader(ctx context.Context, u *url.URL) (types.Reader, error)

func (*ObjectStore) ReaderAt

func (os *ObjectStore) ReaderAt(ctx context.Context, u *url.URL) (types.ReaderAt, error)

func (*ObjectStore) Writer

func (os *ObjectStore) Writer(ctx context.Context, u *url.URL) (types.Writer, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL