s3

package
v0.21.2 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2021 License: GPL-3.0 Imports: 7 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Bucket string
}

type Downloader

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

func NewDownloader

func NewDownloader(sess *session.Session) *Downloader

func (Downloader) Download

func (u Downloader) Download(ctx context.Context, location *Location) ([]byte, error)

type Location

type Location struct {
	Bucket string `json:"bucket"`
	Key    string `json:"key"`
	Url    string `json:"url"`
}

type Uploader

type Uploader struct {
	Bucket string
	// contains filtered or unexported fields
}

func NewUploader

func NewUploader(sess *session.Session, config Config) *Uploader

func (Uploader) Upload

func (u Uploader) Upload(ctx context.Context, key string, body []byte) (*Location, error)

Jump to

Keyboard shortcuts

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