qiniu

package
v1.2.8 Latest Latest
Warning

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

Go to latest
Published: Sep 23, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	UseHttps      bool
	UseCdnDomains bool
	CentralRsHost string
	NotifyUrl     string
	Pipeline      string
}

type FopConfig

type FopConfig struct {
	Fops    []string
	Force   bool
	FileKey string
}

type Option

type Option func(*Options)

func WithAccess

func WithAccess(access string) Option

func WithBucket

func WithBucket(bucket string) Option

func WithDomain

func WithDomain(domain string) Option

func WithOperationConf

func WithOperationConf(conf *Config) Option

func WithPrivate

func WithPrivate(private bool) Option

func WithSecret

func WithSecret(secret string) Option

func WithStorageConfig

func WithStorageConfig(config *Config) Option

func WithTTL

func WithTTL(ttl time.Duration) Option

type Options

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

type Qiniu

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

func New

func New(opts ...Option) *Qiniu

func (*Qiniu) EncodeEntry

func (qiniu *Qiniu) EncodeEntry(fileName string) string

func (*Qiniu) MakePrivateURL

func (qiniu *Qiniu) MakePrivateURL(domain, key string, deadline int64) string

MakePrivateURL 获取私有文件的下载链接地址

func (*Qiniu) MakePrivateURLWithQuery

func (qiniu *Qiniu) MakePrivateURLWithQuery(domain, key string, query url.Values, deadline int64) string

func (*Qiniu) MakePrivateURLWithQueryString

func (qiniu *Qiniu) MakePrivateURLWithQueryString(domain, key, query string, deadline int64) string

func (*Qiniu) Mkzip added in v1.2.6

func (qiniu *Qiniu) Mkzip(mode int, files []string, zipFile string) string

func (*Qiniu) Pfop

func (qiniu *Qiniu) Pfop(config *FopConfig) (string, error)

func (*Qiniu) Provide

func (qiniu *Qiniu) Provide(ctx context.Context) interface{}

func (*Qiniu) UploadToken

func (qiniu *Qiniu) UploadToken(keys ...string) string

Jump to

Keyboard shortcuts

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