@Deprecated public abstract class AbstractPeerConnectionEventListener extends Object implements PeerConnectionEventListener
Constructor and Description |
---|
AbstractPeerConnectionEventListener()
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
void |
onPeerConnected(Peer peer,
int peerCount)
Deprecated.
Called when a peer is connected.
|
void |
onPeerDisconnected(Peer peer,
int peerCount)
Deprecated.
Called when a peer is disconnected.
|
void |
onPeersDiscovered(Set<PeerAddress> peerAddresses)
Deprecated.
Called when peers are discovered, this happens at startup of
PeerGroup or if we run out of
suitable Peer s to connect to. |
public AbstractPeerConnectionEventListener()
public void onPeersDiscovered(Set<PeerAddress> peerAddresses)
PeerDiscoveredEventListener
Called when peers are discovered, this happens at startup of PeerGroup
or if we run out of
suitable Peer
s to connect to.
onPeersDiscovered
in interface PeerDiscoveredEventListener
peerAddresses
- the set of discovered PeerAddress
espublic void onPeerConnected(Peer peer, int peerCount)
PeerConnectedEventListener
Peer
instead of a PeerGroup
,
peerCount will always be 1.onPeerConnected
in interface PeerConnectedEventListener
peerCount
- the total number of connected peerspublic void onPeerDisconnected(Peer peer, int peerCount)
PeerConnectionEventListener
PeerGroup
and the group is in the process of shutting down. If this listener is registered to a
Peer
instead of a PeerGroup
, peerCount will always be 0. This handler can be called without
a corresponding invocation of onPeerConnected if the initial connection is never successful.onPeerDisconnected
in interface PeerConnectionEventListener
onPeerDisconnected
in interface PeerDisconnectedEventListener
peerCount
- the total number of connected peersCopyright © 2016. All rights reserved.