tus

package
v2.0.29 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Uploader added in v2.0.21

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

func NewUploader added in v2.0.21

func NewUploader(client *http.Client, timeout time.Duration, token string) *Uploader

func (*Uploader) CreateUpload added in v2.0.21

func (u *Uploader) CreateUpload(baseCtx context.Context, filename string, parentID, length int64) (location string, err error)

func (*Uploader) GetOffset added in v2.0.21

func (u *Uploader) GetOffset(ctx context.Context, location string) (n int64, err error)

func (*Uploader) SendFile added in v2.0.21

func (u *Uploader) SendFile(ctx context.Context, r io.Reader, location string, offset int64) (fileID int64, crc32 string, err error)

func (*Uploader) TerminateUpload added in v2.0.21

func (u *Uploader) TerminateUpload(ctx context.Context, location string) (err error)

Jump to

Keyboard shortcuts

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