resource

package
v1.0.1-rc5 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckMD5

func CheckMD5(filename, sum string) error

func CheckResourceExist added in v1.0.0

func CheckResourceExist(ctx context.Context, path string) bool

func DeleteResource added in v1.0.0

func DeleteResource(ctx context.Context, resID types.SFID) error

func FetchOrCreateResource

func FetchOrCreateResource(ctx context.Context, f *multipart.FileHeader) (*models.Resource, error)

func GetBySFID added in v1.1.0

func GetBySFID(ctx context.Context, id types.SFID) (*models.Resource, error)

func IsDirExists

func IsDirExists(path string) bool

func IsPathExists

func IsPathExists(path string) bool

func ListResource added in v1.0.0

func ListResource(ctx context.Context) ([]models.Resource, error)

func UnTar

func UnTar(dst, src string) (err error)

func Upload

func Upload(ctx context.Context, f *multipart.FileHeader, id string) (root, fullName, sum string, err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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