weiyun

package
v3.35.3-8Mi Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2024 License: AGPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Addition

type Addition struct {
	RootFolderID   string `json:"root_folder_id"`
	Cookies        string `json:"cookies" required:"true"`
	OrderBy        string `json:"order_by" type:"select" options:"name,size,updated_at" default:"name"`
	OrderDirection string `json:"order_direction" type:"select" options:"asc,desc" default:"asc"`
	UploadThread   string `json:"upload_thread" default:"4" help:"4<=thread<=32"`
}

type File

type File struct {
	PFolder *Folder
	weiyunsdkgo.File
}

func (*File) CreateTime

func (f *File) CreateTime() time.Time

func (*File) GetHash

func (f *File) GetHash() utils.HashInfo

func (*File) GetID

func (f *File) GetID() string

func (*File) GetName

func (f *File) GetName() string

func (*File) GetPKey

func (f *File) GetPKey() string

func (*File) GetPath

func (f *File) GetPath() string

func (*File) GetSize

func (f *File) GetSize() int64

func (*File) IsDir

func (f *File) IsDir() bool

func (*File) ModTime

func (f *File) ModTime() time.Time

type Folder

type Folder struct {
	PFolder *Folder
	weiyunsdkgo.Folder
}

func (*Folder) CreateTime

func (f *Folder) CreateTime() time.Time

func (*Folder) GetHash

func (f *Folder) GetHash() utils.HashInfo

func (*Folder) GetID

func (f *Folder) GetID() string

func (*Folder) GetName

func (f *Folder) GetName() string

func (*Folder) GetPKey

func (f *Folder) GetPKey() string

func (*Folder) GetPath

func (f *Folder) GetPath() string

func (*Folder) GetSize

func (f *Folder) GetSize() int64

func (*Folder) IsDir

func (f *Folder) IsDir() bool

func (*Folder) ModTime

func (f *Folder) ModTime() time.Time

type WeiYun

type WeiYun struct {
	model.Storage
	Addition
	// contains filtered or unexported fields
}

func (*WeiYun) Config

func (d *WeiYun) Config() driver.Config

func (*WeiYun) Copy

func (d *WeiYun) Copy(ctx context.Context, srcObj, dstDir model.Obj) error

func (*WeiYun) Drop

func (d *WeiYun) Drop(ctx context.Context) error

func (*WeiYun) GetAddition

func (d *WeiYun) GetAddition() driver.Additional

func (*WeiYun) GetRoot

func (d *WeiYun) GetRoot(ctx context.Context) (model.Obj, error)

func (*WeiYun) Init

func (d *WeiYun) Init(ctx context.Context) error
func (d *WeiYun) Link(ctx context.Context, file model.Obj, args model.LinkArgs) (*model.Link, error)

func (*WeiYun) List

func (d *WeiYun) List(ctx context.Context, dir model.Obj, args model.ListArgs) ([]model.Obj, error)

func (*WeiYun) MakeDir

func (d *WeiYun) MakeDir(ctx context.Context, parentDir model.Obj, dirName string) (model.Obj, error)

func (*WeiYun) Move

func (d *WeiYun) Move(ctx context.Context, srcObj, dstDir model.Obj) (model.Obj, error)

func (*WeiYun) Put

func (d *WeiYun) Put(ctx context.Context, dstDir model.Obj, stream model.FileStreamer, up driver.UpdateProgress) (model.Obj, error)

func (*WeiYun) Remove

func (d *WeiYun) Remove(ctx context.Context, obj model.Obj) error

func (*WeiYun) Rename

func (d *WeiYun) Rename(ctx context.Context, srcObj model.Obj, newName string) (model.Obj, error)

Jump to

Keyboard shortcuts

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