amazons3

package
v0.15.0 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2019 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AmazonS3

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

AmazonS3 holds the S3 driver session

func Init

func Init(region, endpoint, bucket string) (*AmazonS3, error)

Init initializes an amazon s3 driver

func (*AmazonS3) Close

func (a *AmazonS3) Close() error

Gracefully close the s3 filestore module

func (*AmazonS3) CreateDir

func (a *AmazonS3) CreateDir(req *model.CreateFileRequest) error

CreateDir creates a directory in S3

func (*AmazonS3) CreateFile

func (a *AmazonS3) CreateFile(req *model.CreateFileRequest, file io.Reader) error

CreateFile creates a file in S3

func (*AmazonS3) DeleteDir

func (a *AmazonS3) DeleteDir(path string) error

DeleteDir deletes a directory in S3

func (*AmazonS3) DeleteFile

func (a *AmazonS3) DeleteFile(path string) error

DeleteFile deletes a file from S3

func (*AmazonS3) DoesExists added in v0.15.0

func (a *AmazonS3) DoesExists(path string) error

func (*AmazonS3) GetStoreType

func (a *AmazonS3) GetStoreType() utils.FileStoreType

GetStoreType returns the file store type

func (*AmazonS3) ListDir

ListDir lists a directory in S3

func (*AmazonS3) ReadFile

func (a *AmazonS3) ReadFile(path string) (*model.File, error)

ReadFile reads a file from S3

Jump to

Keyboard shortcuts

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