com.aelitis.azureus.plugins.extseed.impl.getright
Class ExternalSeedReaderGetRight

java.lang.Object
  extended by com.aelitis.azureus.plugins.extseed.impl.ExternalSeedReaderImpl
      extended by com.aelitis.azureus.plugins.extseed.impl.getright.ExternalSeedReaderGetRight
All Implemented Interfaces:
PiecePriorityProvider, ExternalSeedReader, PeerManagerListener2

public class ExternalSeedReaderGetRight
extends ExternalSeedReaderImpl
implements PiecePriorityProvider


Nested Class Summary
 
Nested classes/interfaces inherited from class com.aelitis.azureus.plugins.extseed.impl.ExternalSeedReaderImpl
ExternalSeedReaderImpl.MutableInteger
 
Field Summary
 
Fields inherited from class com.aelitis.azureus.plugins.extseed.impl.ExternalSeedReaderImpl
INITIAL_DELAY, RECONNECT_DEFAULT, STALLED_DOWNLOAD_SPEED, STALLED_PEER_SPEED, TOP_PIECE_PRIORITY
 
Constructor Summary
protected ExternalSeedReaderGetRight(ExternalSeedPlugin _plugin, Torrent _torrent, URL _url, Map _params)
           
 
Method Summary
 void calculatePriorityOffsets(PeerManager peer_manager, int[] base_priorities)
           
 String getName()
           
protected  int getPieceGroupSize()
           
 int getPort()
           
protected  boolean getRequestCanSpanPieces()
           
 String getType()
           
 URL getURL()
           
protected  void readData(ExternalSeedReaderRequest request)
           
protected  void readData(int start_piece_number, int start_piece_offset, int length, ExternalSeedHTTPDownloaderListener listener)
           
 boolean sameAs(ExternalSeedReader other)
           
protected  void setActiveSupport(PeerManager peer_manager, boolean active)
           
 long[] updatePriorities(PiecePicker picker)
           
 
Methods inherited from class com.aelitis.azureus.plugins.extseed.impl.ExternalSeedReaderImpl
addListener, addRequests, cancelAllRequests, cancelRequest, checkActivation, deactivate, eventOccurred, getBooleanParam, getExpiredRequests, getFailureCount, getIntParam, getIP, getLastFailTime, getMaximumNumberOfRequests, getOutgoingRequestCount, getOutgoingRequestedPieceNumbers, getPercentDoneOfCurrentIncomingRequest, getPermittedBytes, getPriorityOffsets, getRequestCount, getRequests, getStatus, getSystemTime, getTorrent, getUserAgent, informCancelled, informComplete, informFailed, isActive, isPermanentlyUnavailable, isTransient, log, processRequests, processRequests, read, readBytes, readyToActivate, readyToDeactivate, removeListener, reportBytesRead, selectRequests, setActive, setReconnectDelay
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExternalSeedReaderGetRight

protected ExternalSeedReaderGetRight(ExternalSeedPlugin _plugin,
                                     Torrent _torrent,
                                     URL _url,
                                     Map _params)
                              throws Exception
Throws:
Exception
Method Detail

sameAs

public boolean sameAs(ExternalSeedReader other)
Specified by:
sameAs in interface ExternalSeedReader

getName

public String getName()
Specified by:
getName in interface ExternalSeedReader

getType

public String getType()
Specified by:
getType in interface ExternalSeedReader

getURL

public URL getURL()
Specified by:
getURL in interface ExternalSeedReader

getPort

public int getPort()
Specified by:
getPort in interface ExternalSeedReader

getPieceGroupSize

protected int getPieceGroupSize()
Specified by:
getPieceGroupSize in class ExternalSeedReaderImpl

getRequestCanSpanPieces

protected boolean getRequestCanSpanPieces()
Specified by:
getRequestCanSpanPieces in class ExternalSeedReaderImpl

setActiveSupport

protected void setActiveSupport(PeerManager peer_manager,
                                boolean active)
Overrides:
setActiveSupport in class ExternalSeedReaderImpl

updatePriorities

public long[] updatePriorities(PiecePicker picker)
Specified by:
updatePriorities in interface PiecePriorityProvider

calculatePriorityOffsets

public void calculatePriorityOffsets(PeerManager peer_manager,
                                     int[] base_priorities)
Specified by:
calculatePriorityOffsets in interface ExternalSeedReader
Overrides:
calculatePriorityOffsets in class ExternalSeedReaderImpl

readData

protected void readData(ExternalSeedReaderRequest request)
                 throws ExternalSeedException
Overrides:
readData in class ExternalSeedReaderImpl
Throws:
ExternalSeedException

readData

protected void readData(int start_piece_number,
                        int start_piece_offset,
                        int length,
                        ExternalSeedHTTPDownloaderListener listener)
                 throws ExternalSeedException
Specified by:
readData in class ExternalSeedReaderImpl
Throws:
ExternalSeedException