|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.aelitis.azureus.plugins.tracker.dht.DHTTrackerPlugin
public class DHTTrackerPlugin
Nested Class Summary | |
---|---|
protected static class |
DHTTrackerPlugin.putDetails
|
protected class |
DHTTrackerPlugin.RegistrationDetails
|
static class |
DHTTrackerPlugin.trackerTarget
|
static class |
DHTTrackerPlugin.TriangleSlicer
|
Field Summary | |
---|---|
static java.lang.Object |
DOWNLOAD_USER_DATA_I2P_SCRAPE_KEY
|
static int |
NUM_WANT
|
Fields inherited from interface org.gudy.azureus2.plugins.download.DownloadAttributeListener |
---|
WILL_BE_READ, WRITTEN |
Constructor Summary | |
---|---|
DHTTrackerPlugin()
|
Method Summary | |
---|---|
void |
addDownload(Download download)
|
void |
announceAll()
|
void |
announceResult(DownloadAnnounceResult result)
An announce result has been returned from the tracker |
void |
attributeEventOccurred(Download download,
TorrentAttribute attr,
int event_type)
This method will be called when an attribute event occurs. |
protected void |
checkDownloadForRegistration(Download download,
boolean first_time)
|
protected void |
configChanged()
|
protected void |
decreaseActive(Download dl)
|
protected long |
getDerivedTrackMetric(Download download)
|
TrackerPeerSource |
getTrackerPeerSource(Download download)
|
TrackerPeerSource[] |
getTrackerPeerSources(Torrent torrent)
|
protected void |
increaseActive(Download dl)
|
protected void |
initialise()
|
void |
initialize(PluginInterface _plugin_interface)
This method is called when the Plugin is loaded by Azureus |
protected boolean |
isActive(Download dl)
|
protected boolean |
isComplete(Download download)
|
boolean |
isRunning()
|
static void |
load(PluginInterface plugin_interface)
|
protected void |
notRunning()
|
void |
positionChanged(Download download,
int oldPosition,
int newPosition)
Position of download has changed. |
protected void |
processNonRegistrations()
|
protected void |
processRegistrations(boolean full_processing)
|
void |
removeDownload(Download download)
|
DownloadScrapeResult |
scrape(byte[] hash)
This is used by the dhtscraper plugin |
void |
scrapeResult(DownloadScrapeResult result)
A scrape result has been returned from a tracker |
void |
stateChanged(Download download,
int old_state,
int new_state)
The Download's state has changed. |
protected int |
trackerGet(Download download,
DHTTrackerPlugin.RegistrationDetails details,
boolean derived_only)
|
protected void |
trackerPut(Download download,
DHTTrackerPlugin.RegistrationDetails details)
|
protected void |
trackerRemove(Download download,
DHTTrackerPlugin.RegistrationDetails details)
|
protected void |
trackerRemove(Download download,
DHTTrackerPlugin.trackerTarget target)
|
void |
waitUntilInitialised()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static java.lang.Object DOWNLOAD_USER_DATA_I2P_SCRAPE_KEY
public static final int NUM_WANT
Constructor Detail |
---|
public DHTTrackerPlugin()
Method Detail |
---|
public static void load(PluginInterface plugin_interface)
public void initialize(PluginInterface _plugin_interface)
Plugin
initialize
in interface Plugin
_plugin_interface
- the interface that the plugin must use to communicate with Azureusprotected void notRunning()
protected void initialise()
public void waitUntilInitialised()
public boolean isRunning()
public void addDownload(Download download)
public void removeDownload(Download download)
public void attributeEventOccurred(Download download, TorrentAttribute attr, int event_type)
DownloadAttributeListener
attributeEventOccurred
in interface DownloadAttributeListener
download
- The download object involved.attr
- The attribute involved.event_type
- Either WRITTEN or WILL_BE_READ.public void scrapeResult(DownloadScrapeResult result)
DownloadTrackerListener
scrapeResult
in interface DownloadTrackerListener
result
- Information about the scrapepublic void announceResult(DownloadAnnounceResult result)
DownloadTrackerListener
announceResult
in interface DownloadTrackerListener
result
- Information about the announceprotected void checkDownloadForRegistration(Download download, boolean first_time)
protected void processRegistrations(boolean full_processing)
protected long getDerivedTrackMetric(Download download)
protected void trackerPut(Download download, DHTTrackerPlugin.RegistrationDetails details)
protected int trackerGet(Download download, DHTTrackerPlugin.RegistrationDetails details, boolean derived_only)
protected boolean isComplete(Download download)
protected void trackerRemove(Download download, DHTTrackerPlugin.RegistrationDetails details)
protected void trackerRemove(Download download, DHTTrackerPlugin.trackerTarget target)
protected void processNonRegistrations()
public void stateChanged(Download download, int old_state, int new_state)
DownloadListener
stateChanged
in interface DownloadListener
public void announceAll()
public void positionChanged(Download download, int oldPosition, int newPosition)
DownloadListener
positionChanged
in interface DownloadListener
download
- object in which the position has changedoldPosition
- position that the download used to be atnewPosition
- position that the download is now atprotected void configChanged()
public DownloadScrapeResult scrape(byte[] hash)
protected void increaseActive(Download dl)
protected void decreaseActive(Download dl)
protected boolean isActive(Download dl)
public TrackerPeerSource getTrackerPeerSource(Download download)
public TrackerPeerSource[] getTrackerPeerSources(Torrent torrent)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |