Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Swarm ¶
type Swarm interface { // common methods IsMaster() bool Bootstrap() error // master methods GetConnectedWorkers() map[string]*SwarmWorker RequestTorrentsFromWorker(string) ([]*deluge.Torrent, error) RequestFreeSpaceFromWorker(string) (uint64, error) SaveTorrentFile(string, string, *[]byte) (int64, error) RemoveTorrent(string, string, string, ...bool) (uint64, uint64, error) ForceReannounce(string) error }
type SwarmWorker ¶
type SwarmWorker struct { Id string Version string sync.RWMutex FreeSpace uint64 ActiveTorrents []*deluge.Torrent }
func (*SwarmWorker) DecreaseFreeSpace ¶ added in v0.0.4
func (m *SwarmWorker) DecreaseFreeSpace(space uint64) bool
func (*SwarmWorker) GetFreeSpace ¶ added in v0.0.4
func (m *SwarmWorker) GetFreeSpace() (space uint64)
func (*SwarmWorker) HasEnoughSpace ¶ added in v0.0.4
func (m *SwarmWorker) HasEnoughSpace(space uint64) bool
Click to show internal directories.
Click to hide internal directories.