commands

package
v0.40.0 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetServices

func SetServices(s *Services)

Types

type BindingResolver

type BindingResolver interface {
	FindByChannelUser(ctx context.Context, channelType, channelUserID string) (uint, bool, error)
}

BindingResolver 用于 /unbind 命令解析自身 binding ID。

type DownloaderOption added in v0.35.0

type DownloaderOption struct {
	ID        uint
	Name      string
	IsDefault bool
}

type DownloaderStatusSource

type DownloaderStatusSource interface {
	GetAllDownloaderStatus() []downloader.DownloaderStatus
}

DownloaderStatusSource 抽象 *downloader.DownloaderManager.GetAllDownloaderStatus()。

type IDNameOption added in v0.35.0

type IDNameOption struct {
	ID   uint
	Name string
}

type RSSWizardService added in v0.35.0

type RSSWizardService interface {
	AppendRSSToSite(siteName string, entry models.RSSConfig) (models.RSSConfig, error)
	ListRSSForSite(siteName string) ([]models.RSSConfig, error)
	DeleteRSSFromSite(siteName string, rssID uint) (models.RSSConfig, error)
	ListDownloaders(ctx context.Context) ([]DownloaderOption, error)
	ListFilterRules(ctx context.Context) ([]IDNameOption, error)
	ListNotificationChannels(ctx context.Context) ([]IDNameOption, error)
}

type Services

type Services struct {
	Task       app.TaskService
	Torrent    app.TorrentService
	Site       app.SiteService
	Binding    app.BindingService
	Downloader DownloaderStatusSource
	RSSWizard  RSSWizardService
	Bindings   BindingResolver
	Sessions   chatops.SessionStoreAPI
}

Services 是 chatops 命令访问的业务依赖集合。

Jump to

Keyboard shortcuts

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