Documentation
¶
Index ¶
- type Provider
- func (p *Provider) AddTorrent(ctx context.Context, request apiexternal_v2.TorrentAddRequest) (*apiexternal_v2.TorrentAddResponse, error)
- func (p *Provider) GetHTTPClient() *http.Client
- func (p *Provider) GetProviderName() string
- func (p *Provider) GetProviderType() apiexternal_v2.DownloadProviderType
- func (p *Provider) GetStatus(ctx context.Context) (*apiexternal_v2.DownloadClientStatus, error)
- func (p *Provider) GetTorrentInfo(ctx context.Context, hash string) (*apiexternal_v2.TorrentInfo, error)
- func (p *Provider) ListTorrents(ctx context.Context, filter string) (*apiexternal_v2.TorrentListResponse, error)
- func (p *Provider) PauseTorrent(ctx context.Context, hash string) error
- func (p *Provider) RemoveTorrent(ctx context.Context, hash string, deleteFiles bool) error
- func (p *Provider) ResumeTorrent(ctx context.Context, hash string) error
- func (p *Provider) TestConnection(ctx context.Context) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Provider ¶
type Provider struct {
*base.BaseClient
// contains filtered or unexported fields
}
Provider implements the DownloadProvider interface for rTorrent.
func NewProvider ¶
func NewProvider( host string, port int, username, password string, useSSL bool, urlBase string, ) (*Provider, error)
NewProvider creates a new rTorrent download provider.
func (*Provider) AddTorrent ¶
func (p *Provider) AddTorrent( ctx context.Context, request apiexternal_v2.TorrentAddRequest, ) (*apiexternal_v2.TorrentAddResponse, error)
AddTorrent adds a torrent to rTorrent.
func (*Provider) GetHTTPClient ¶
GetHTTPClient returns an HTTP client for this provider.
func (*Provider) GetProviderName ¶
GetProviderName returns the provider name.
func (*Provider) GetProviderType ¶
func (p *Provider) GetProviderType() apiexternal_v2.DownloadProviderType
GetProviderType returns the download provider type.
func (*Provider) GetStatus ¶
func (p *Provider) GetStatus(ctx context.Context) (*apiexternal_v2.DownloadClientStatus, error)
GetStatus retrieves the download client status.
func (*Provider) GetTorrentInfo ¶
func (p *Provider) GetTorrentInfo( ctx context.Context, hash string, ) (*apiexternal_v2.TorrentInfo, error)
GetTorrentInfo retrieves information about a specific torrent.
func (*Provider) ListTorrents ¶
func (p *Provider) ListTorrents( ctx context.Context, filter string, ) (*apiexternal_v2.TorrentListResponse, error)
ListTorrents lists all torrents in rTorrent.
func (*Provider) PauseTorrent ¶
PauseTorrent pauses a torrent.
func (*Provider) RemoveTorrent ¶
RemoveTorrent removes a torrent from rTorrent.
func (*Provider) ResumeTorrent ¶
ResumeTorrent resumes a torrent.
Click to show internal directories.
Click to hide internal directories.