| Constructor and Description |
|---|
PeerMapConfiguration(Number160 self)
Constructor with reasonable defaults.
|
| Modifier and Type | Method and Description |
|---|---|
PeerMapConfiguration |
addPeerFilter(PeerFilter peerFilter) |
int |
bagSizeOverflow() |
PeerMapConfiguration |
bagSizeOverflow(int bagSizeOverflow) |
int |
bagSizeVerified() |
PeerMapConfiguration |
bagSizeVerified(int bagSizeVerified) |
int |
exceptionTimeout() |
PeerMapConfiguration |
exceptionTimeout(int exceptionTimeout) |
boolean |
isPeerVerification() |
Maintenance |
maintenance() |
PeerMapConfiguration |
maintenance(Maintenance maintenance) |
int |
offlineCount() |
PeerMapConfiguration |
offlineCount(int offlineCount) |
int |
offlineTimeout() |
PeerMapConfiguration |
offlineTimeout(int offlineTimeout) |
Collection<PeerFilter> |
peerFilters() |
PeerMapConfiguration |
peerNoVerification() |
PeerMapConfiguration |
peerVerification(boolean reerVerification) |
Number160 |
self() |
int |
shutdownTimeout() |
PeerMapConfiguration |
shutdownTimeout(int shutdownTimeout) |
public PeerMapConfiguration(Number160 self)
self - The peer ID of this peerpublic Number160 self()
public int bagSizeVerified()
public PeerMapConfiguration bagSizeVerified(int bagSizeVerified)
bagSizeVerified - Each distance bit has its own bag this is the size of the verified peers are know to be onlinepublic int bagSizeOverflow()
public PeerMapConfiguration bagSizeOverflow(int bagSizeOverflow)
bagSizeOverflow - Each distance bit has its own bag this is the size of the non-verified peers that may have been
reported by other peerspublic int offlineTimeout()
public PeerMapConfiguration offlineTimeout(int offlineTimeout)
offlineTimeout - The time a peer is considered offline in seconds. This is important, since we see that a peer is
offline and an other peer reports this peer, we don't want to add it into our map. Thus, there is a
map that keeps track of such peers. This also means that a fast reconnect is not possible and a peer
has to wait until the timeout to rejoinpublic int offlineCount()
public PeerMapConfiguration offlineCount(int offlineCount)
offlineCount - The number of times that the peer is not reachabel. After that the peer is considered offlinepublic Collection<PeerFilter> peerFilters()
public PeerMapConfiguration addPeerFilter(PeerFilter peerFilter)
peerFilter - This filter can be set to not accept certain peerspublic Maintenance maintenance()
public PeerMapConfiguration maintenance(Maintenance maintenance)
maintenance - The class that is responsible for maintenancepublic int shutdownTimeout()
public PeerMapConfiguration shutdownTimeout(int shutdownTimeout)
shutdownTimeout - The time a peer is considered offline (shutdown) in seconds. This is important, since we see that a peer is
offline and an other peer reports this peer, we don't want to add it into our map. Thus, there is a
map that keeps track of such peers. This also means that a fast reconnect is not possible and a peer
has to wait until the timeout to rejoinpublic int exceptionTimeout()
public PeerMapConfiguration exceptionTimeout(int exceptionTimeout)
exceptionTimeout - The time a peer is considered offline (exception) in seconds. This is important, since we see that a peer is
offline and an other peer reports this peer, we don't want to add it into our map. Thus, there is a
map that keeps track of such peers. This also means that a fast reconnect is not possible and a peer
has to wait until the timeout to rejoinpublic boolean isPeerVerification()
public PeerMapConfiguration peerNoVerification()
public PeerMapConfiguration peerVerification(boolean reerVerification)
Copyright © 2014. All rights reserved.