|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.aelitis.azureus.core.networkmanager.impl.EntityHandler
public class EntityHandler
Manages transfer entities on behalf of peer connections. Each entity handler has a global pool which manages all connections by default. Connections can also be "upgraded" to a higher connection control level, i.e. each connection has its own specialized entity for performance purposes.
Constructor Summary | |
---|---|
EntityHandler(int type,
RateHandler rate_handler)
Create a new entity handler using the given rate handler. |
Method Summary | |
---|---|
void |
cancelPeerConnection(NetworkConnectionBase connection)
Remove a peer connection from the entity handler. |
void |
downgradePeerConnection(NetworkConnectionBase connection)
Downgrade (return) a peer connection back into the general pool. |
RateHandler |
getRateHandler(NetworkConnectionBase connection)
|
void |
registerPeerConnection(NetworkConnectionBase connection)
Register a peer connection for management by the handler. |
void |
upgradePeerConnection(NetworkConnectionBase connection,
RateHandler handler,
int partition_id)
Upgrade a peer connection from the general pool to its own high-speed entity. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public EntityHandler(int type, RateHandler rate_handler)
type
- read or write type handlerrate_handler
- global max rate handlerMethod Detail |
---|
public void registerPeerConnection(NetworkConnectionBase connection)
connection
- to add to the global poolpublic void cancelPeerConnection(NetworkConnectionBase connection)
connection
- to cancelpublic void upgradePeerConnection(NetworkConnectionBase connection, RateHandler handler, int partition_id)
connection
- to upgrade from global managementhandler
- individual connection rate handlerpublic void downgradePeerConnection(NetworkConnectionBase connection)
connection
- to downgrade back into the global entitypublic RateHandler getRateHandler(NetworkConnectionBase connection)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |