Versions in this module Expand all Collapse all v0 v0.0.1 Nov 28, 2024 Changes in this version + const ACCOUNT_TYPE + const API_URL + const APP_ID + const AUTH_URL + const CHANNEL_ID + const CLIENT_TYPE + const MAC + const PC + const RETURN_URL + const UPLOAD_URL + const VERSION + const WEB_URL + var ErrIsConflict = errors.New("there is a conflict with the target object") + func AesECBEncrypt(data, key string) string + func BoolToNumber(b bool) int + func IF[V any](o bool, t V, f V) V + func MustParseTime(str string) *time.Time + func MustString(str string, err error) string + func PKCS7Padding(ciphertext []byte, blockSize int) []byte + func ParseHttpHeader(str string) map[string]string + func RsaEncrypt(publicKey, origData string) string + type Addition struct + FamilyID string + FamilyTransfer bool + NoUseOcr bool + OrderBy string + OrderDirection string + Password string + RapidUpload bool + Type string + UploadMethod string + UploadThread string + Username string + VCode string + type AppSessionResp struct + AccessToken string + IsSaveName string + RefreshToken string + type BatchTaskConflictTaskInfoResp struct + SessionKey string + TargetFolderID int + TaskID string + TaskInfos []BatchTaskInfo + TaskType int + type BatchTaskInfo struct + DealWay int + FileId string + FileName string + IsConflict int + IsFolder int + SrcParentId string + type BatchTaskStateResp struct + FailedCount int + Process int + SkipCount int + SubTaskCount int + SuccessedCount int + SuccessedFileIDList []int64 + TaskID string + TaskStatus int + type Cloud189File struct + CreateDate Time + ID String + Icon struct{ ... } + LastOpTime Time + Md5 string + Name string + Size int64 + func (c *Cloud189File) CreateTime() time.Time + func (c *Cloud189File) GetHash() utils.HashInfo + func (c *Cloud189File) GetID() string + func (c *Cloud189File) GetName() string + func (c *Cloud189File) GetPath() string + func (c *Cloud189File) GetSize() int64 + func (c *Cloud189File) IsDir() bool + func (c *Cloud189File) ModTime() time.Time + func (c *Cloud189File) Thumb() string + type Cloud189FilesResp struct + FileListAO struct{ ... } + type Cloud189Folder struct + CreateDate Time + ID String + LastOpTime Time + Name string + ParentID int64 + func (c *Cloud189Folder) CreateTime() time.Time + func (c *Cloud189Folder) GetHash() utils.HashInfo + func (c *Cloud189Folder) GetID() string + func (c *Cloud189Folder) GetName() string + func (c *Cloud189Folder) GetPath() string + func (c *Cloud189Folder) GetSize() int64 + func (c *Cloud189Folder) IsDir() bool + func (c *Cloud189Folder) ModTime() time.Time + type Cloud189PC struct + func (y *Cloud189PC) CheckBatchTask(aType string, taskID string) (*BatchTaskStateResp, error) + func (y *Cloud189PC) Config() driver.Config + func (y *Cloud189PC) Copy(ctx context.Context, srcObj, dstDir model.Obj) error + func (y *Cloud189PC) CreateBatchTask(aType string, familyID string, targetFolderId string, other map[string]string, ...) (*CreateBatchTaskResp, error) + func (y *Cloud189PC) Drop(ctx context.Context) error + func (y *Cloud189PC) EncryptParams(params Params, isFamily bool) string + func (y *Cloud189PC) FastUpload(ctx context.Context, dstDir model.Obj, file model.FileStreamer, ...) (model.Obj, error) + func (y *Cloud189PC) GetAddition() driver.Additional + func (y *Cloud189PC) GetConflictTaskInfo(aType string, taskID string) (*BatchTaskConflictTaskInfoResp, error) + func (y *Cloud189PC) GetMultiUploadUrls(ctx context.Context, isFamily bool, uploadFileId string, partInfo ...string) ([]UploadUrlInfo, error) + func (y *Cloud189PC) Init(ctx context.Context) (err error) + func (y *Cloud189PC) Link(ctx context.Context, file model.Obj, args model.LinkArgs) (*model.Link, error) + func (y *Cloud189PC) List(ctx context.Context, dir model.Obj, args model.ListArgs) ([]model.Obj, error) + func (y *Cloud189PC) MakeDir(ctx context.Context, parentDir model.Obj, dirName string) (model.Obj, error) + func (y *Cloud189PC) ManageBatchTask(aType string, taskID string, targetFolderId string, taskInfos ...BatchTaskInfo) error + func (y *Cloud189PC) Move(ctx context.Context, srcObj, dstDir model.Obj) (model.Obj, error) + func (y *Cloud189PC) OldUpload(ctx context.Context, dstDir model.Obj, file model.FileStreamer, ...) (model.Obj, error) + func (y *Cloud189PC) OldUploadCommit(ctx context.Context, fileCommitUrl string, uploadFileID int64, isFamily bool, ...) (model.Obj, error) + func (y *Cloud189PC) OldUploadCreate(ctx context.Context, parentID string, fileMd5, fileName, fileSize string, ...) (*CreateUploadFileResp, error) + func (y *Cloud189PC) Put(ctx context.Context, dstDir model.Obj, stream model.FileStreamer, ...) (newObj model.Obj, err error) + func (y *Cloud189PC) RapidUpload(ctx context.Context, dstDir model.Obj, stream model.FileStreamer, ...) (model.Obj, error) + func (y *Cloud189PC) Remove(ctx context.Context, obj model.Obj) error + func (y *Cloud189PC) Rename(ctx context.Context, srcObj model.Obj, newName string) (model.Obj, error) + func (y *Cloud189PC) SaveFamilyFileToPersonCloud(ctx context.Context, familyId string, srcObj, dstDir model.Obj, overwrite bool) error + func (y *Cloud189PC) SignatureHeader(url, method, params string, isFamily bool) map[string]string + func (y *Cloud189PC) StreamUpload(ctx context.Context, dstDir model.Obj, file model.FileStreamer, ...) (model.Obj, error) + func (y *Cloud189PC) WaitBatchTask(aType string, taskID string, t time.Duration) error + type CommitMultiUploadFileResp struct + File struct{ ... } + type CreateBatchTaskResp struct + TaskID string + type CreateUploadFileResp struct + FileCommitUrl string + FileDataExists int + FileUploadUrl string + UploadFileId int64 + type EncryptConfResp struct + Data struct{ ... } + Result int + type FamilyInfoListResp struct + FamilyInfoResp []FamilyInfoResp + type FamilyInfoResp struct + Count int + CreateTime string + FamilyID int64 + RemarkName string + Type int + UseFlag int + UserRole int + type GetUploadFileStatusResp struct + DataSize int64 + Size int64 + func (r *GetUploadFileStatusResp) GetSize() int64 + type InitMultiUploadResp struct + Data struct{ ... } + type LoginParam struct + CaptchaToken string + Lt string + ParamId string + ReqId string + RsaPassword string + RsaUsername string + type LoginResp struct + Msg string + Result int + ToUrl string + type OldCommitUploadFileResp struct + CreateDate Time + ID String + Md5 string + Name string + Size int64 + XMLName xml.Name + type Params map[string]string + func (p Params) Encode() string + func (p Params) Set(k, v string) + type RespErr struct + Code string + ErrorCode string + ErrorMsg string + Error_ string + Message string + Msg string + ResCode any + ResMessage string + XMLName xml.Name + func (e *RespErr) Error() string + func (e *RespErr) HasError() bool + type String string + func (s *String) Unmarshal(b []byte) error + func (t *String) UnmarshalJSON(b []byte) error + func (t *String) UnmarshalXML(e *xml.Decoder, ee xml.StartElement) error + type Time time.Time + func (t *Time) Unmarshal(b []byte) error + func (t *Time) UnmarshalJSON(b []byte) error + func (t *Time) UnmarshalXML(e *xml.Decoder, ee xml.StartElement) error + type UploadProgress struct + UploadInfo InitMultiUploadResp + UploadParts []string + type UploadUrlInfo struct + Headers map[string]string + PartNumber int + type UploadUrlsData struct + RequestHeader string + RequestURL string + type UploadUrlsResp struct + Code string + Data map[string]UploadUrlsData + type UserSessionResp struct + FamilySessionKey string + FamilySessionSecret string + GetFileDiffSpan int + GetUserInfoSpan int + KeepAlive int + LoginName string + ResCode int + ResMessage string + SessionKey string + SessionSecret string