upyun

package
v0.0.0-...-7cc72ef Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2025 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultObjsChannelSize = 10

Variables

View Source
var UpYun *upyun.UpYun

Functions

func DeleteImg

func DeleteImg(url string) error

DeleteImg 又拍云删除文件

func GenerateImgName

func GenerateImgName(suffix string) string

GenerateImgName 生成图片名字

func GetDir

func GetDir(path string) (*model.UpYunFileDir, error)

GetDir 获取目录下的文件和文件夹

func GetDownloadUrl

func GetDownloadUrl(uri string) (string, error)

GetDownloadUrl 基于路径获取对应的下载链接

func GetPolicy

func GetPolicy() string

GetPolicy generates the policy string for requests.

func JoinFileName

func JoinFileName(fileName string) string

JoinFileName 生成文件名字

func NewUpYun

func NewUpYun()

func SignStr

func SignStr(policy string) string

SignStr generates the signature string for authentication.

func URlGetFile

func URlGetFile(url string) (*[]byte, error)

URlGetFile 又拍云下载文件

func URlUploadFile

func URlUploadFile(file []byte, url string) error

URlUploadFile 又拍云上传文件

func UploadFile

func UploadFile(filepath, ussDir string) error

UploadFile 支持上传文件 20241030: 暂时搁置上传计划

func UploadImg

func UploadImg(file []byte, url string) error

UploadImg 又拍云上传文件

Types

This section is empty.

Jump to

Keyboard shortcuts

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