Interface ITrackerManager
Assembly: MonoTorrent.dll
Syntax
public interface ITrackerManager
Properties
Private
Declaration
Property Value
| Type |
Description |
| System.Boolean |
|
Tiers
Declaration
IList<TrackerTier> Tiers { get; }
Property Value
| Type |
Description |
| System.Collections.Generic.IList<TrackerTier> |
|
Methods
AddTrackerAsync(ITracker)
Adds the tracker to a new TrackerTier.
Declaration
ReusableTask AddTrackerAsync(ITracker tracker)
Parameters
| Type |
Name |
Description |
| ITracker |
tracker |
The tracker to add
|
Returns
| Type |
Description |
| ReusableTasks.ReusableTask |
|
AddTrackerAsync(Uri)
Creates an ITracker instance for the given url and adds it to a
new TrackerTier.
Declaration
ReusableTask AddTrackerAsync(Uri trackerUri)
Parameters
| Type |
Name |
Description |
| System.Uri |
trackerUri |
|
Returns
| Type |
Description |
| ReusableTasks.ReusableTask |
|
AnnounceAsync(ITracker, CancellationToken)
Sends an Announce to the specified tracker using None
in order to fetch more peers. This will respect the Tracker's
MinUpdateInterval and UpdateInterval
to avoid announcing to frequently.
Declaration
ReusableTask AnnounceAsync(ITracker tracker, CancellationToken token)
Parameters
| Type |
Name |
Description |
| ITracker |
tracker |
The tracker to send the Announce to.
|
| System.Threading.CancellationToken |
token |
The token used to cancel the request
|
Returns
| Type |
Description |
| ReusableTasks.ReusableTask |
|
AnnounceAsync(TorrentEvent, CancellationToken)
Sends an announce with the specified event to each tier in Tiers.
If None is specified then the Tracker's
MinUpdateInterval and UpdateInterval
will be respected to avoid announcing too frequently. Otherwise this
is a special announce which will be sent regardless of the
usual update interval.
Declaration
ReusableTask AnnounceAsync(TorrentEvent clientEvent, CancellationToken token)
Parameters
| Type |
Name |
Description |
| TorrentEvent |
clientEvent |
The event to send with the announce.
|
| System.Threading.CancellationToken |
token |
The token used to cancel the request.
|
Returns
| Type |
Description |
| ReusableTasks.ReusableTask |
|
AnnounceAsync(CancellationToken)
Declaration
ReusableTask AnnounceAsync(CancellationToken token)
Parameters
| Type |
Name |
Description |
| System.Threading.CancellationToken |
token |
The token used to cancel the request
|
Returns
| Type |
Description |
| ReusableTasks.ReusableTask |
|
RemoveTrackerAsync(ITracker)
Removes the ITracker from the manager. If the TrackerTier it was part of is now empty
it will also be removed.
Declaration
ReusableTask<bool> RemoveTrackerAsync(ITracker tracker)
Parameters
Returns
| Type |
Description |
| ReusableTasks.ReusableTask<System.Boolean> |
|
ScrapeAsync(ITracker, CancellationToken)
Sends a Scrape to each TrackerTier. This will respect the MinUpdateInterval
for the Tracker to avoid scraping too frequently.
Declaration
ReusableTask ScrapeAsync(ITracker tracker, CancellationToken token)
Parameters
| Type |
Name |
Description |
| ITracker |
tracker |
Tje tracker to send the Scrape to.
|
| System.Threading.CancellationToken |
token |
The token used to cancel the request
|
Returns
| Type |
Description |
| ReusableTasks.ReusableTask |
|
ScrapeAsync(CancellationToken)
Sends a Scrape to each TrackerTier. This will respect the MinUpdateInterval
for the Tracker to avoid scraping too frequently
Declaration
ReusableTask ScrapeAsync(CancellationToken token)
Parameters
| Type |
Name |
Description |
| System.Threading.CancellationToken |
token |
The token used to cancel the request
|
Returns
| Type |
Description |
| ReusableTasks.ReusableTask |
|
Events
AnnounceComplete
Declaration
event EventHandler<AnnounceResponseEventArgs> AnnounceComplete
Event Type
ScrapeComplete
Declaration
event EventHandler<ScrapeResponseEventArgs> ScrapeComplete
Event Type