p115

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2026 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DisplayQrcode

func DisplayQrcode(img []byte) error

func DisposeQrcode

func DisposeQrcode()

func LoadCookies

func LoadCookies() string

func NewOperationLimiter added in v0.2.0

func NewOperationLimiter(minMs, maxMs int) cloudfs.Limiter

NewOperationLimiter builds a CooldownLimiter from millisecond bounds. Returns nil if both values are zero (no limiting).

func SaveCookies

func SaveCookies(agent *elevengo.Agent)

func SetOption added in v0.1.3

func SetOption(opt Option)

Types

type Agent

type Agent struct {
	Agent         *elevengo.Agent
	StoreInstance *store.Store
}

func New

func New() (*Agent, error)

func NewAgent

func NewAgent(cookies string) (*Agent, error)

func NewAgentByConfig

func NewAgentByConfig() (*Agent, error)

func NewAgentByQrcode

func NewAgentByQrcode() (*Agent, error)

func QrcodeLogin

func QrcodeLogin() (*Agent, error)

func (*Agent) AddMagnetTask

func (ag *Agent) AddMagnetTask(magnets []string, cid string, savepath string)

func (*Agent) AddRssUrlTask

func (ag *Agent) AddRssUrlTask(url string)

func (*Agent) ExecuteAllRssTask

func (ag *Agent) ExecuteAllRssTask()

func (*Agent) FileSystem added in v0.2.0

func (ag *Agent) FileSystem() cloudfs.Driver

FileSystem returns a cloudfs.Driver for this agent using default options.

func (*Agent) FileSystemWithOption added in v0.2.0

func (ag *Agent) FileSystemWithOption(opt FileSystemOption) cloudfs.Driver

FileSystemWithOption returns a cloudfs.Driver configured with the given options.

func (*Agent) OfflineClear added in v0.1.4

func (ag *Agent) OfflineClear(num int) (err error)

type FileSystem added in v0.2.0

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

func NewFileSystem added in v0.2.0

func NewFileSystem(agent *elevengo.Agent) *FileSystem

NewFileSystem creates a FileSystem with default options.

func NewFileSystemWithOption added in v0.2.0

func NewFileSystemWithOption(agent *elevengo.Agent, opt FileSystemOption) *FileSystem

NewFileSystemWithOption creates a FileSystem with the given options.

func (*FileSystem) Copy added in v0.2.0

func (fs *FileSystem) Copy(_ context.Context, targetDirID, entryID string) error

func (*FileSystem) Delete added in v0.2.0

func (fs *FileSystem) Delete(_ context.Context, entryID string) error

func (*FileSystem) List added in v0.2.0

func (fs *FileSystem) List(ctx context.Context, dirID string) ([]cloudfs.Entry, error)

func (*FileSystem) Lookup added in v0.2.0

func (fs *FileSystem) Lookup(ctx context.Context, parentID, name string) (cloudfs.Entry, error)

func (*FileSystem) Mkdir added in v0.2.0

func (fs *FileSystem) Mkdir(ctx context.Context, parentID, name string) (cloudfs.Entry, error)

func (*FileSystem) Move added in v0.2.0

func (fs *FileSystem) Move(ctx context.Context, targetDirID, entryID string) (cloudfs.Entry, error)

func (*FileSystem) Provider added in v0.2.0

func (fs *FileSystem) Provider() string

func (*FileSystem) Rename added in v0.2.0

func (fs *FileSystem) Rename(ctx context.Context, entryID, newName string) (cloudfs.Entry, error)

func (*FileSystem) Root added in v0.2.0

func (fs *FileSystem) Root(_ context.Context) (cloudfs.Entry, error)

func (*FileSystem) Search added in v0.2.0

func (fs *FileSystem) Search(_ context.Context, dirID, keyword string, opts cloudfs.SearchOptions) ([]cloudfs.Entry, error)

func (*FileSystem) Stat added in v0.2.0

func (fs *FileSystem) Stat(ctx context.Context, entryID string) (cloudfs.Entry, error)

type FileSystemOption added in v0.2.0

type FileSystemOption struct {
	// RootID overrides the logical root directory (default "0").
	RootID string
	// PageSize is a hint for list page size.
	// Note: elevengo does not expose per-call page size control; this field is
	// reserved for future use or a lower-level workaround.
	PageSize int
	// OperationLimiter is an optional rate limiter applied at the operation layer.
	OperationLimiter cloudfs.Limiter
}

FileSystemOption holds provider-level configuration for FileSystem.

type Option added in v0.1.3

type Option struct {
	DisableCache  bool
	ChunkDelay    int
	ChunkSize     int
	CooldownMinMs int
	CooldownMaxMs int
}

Jump to

Keyboard shortcuts

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