file

package
v0.2.25 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2026 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FileBackend

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

func (FileBackend) Close

func (FileBackend) Close() error

func (*FileBackend) CreateObject

func (self *FileBackend) CreateObject(ctx context.Context, req schema.CreateObjectRequest) (*schema.Object, error)

Create object in the backend

func (FileBackend) DeleteObjects

func (self FileBackend) DeleteObjects(ctx context.Context, req schema.DeleteObjectsRequest) error

Delete objects in the backend (single object or prefix)

func (*FileBackend) GetObject

func (self *FileBackend) GetObject(ctx context.Context, req schema.GetObjectRequest) (*schema.Object, error)

Get object metadata from the backend

func (FileBackend) ListObjects

func (self FileBackend) ListObjects(ctx context.Context, iterator *schema.ObjectListIterator) (err error)

List objects or directories in the backend

func (*FileBackend) Name

func (self *FileBackend) Name() string

Name returns the name of the backend

func (*FileBackend) ReadObject

Read object content from the backend. Caller must close the returned reader.

func (*FileBackend) URL

func (self *FileBackend) URL() *url.URL

URL returns the backend destination URL. The scheme, host (bucket/name), and path (prefix/directory) identify the storage location. Query parameters carry useful non-credential details: region, endpoint, anonymous.

type WritableFS added in v0.2.14

type WritableFS interface {
	fs.FS
	Root() string
	Create(name string) (*os.File, error)
	Chtimes(name string, atime, mtime time.Time) error
	MkdirAll(name string, perm fs.FileMode) error
	Remove(name string) error
	RemoveAll(name string) error
}

WritableFS extends fs.FS with write operations against a rooted directory.

Jump to

Keyboard shortcuts

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