Packages that use NID
Package
Description
BitTorrent distributed hash table (DHT) implementation following the Mainline protocol, for trackerless peer discovery.
Uses of NID in org.klomp.snark.dht
Classes in org.klomp.snark.dht that implement interfaces with type arguments of type NIDModifier and TypeClassDescription(package private) classKademlia bucket trimmer for DHT node management.Fields in org.klomp.snark.dht declared as NIDModifier and TypeFieldDescriptionprivate final NIDKRPC._myNID20 byte random id.static final NIDKRPC.FAKE_NIDAll-zero NID used for pings.private final NIDNodeInfo.nIDThe node's DHT id.Fields in org.klomp.snark.dht with type parameters of type NIDModifier and TypeFieldDescriptionKRPC._blacklistRecently unreachable, with lastSeen() as the added-to-blacklist time.private final ConcurrentHashMap<NID, Token> KRPC._incomingTokensIndex to incoming opaque tokens, received in a peers or nodes reply.private final KBucketSet<NID> DHTNodes._kadThe Kademlia buckets of the known nodes.private final ConcurrentHashMap<NID, NodeInfo> DHTNodes._nodeMapThe known nodes, by node id.Methods in org.klomp.snark.dht that return NIDModifier and TypeMethodDescriptionstatic NIDNodeInfo.generateNID(Hash h, int p, RandomSource random) Generate a secure NID that matches the Hash and port.NodeInfo.getNID()The node ID.Methods in org.klomp.snark.dht that return types with arguments of type NIDModifier and TypeMethodDescriptionDHTNodes.getExploreKeys()Random keys to explore for DHT maintenance.Methods in org.klomp.snark.dht with parameters of type NIDModifier and TypeMethodDescriptionprivate voidBootstrapping or background thread.The node with the given ID.private voidKRPC.receiveFindNode(MsgID msgID, NodeInfo nInfo, NID tID) Handle and respond to the query.Remove a node by its ID.private KRPC.ReplyWaiterKRPC.sendFindNode(NodeInfo nInfo, NID tID) Send a find_node query to a node, on the query port.booleanAttempts to trim a Kademlia bucket to make room for a new node.Method parameters in org.klomp.snark.dht with type arguments of type NIDModifier and TypeMethodDescriptionbooleanAttempts to trim a Kademlia bucket to make room for a new node.Constructors in org.klomp.snark.dht with parameters of type NIDModifierConstructorDescriptionDHTNodes(I2PAppContext ctx, NID me) Create a new DHTNodes instance.NodeInfo(NID nID, Destination dest, int port) Use this if we have the full destination.No Destination yet available.Creates a new token key by combining a node ID with an info hash.