s3

package
v1.7.24 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2025 License: MIT Imports: 10 Imported by: 2

Documentation

Index

Constants

View Source
const Name = "object"

Variables

This section is empty.

Functions

func IsNotExist added in v1.4.0

func IsNotExist(err error) bool

Types

type Config added in v1.1.0

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

type ConfigOption added in v1.1.0

type ConfigOption func(Config) Config

func WithRegion added in v1.1.0

func WithRegion(region string) ConfigOption

func WithStorageClass added in v1.1.0

func WithStorageClass(storageClass string) ConfigOption

type Service added in v1.7.1

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

func New

func New(endpoint, accessKey, secretAccess, bucket string, useSSL bool, partSize uint64, options ...ConfigOption) (Service, error)

func (Service) ConvertError added in v1.7.1

func (a Service) ConvertError(err error) error

func (Service) Enabled added in v1.7.1

func (a Service) Enabled() bool

func (Service) List added in v1.7.1

func (a Service) List(ctx context.Context, pathname string) ([]model.Item, error)

func (Service) Mkdir added in v1.7.1

func (a Service) Mkdir(ctx context.Context, name string, _ os.FileMode) error

func (Service) Name added in v1.7.1

func (a Service) Name() string

func (Service) Path added in v1.7.1

func (a Service) Path(pathname string) string

func (Service) ReadFrom added in v1.7.1

func (a Service) ReadFrom(ctx context.Context, pathname string) (model.ReadAtSeekCloser, error)

func (Service) RemoveAll added in v1.7.1

func (a Service) RemoveAll(ctx context.Context, name string) error

func (Service) Rename added in v1.7.1

func (a Service) Rename(ctx context.Context, oldName, newName string) error

func (Service) Stat added in v1.7.1

func (a Service) Stat(ctx context.Context, pathname string) (model.Item, error)

func (Service) UpdateDate added in v1.7.1

func (a Service) UpdateDate(_ context.Context, _ string, _ time.Time) error

func (Service) Walk added in v1.7.1

func (a Service) Walk(ctx context.Context, pathname string, walkFn func(model.Item) error) error

func (Service) WithIgnoreFn added in v1.7.1

func (a Service) WithIgnoreFn(ignoreFn func(model.Item) bool) model.Storage

func (Service) WriteTo added in v1.7.1

func (a Service) WriteTo(ctx context.Context, pathname string, reader io.Reader, opts model.WriteOpts) error

Jump to

Keyboard shortcuts

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