public interface IPeerConnectionPool
Modifier and Type | Method and Description |
---|---|
PeerConnection |
addConnectionIfAbsent(PeerConnection connection) |
void |
checkDuplicateConnections(TorrentId torrentId,
Peer peer) |
PeerConnection |
getConnection(ConnectionKey key) |
PeerConnection |
getConnection(Peer peer,
TorrentId torrentId) |
int |
size() |
void |
visitConnections(TorrentId torrentId,
Consumer<PeerConnection> visitor)
Visit connections for a given torrent ID.
|
PeerConnection getConnection(Peer peer, TorrentId torrentId)
PeerConnection getConnection(ConnectionKey key)
void visitConnections(TorrentId torrentId, Consumer<PeerConnection> visitor)
int size()
PeerConnection addConnectionIfAbsent(PeerConnection connection)
Copyright © 2016–2021. All rights reserved.