core

package
v4.0.0-rc6 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2022 License: AGPL-3.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithFlatInterceptor

func WithFlatInterceptor() nodes.Option

func WithStructInterceptor added in v4.0.1

func WithStructInterceptor() nodes.Option

Types

type Executor

type Executor struct {
	abstract.Handler
}

Executor is the final handler: it does not have a "Next" handler, but actually performs all requests.

func (*Executor) CopyObject

func (e *Executor) CopyObject(ctx context.Context, from *tree.Node, to *tree.Node, requestData *models.CopyRequestData) (models.ObjectInfo, error)

func (*Executor) CreateNode

func (*Executor) DeleteNode

func (*Executor) ExecuteWrapped

func (e *Executor) ExecuteWrapped(inputFilter nodes.FilterFunc, outputFilter nodes.FilterFunc, provider nodes.CallbackFunc) error

func (*Executor) GetObject

func (e *Executor) GetObject(ctx context.Context, node *tree.Node, requestData *models.GetRequestData) (io.ReadCloser, error)

func (*Executor) ListNodes

func (*Executor) MultipartAbort

func (e *Executor) MultipartAbort(ctx context.Context, target *tree.Node, uploadID string, requestData *models.MultipartRequestData) error

func (*Executor) MultipartComplete

func (e *Executor) MultipartComplete(ctx context.Context, target *tree.Node, uploadID string, uploadedParts []models.MultipartObjectPart) (models.ObjectInfo, error)

func (*Executor) MultipartCreate

func (e *Executor) MultipartCreate(ctx context.Context, target *tree.Node, requestData *models.MultipartRequestData) (string, error)

func (*Executor) MultipartList

func (e *Executor) MultipartList(ctx context.Context, prefix string, requestData *models.MultipartRequestData) (res models.ListMultipartUploadsResult, err error)

func (*Executor) MultipartListObjectParts

func (e *Executor) MultipartListObjectParts(ctx context.Context, target *tree.Node, uploadID string, partNumberMarker int, maxParts int) (models.ListObjectPartsResult, error)

func (*Executor) MultipartPutObjectPart

func (e *Executor) MultipartPutObjectPart(ctx context.Context, target *tree.Node, uploadID string, partNumberMarker int, reader io.Reader, requestData *models.PutRequestData) (models.MultipartObjectPart, error)

func (*Executor) PutObject

func (e *Executor) PutObject(ctx context.Context, node *tree.Node, reader io.Reader, requestData *models.PutRequestData) (models.ObjectInfo, error)

func (*Executor) ReadNode

func (*Executor) UpdateNode

func (*Executor) WrappedCanApply

func (e *Executor) WrappedCanApply(_ context.Context, _ context.Context, _ *tree.NodeChangeEvent) error

type FlatStorageHandler

type FlatStorageHandler struct {
	abstract.Handler
}

FlatStorageHandler intercepts request to a flat-storage

func (*FlatStorageHandler) Adapt

func (*FlatStorageHandler) CopyObject

func (f *FlatStorageHandler) CopyObject(ctx context.Context, from *tree.Node, to *tree.Node, requestData *models.CopyRequestData) (models.ObjectInfo, error)

func (*FlatStorageHandler) CreateNode

CreateNode creates directly in index, but make sure not to override

func (*FlatStorageHandler) DeleteNode

func (*FlatStorageHandler) GetObject

func (f *FlatStorageHandler) GetObject(ctx context.Context, node *tree.Node, requestData *models.GetRequestData) (io.ReadCloser, error)

func (*FlatStorageHandler) MultipartAbort

func (f *FlatStorageHandler) MultipartAbort(ctx context.Context, target *tree.Node, uploadID string, requestData *models.MultipartRequestData) error

func (*FlatStorageHandler) MultipartComplete

func (f *FlatStorageHandler) MultipartComplete(ctx context.Context, target *tree.Node, uploadID string, uploadedParts []models.MultipartObjectPart) (models.ObjectInfo, error)

func (*FlatStorageHandler) MultipartListObjectParts

func (f *FlatStorageHandler) MultipartListObjectParts(ctx context.Context, target *tree.Node, uploadID string, partNumberMarker int, maxParts int) (lpi models.ListObjectPartsResult, err error)

func (*FlatStorageHandler) MultipartPutObjectPart

func (f *FlatStorageHandler) MultipartPutObjectPart(ctx context.Context, target *tree.Node, uploadID string, partNumberMarker int, reader io.Reader, requestData *models.PutRequestData) (models.MultipartObjectPart, error)

func (*FlatStorageHandler) PutObject

func (f *FlatStorageHandler) PutObject(ctx context.Context, node *tree.Node, reader io.Reader, requestData *models.PutRequestData) (models.ObjectInfo, error)

type StructStorageHandler added in v4.0.1

type StructStorageHandler struct {
	abstract.Handler
	// contains filtered or unexported fields
}

StructStorageHandler intercepts request to a flat-storage

func (*StructStorageHandler) Adapt added in v4.0.1

func (*StructStorageHandler) CopyObject added in v4.0.1

func (f *StructStorageHandler) CopyObject(ctx context.Context, from *tree.Node, to *tree.Node, requestData *models.CopyRequestData) (models.ObjectInfo, error)

func (*StructStorageHandler) CreateNode added in v4.0.1

func (*StructStorageHandler) DeleteNode added in v4.0.1

func (*StructStorageHandler) MultipartComplete added in v4.0.1

func (f *StructStorageHandler) MultipartComplete(ctx context.Context, target *tree.Node, uploadID string, uploadedParts []models.MultipartObjectPart) (models.ObjectInfo, error)

func (*StructStorageHandler) PutObject added in v4.0.1

func (f *StructStorageHandler) PutObject(ctx context.Context, node *tree.Node, reader io.Reader, requestData *models.PutRequestData) (models.ObjectInfo, error)

Jump to

Keyboard shortcuts

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