public interface ConnectionCache
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
Connection |
getConnectionTo(Router router,
boolean isDirectoryConnection)
Returns a completed connection to the specified router.
|
boolean |
isClosed() |
Connection getConnectionTo(Router router, boolean isDirectoryConnection) throws InterruptedException, ConnectionTimeoutException, ConnectionFailedException, ConnectionHandshakeException
router - The router to which a connection is requested.isDirectoryConnection - Is this going to be used as a directory connection.InterruptedException - if thread is interrupted while waiting for connection to complete.ConnectionTimeoutException - if timeout expires before connection completes.ConnectionFailedException - if connection fails due to I/O errorConnectionHandshakeException - if connection fails because an error occurred during handshake phasevoid close()
boolean isClosed()
Copyright © 2015. All rights reserved.