| Package | Description |
|---|---|
| net.tomp2p.connection | |
| net.tomp2p.futures | |
| net.tomp2p.message | |
| net.tomp2p.p2p | |
| net.tomp2p.p2p.builder | |
| net.tomp2p.peers | |
| net.tomp2p.rpc |
| Modifier and Type | Method and Description |
|---|---|
PeerAddress |
PeerConnection.remotePeer() |
PeerAddress |
PeerBean.serverPeerAddress() |
| Modifier and Type | Method and Description |
|---|---|
InetSocketAddress |
RelaySender.createSocketTCP(PeerAddress peerAddress) |
InetSocketAddress |
RelaySender.createSocketUPD(PeerAddress peerAddress) |
PeerBean |
PeerBean.serverPeerAddress(PeerAddress serverPeerAddress) |
| Constructor and Description |
|---|
PeerConnection(PeerAddress remotePeer,
ChannelCreator cc,
int heartBeatMillis)
If we don't have an open TCP connection, we first need a channel creator to open a channel.
|
PeerConnection(PeerAddress remotePeer,
io.netty.channel.ChannelFuture channelFuture,
int heartBeatMillis)
If we already have an open TCP connection, we don't need a channel creator
|
| Modifier and Type | Method and Description |
|---|---|
PeerAddress |
FutureDiscover.discoverPeer() |
PeerAddress |
FutureDiscover.peerAddress()
The peerAddress where we are reachable.
|
PeerAddress |
FutureAsyncTask.remotePeer() |
PeerAddress |
FuturePing.remotePeer() |
PeerAddress |
FuturePeerConnection.remotePeer() |
PeerAddress |
FutureDiscover.reporter() |
| Modifier and Type | Method and Description |
|---|---|
Collection<PeerAddress> |
FutureBootstrap.bootstrapTo()
Returns the Peers we bootstrapped in no particular order.
|
Collection<PeerAddress> |
FutureWrappedBootstrap.bootstrapTo()
Returns a list of of peers that were involved in the bootstrapping.
|
NavigableSet<PeerAddress> |
FutureRouting.directHits()
The direct hits set contains those peers that reported to have the key
(Number160) we were looking for.
|
SortedMap<PeerAddress,DigestInfo> |
FutureRouting.directHitsDigest()
The direct hits map contains those peers that reported to have the key
(Number160) we were looking for including its digest (size of the result
set and its xored hashes).
|
Set<PeerAddress> |
FutureTracker.directTrackers() |
Set<PeerAddress> |
FutureTracker.peersOnTracker() |
NavigableSet<PeerAddress> |
FutureRouting.potentialHits()
The potential hits set contains those peers that are in the direct hit
and that did report to *not* have the key (Number160) we were looking
for.
|
Set<PeerAddress> |
FutureTracker.potentialTrackers() |
Map<PeerAddress,Map<Number160,Data>> |
FutureTask.rawDataMap() |
Map<PeerAddress,TrackerData> |
FutureTracker.rawPeersOnTracker() |
SortedSet<PeerAddress> |
FutureRouting.routingPath()
Returns the peers that have been asked to provide neighbor information.
|
| Modifier and Type | Method and Description |
|---|---|
FutureDiscover |
FutureDiscover.discoverPeer(PeerAddress discoverPeer) |
FuturePing |
FuturePing.done(PeerAddress remotePeer)
Gets called if the ping was a success and an other peer could ping us
with TCP and UDP.
|
void |
FutureDiscover.done(PeerAddress ourPeerAddress,
PeerAddress reporter)
Gets called if the discovery was a success and an other peer could ping us with TCP and UDP.
|
FutureDiscover |
FutureDiscover.failed(PeerAddress serverPeerAddress,
String failed) |
void |
FutureDiscover.timeout(PeerAddress serverPeerAddress,
ScheduledExecutorService timer,
int delaySec)
Creates a new future object and creates a timer that fires failed after a timeout.
|
| Modifier and Type | Method and Description |
|---|---|
void |
FutureWrappedBootstrap.bootstrapTo(Collection<PeerAddress> bootstrapTo)
The addresses we boostrap to.
|
void |
FutureRouting.neighbors(SortedMap<PeerAddress,DigestInfo> directHits,
NavigableSet<PeerAddress> potentialHits,
SortedSet<PeerAddress> routingPath,
boolean isBootstrap,
boolean isRoutingToOther)
Sets the result of the routing process and finishes the future.
|
void |
FutureRouting.neighbors(SortedMap<PeerAddress,DigestInfo> directHits,
NavigableSet<PeerAddress> potentialHits,
SortedSet<PeerAddress> routingPath,
boolean isBootstrap,
boolean isRoutingToOther)
Sets the result of the routing process and finishes the future.
|
void |
FutureRouting.neighbors(SortedMap<PeerAddress,DigestInfo> directHits,
NavigableSet<PeerAddress> potentialHits,
SortedSet<PeerAddress> routingPath,
boolean isBootstrap,
boolean isRoutingToOther)
Sets the result of the routing process and finishes the future.
|
void |
FutureTracker.trackers(Set<PeerAddress> potentialTrackers,
Set<PeerAddress> directTrackers,
Map<PeerAddress,TrackerData> peersOnTracker)
Set the result of the tracker process.
|
void |
FutureTracker.trackers(Set<PeerAddress> potentialTrackers,
Set<PeerAddress> directTrackers,
Map<PeerAddress,TrackerData> peersOnTracker)
Set the result of the tracker process.
|
void |
FutureTracker.trackers(Set<PeerAddress> potentialTrackers,
Set<PeerAddress> directTrackers,
Map<PeerAddress,TrackerData> peersOnTracker)
Set the result of the tracker process.
|
| Constructor and Description |
|---|
FutureAsyncTask(PeerAddress remotePeer)
Constructor
|
FuturePeerConnection(PeerAddress remotePeer) |
| Modifier and Type | Field and Description |
|---|---|
static io.netty.util.AttributeKey<PeerAddress> |
Decoder.PEER_ADDRESS_KEY |
| Modifier and Type | Method and Description |
|---|---|
PeerAddress |
MessageID.peerAddress() |
PeerAddress |
Message.recipient()
The ID of the recipient.
|
PeerAddress |
Message.sender()
The ID of the sender.
|
| Modifier and Type | Method and Description |
|---|---|
Collection<PeerAddress> |
NeighborSet.neighbors() |
| Modifier and Type | Method and Description |
|---|---|
void |
NeighborSet.add(PeerAddress neighbor) |
Message |
Message.recipient(PeerAddress recipient)
Set the ID of the recipient.
|
Message |
Message.sender(PeerAddress sender)
The ID of the sender.
|
| Modifier and Type | Method and Description |
|---|---|
void |
NeighborSet.addResult(Collection<PeerAddress> neighbors) |
| Constructor and Description |
|---|
NeighborSet(int neighborLimit,
Collection<PeerAddress> neighbors) |
| Modifier and Type | Method and Description |
|---|---|
PeerAddress |
Peer.peerAddress() |
PeerAddress |
RoutingMechanism.pollFirstInQueueToAsk() |
PeerAddress |
RoutingMechanism.pollRandomInQueueToAsk(Random rnd) |
| Modifier and Type | Method and Description |
|---|---|
SortedSet<PeerAddress> |
RoutingMechanism.alreadyAsked() |
SortedMap<PeerAddress,DigestInfo> |
RoutingMechanism.directHits() |
NavigableSet<PeerAddress> |
RoutingMechanism.potentialHits() |
NavigableSet<PeerAddress> |
RoutingMechanism.queueToAsk() |
| Modifier and Type | Method and Description |
|---|---|
void |
RoutingMechanism.addPotentialHits(PeerAddress remotePeer) |
void |
RoutingMechanism.addToAlreadyAsked(PeerAddress next) |
void |
PeerReceivedBroadcastPing.broadcastPingReceived(PeerAddress sender)
Call this method when we receive a broadcast ping.
|
FuturePeerConnection |
Peer.createPeerConnection(PeerAddress destination) |
FuturePeerConnection |
Peer.createPeerConnection(PeerAddress destination,
int heartBeatMillis)
Opens a TCP connection and keeps it open.
|
boolean |
RoutingMechanism.evaluateSuccess(PeerAddress remotePeer,
DigestInfo digestBean,
Collection<PeerAddress> newNeighbors,
boolean last,
Number160 locationkey) |
void |
ResponsibilityListener.meResponsible(Number160 locationKey,
PeerAddress newPeer) |
void |
ResponsibilityListener.otherResponsible(Number160 locationKey,
PeerAddress other)
Here an other peer is responsible and we need to transfer data.
|
void |
PeerReachable.peerWellConnected(PeerAddress peerAddress,
PeerAddress reporter,
boolean tcp)
Call this method when other peers can reach our peer from outside.
|
SendDirectBuilder |
Peer.sendDirect(PeerAddress recipientAddress) |
| Modifier and Type | Method and Description |
|---|---|
PeerAddress |
PingBuilder.getPeerAddress() |
PeerAddress |
BootstrapBuilder.peerAddress() |
PeerAddress |
DiscoverBuilder.peerAddress() |
PeerAddress |
SendDirectBuilder.recipient() |
PeerAddress |
BroadcastBuilder.remotePeer() |
| Modifier and Type | Method and Description |
|---|---|
Collection<PeerAddress> |
BootstrapBuilder.bootstrapTo() |
| Modifier and Type | Method and Description |
|---|---|
PingBuilder |
PingBuilder.peerAddress(PeerAddress peerAddress) |
BootstrapBuilder |
BootstrapBuilder.peerAddress(PeerAddress peerAddress)
Set the peer address to bootstrap to.
|
DiscoverBuilder |
DiscoverBuilder.peerAddress(PeerAddress peerAddress) |
| Modifier and Type | Method and Description |
|---|---|
BootstrapBuilder |
BootstrapBuilder.bootstrapTo(Collection<PeerAddress> bootstrapTo) |
| Constructor and Description |
|---|
SendDirectBuilder(Peer peer,
PeerAddress recipientAddress) |
| Modifier and Type | Method and Description |
|---|---|
PeerAddress |
PeerAddress.changeAddress(InetAddress inetAddress)
Create a new PeerAddress and change the InetAddress.
|
PeerAddress |
PeerAddress.changeFirewalledTCP(boolean firewalledTCP)
Create a new PeerAddress and change the firewalledTCP status.
|
PeerAddress |
PeerAddress.changeFirewalledUDP(boolean firewalledUDP)
Create a new PeerAddress and change the firewallUDP status.
|
PeerAddress |
PeerAddress.changePeerId(Number160 peerId)
Create a new PeerAddress and change the peer id.
|
PeerAddress |
PeerAddress.changePeerSocketAddress(PeerSocketAddress peerSocketAddress) |
PeerAddress |
PeerAddress.changePeerSocketAddresses(Collection<PeerSocketAddress> peerSocketAddresses) |
PeerAddress |
PeerAddress.changePorts(int tcpPort,
int udpPort)
Create a new PeerAddress and change the TCP and UDP ports.
|
PeerAddress |
PeerAddress.changeRelayed(boolean isRelayed)
Create a new PeerAddress and change the relayed status.
|
PeerAddress |
PeerMap.find(Number160 peerId) |
PeerAddress |
PeerStatatistic.peerAddress() |
PeerAddress |
PeerStatatistic.peerAddress(PeerAddress peerAddress)
Set the peer address only if the previous peer address that had the same peer ID.
|
| Modifier and Type | Method and Description |
|---|---|
List<PeerAddress> |
PeerMap.all()
Return all addresses from the neighbor list.
|
List<PeerAddress> |
PeerMap.allOverflow()
Return all addresses from the overflow / non-verified list.
|
NavigableSet<PeerAddress> |
PeerMap.closePeers(int atLeast)
Returns close peers to the peer itself.
|
NavigableSet<PeerAddress> |
PeerMap.closePeers(Number160 id,
int atLeast)
Returns close peer from the set to a given key.
|
static NavigableSet<PeerAddress> |
PeerMap.closePeers(Number160 self,
Number160 other,
int atLeast,
List<Map<Number160,PeerStatatistic>> peerMap) |
Comparator<PeerAddress> |
PeerMap.createComparator()
Creates an XOR comparator based on this peer ID.
|
static Comparator<PeerAddress> |
PeerMap.createComparator(Number160 id)
Create the Kademlia distance comparator.
|
| Modifier and Type | Method and Description |
|---|---|
int |
PeerAddress.compareTo(PeerAddress nodeAddress) |
boolean |
PeerMap.contains(PeerAddress peerAddress)
Checks if a peer address in either in the verified map.
|
boolean |
PeerMap.containsOverflow(PeerAddress peerAddress)
Checks if a peer address in either in the overflow / non-verified map.
|
static int |
PeerMap.isCloser(Number160 id,
PeerAddress rn,
PeerAddress rn2)
Returns -1 if the first remote node is closer to the key, if the second is closer, then 1 is returned.
|
static int |
PeerMap.isKadCloser(Number160 id,
PeerAddress rn,
PeerAddress rn2)
Returns -1 if the first remote node is closer to the key, if the secondBITS is closer, then 1 is returned.
|
boolean |
PeerMap.isPeerRemovedTemporarly(PeerAddress peerAddress)
Checks if a peer is in the offline map.
|
PeerAddress |
PeerStatatistic.peerAddress(PeerAddress peerAddress)
Set the peer address only if the previous peer address that had the same peer ID.
|
boolean |
PeerMap.peerFailed(PeerAddress remotePeer,
PeerStatusListener.FailReason reason)
Remove a peer from the list.
|
boolean |
PeerStatusListener.peerFailed(PeerAddress remotePeer,
PeerStatusListener.FailReason reason)
Called if the peer does not send answer in time.
|
boolean |
PeerMap.peerFound(PeerAddress remotePeer,
PeerAddress referrer)
Adds a neighbor to the neighbor list.
|
boolean |
PeerStatusListener.peerFound(PeerAddress remotePeer,
PeerAddress referrer)
Called if the peer is online and who reported it.
|
void |
PeerMapChangeListener.peerInserted(PeerAddress peerAddress,
boolean verified)
This method is called if a peer is added to the map.
|
void |
PeerMapChangeListener.peerRemoved(PeerAddress peerAddress,
PeerStatatistic storedPeerAddress)
This method is called if a peer is removed from the map.
|
void |
PeerMapChangeListener.peerUpdated(PeerAddress peerAddress,
PeerStatatistic storedPeerAddress)
This method is called if a peer is updated.
|
boolean |
DefaultPeerFilter.reject(PeerAddress peerAddress,
Collection<PeerAddress> all,
Number160 target) |
boolean |
PeerIPFilter.reject(PeerAddress peerAddress,
Collection<PeerAddress> all,
Number160 target) |
boolean |
PeerFilter.reject(PeerAddress peerAddress,
Collection<PeerAddress> all,
Number160 target)
Each peer that is added in the map runs through this filter.
|
boolean |
PeerStatRoutingFilter.reject(PeerAddress peerAddress,
Collection<PeerAddress> all,
Number160 target) |
| Constructor and Description |
|---|
PeerStatatistic(PeerAddress peerAddress)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected Collection<PeerAddress> |
NeighborRPC.getNeighbors(Number160 id,
int atLeast)
TODO: explain why protected method here.
|
| Modifier and Type | Method and Description |
|---|---|
FutureResponse |
NeighborRPC.closeNeighbors(PeerAddress remotePeer,
NeighborRPC.SearchValues searchValues,
Message.Type type,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Requests close neighbors from the remote peer.
|
Message |
DispatchHandler.createMessage(PeerAddress recipient,
byte name,
Message.Type type)
Create a request message and fills it with connection bean and peer bean parameters.
|
static Message |
DispatchHandler.createResponseMessage(Message requestMessage,
Message.Type replyType,
PeerAddress peerAddress) |
FutureResponse |
PingRPC.fireTCP(PeerAddress remotePeer,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Ping a TCP peer, but don't expect an answer.
|
FutureResponse |
PingRPC.fireUDP(PeerAddress remotePeer,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Ping a UDP peer, but don't expect an answer.
|
RequestHandler<FutureResponse> |
PingRPC.ping(PeerAddress remotePeer,
ConnectionConfiguration configuration)
Ping with UDP or TCP, but do not send yet.
|
FutureResponse |
PingRPC.pingBroadcastUDP(PeerAddress remotePeer,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Ping a UDP peer using layer 2 broadcast.
|
FutureResponse |
PingRPC.pingTCP(PeerAddress remotePeer,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Ping a TCP peer.
|
FutureResponse |
PingRPC.pingTCPDiscover(PeerAddress remotePeer,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Ping a TCP peer, and find out how the other peer sees us.
|
FutureResponse |
PingRPC.pingTCPProbe(PeerAddress remotePeer,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Ping a TCP peer, and request the other peer to ping us on our public address with a fire and forget message.
|
FutureResponse |
PingRPC.pingUDP(PeerAddress remotePeer,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Ping a UDP peer.
|
FutureResponse |
PingRPC.pingUDPDiscover(PeerAddress remotePeer,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Ping a UDP peer, and find out how the other peer sees us.
|
FutureResponse |
PingRPC.pingUDPProbe(PeerAddress remotePeer,
ChannelCreator channelCreator,
ConnectionConfiguration configuration)
Ping a UDP peer, and request the other peer to ping us on our public address with a fire and forget message.
|
FutureResponse |
QuitRPC.quit(PeerAddress remotePeer,
ShutdownBuilder shutdownBuilder,
ChannelCreator channelCreator)
Sends a message that indicates this peer is about to quit.
|
Buffer |
RawDataReply.reply(PeerAddress sender,
Buffer requestBuffer,
boolean complete)
Replies to a direct message from a peer.
|
Object |
ObjectDataReply.reply(PeerAddress sender,
Object request)
Replies to a direct message from a peer.
|
FutureResponse |
BroadcastRPC.send(PeerAddress remotePeer,
BroadcastBuilder broadcastBuilder,
ChannelCreator channelCreator,
ConnectionConfiguration configuration) |
FutureResponse |
DirectDataRPC.send(PeerAddress remotePeer,
SendDirectBuilderI sendDirectBuilder,
ChannelCreator channelCreator) |
RequestHandler<FutureResponse> |
DirectDataRPC.sendInternal(PeerAddress remotePeer,
SendDirectBuilderI sendDirectBuilder)
Send data directly to a peer.
|
Copyright © 2014. All rights reserved.