Documentation
¶
Index ¶
- func NewPrivateKey() (*ecdsa.PrivateKey, error)
- func NewPrivateKeyFromBytes(priv []byte) *ecdsa.PrivateKey
- func NewPrivateKeyFromHex(hex_ string) (*ecdsa.PrivateKey, error)
- func PrivateKeyToBytes(private *ecdsa.PrivateKey) []byte
- func PrivateKeyToHex(private *ecdsa.PrivateKey) string
- func PublicKeyToBytes(public *ecdsa.PublicKey) []byte
- func PublicKeyToHex(public *ecdsa.PublicKey) string
- type Addition
- type AliDrive
- func (d *AliDrive) Config() driver.Config
- func (d *AliDrive) Copy(ctx context.Context, srcObj, dstDir model.Obj) error
- func (d *AliDrive) Drop(ctx context.Context) error
- func (d *AliDrive) GetAddition() driver.Additional
- func (d *AliDrive) Init(ctx context.Context) error
- func (d *AliDrive) Link(ctx context.Context, file model.Obj, args model.LinkArgs) (*model.Link, error)
- func (d *AliDrive) List(ctx context.Context, dir model.Obj, args model.ListArgs) ([]model.Obj, error)
- func (d *AliDrive) MakeDir(ctx context.Context, parentDir model.Obj, dirName string) error
- func (d *AliDrive) Move(ctx context.Context, srcObj, dstDir model.Obj) error
- func (d *AliDrive) Other(ctx context.Context, args model.OtherArgs) (interface{}, error)
- func (d *AliDrive) Put(ctx context.Context, dstDir model.Obj, streamer model.FileStreamer, ...) error
- func (d *AliDrive) Remove(ctx context.Context, obj model.Obj) error
- func (d *AliDrive) Rename(ctx context.Context, srcObj model.Obj, newName string) error
- type File
- type Files
- type RespErr
- type State
- type UploadResp
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewPrivateKey ¶
func NewPrivateKey() (*ecdsa.PrivateKey, error)
func NewPrivateKeyFromBytes ¶
func NewPrivateKeyFromBytes(priv []byte) *ecdsa.PrivateKey
func NewPrivateKeyFromHex ¶
func NewPrivateKeyFromHex(hex_ string) (*ecdsa.PrivateKey, error)
func PrivateKeyToBytes ¶
func PrivateKeyToBytes(private *ecdsa.PrivateKey) []byte
func PrivateKeyToHex ¶
func PrivateKeyToHex(private *ecdsa.PrivateKey) string
func PublicKeyToBytes ¶
func PublicKeyToHex ¶
Types ¶
type Addition ¶
type Addition struct {
driver.RootID
RefreshToken string `json:"refresh_token" required:"true"`
//DeviceID string `json:"device_id" required:"true"`
OrderBy string `json:"order_by" type:"select" options:"name,size,updated_at,created_at"`
OrderDirection string `json:"order_direction" type:"select" options:"ASC,DESC"`
RapidUpload bool `json:"rapid_upload"`
InternalUpload bool `json:"internal_upload"`
}
type AliDrive ¶
type AliDrive struct {
model.Storage
Addition
AccessToken string
DriveId string
UserID string
// contains filtered or unexported fields
}
func (*AliDrive) GetAddition ¶
func (d *AliDrive) GetAddition() driver.Additional
type File ¶
type File struct {
DriveId string `json:"drive_id"`
CreatedAt *time.Time `json:"created_at"`
FileExtension string `json:"file_extension"`
FileId string `json:"file_id"`
Type string `json:"type"`
Name string `json:"name"`
Category string `json:"category"`
ParentFileId string `json:"parent_file_id"`
UpdatedAt time.Time `json:"updated_at"`
Size int64 `json:"size"`
Thumbnail string `json:"thumbnail"`
Url string `json:"url"`
}
Click to show internal directories.
Click to hide internal directories.