LimeWire Consolidated API

org.limewire.swarm.impl
Class AbstractSwarmCoordinator

java.lang.Object
  extended by org.limewire.swarm.impl.AbstractSwarmCoordinator
All Implemented Interfaces:
Closeable, SwarmCoordinator
Direct Known Subclasses:
BTSwarmCoordinator, FileCoordinatorImpl

public abstract class AbstractSwarmCoordinator
extends Object
implements SwarmCoordinator

Abstract Swarm Coordinator that will hold some common functionality accross Coordinators.


Constructor Summary
AbstractSwarmCoordinator()
           
 
Method Summary
 void addListener(SwarmCoordinatorListener swarmListener)
          Adds a listener for swarm completion.
protected  SwarmCoordinatorListenerList listeners()
          Returns the listeners for this coordinator.
 void removeListener(SwarmCoordinatorListener swarmListener)
          Removes a listener from this swarm coordinator.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.limewire.swarm.SwarmCoordinator
createWriteJob, getAmountLost, getAmountVerified, getSwarmFile, isComplete, leasePortion, leasePortion, pending, renewLease, reverify, unlease, unpending, verify, write, wrote
 
Methods inherited from interface java.io.Closeable
close
 

Constructor Detail

AbstractSwarmCoordinator

public AbstractSwarmCoordinator()
Method Detail

addListener

public void addListener(SwarmCoordinatorListener swarmListener)
Description copied from interface: SwarmCoordinator
Adds a listener for swarm completion. The listener will be notified when the file has completely been downloaded. If verification is not active, the listener will be notified once all ranges are written. If verification is active, the listener will be notified once all ranges are verified.

Specified by:
addListener in interface SwarmCoordinator

removeListener

public void removeListener(SwarmCoordinatorListener swarmListener)
Description copied from interface: SwarmCoordinator
Removes a listener from this swarm coordinator.

Specified by:
removeListener in interface SwarmCoordinator

listeners

protected SwarmCoordinatorListenerList listeners()
Returns the listeners for this coordinator.


LimeWire Consolidated API

Copyright © 2009. All Rights Reserved.