${header}

meteor.dht
Interface DHTService

All Superinterfaces:
net.jxta.platform.Module, net.jxta.service.Service
All Known Subinterfaces:
CANService, ChordService
All Known Implementing Classes:
CANServiceImpl, ChordServiceImpl

public interface DHTService
extends net.jxta.service.Service

The interface defining the DHT Service The fundamental operations of the DHT are to define an indexing space and provide a mechanism to locate and route to an identifier. There are currently two types of DHT implemented: A ring-based algorithm (inspired by MIT's CHORD) A mesh-based algorithm (inspired by the Content-Addressable Network)

Author:
Vincent Matossian December 2003

Field Summary
 
Fields inherited from interface net.jxta.platform.Module
START_AGAIN_PROGRESS, START_AGAIN_STALLED, START_OK
 
Method Summary
 void bootstrap(java.lang.String pid)
          Start the discovery for bootstrap
 void get(java.lang.String key)
          Get an object from the Hashtable
 java.math.BigInteger getNodeID(java.lang.String id)
          Hashes the JXTA peer id into an overlay node id
 java.math.BigInteger getTopologySize()
          Returns the size of the topoloy as an Integer In the case of a ring, the size of the ring, In the case of a mesh, the width ot th mesh
 void join(java.lang.String nodeID)
          JOIN Protocol
 void lookup(java.math.BigInteger target, int owner, int mode)
          Lookup the node handling an identifier
 void put(java.lang.String key, java.lang.String value)
          Put an Object in the Hashtable
 void setTopologySize(int size)
          Sets the size of the topology
 
Methods inherited from interface net.jxta.service.Service
getImplAdvertisement, getInterface
 
Methods inherited from interface net.jxta.platform.Module
init, startApp, stopApp
 

Method Detail

setTopologySize

public void setTopologySize(int size)
Sets the size of the topology


getTopologySize

public java.math.BigInteger getTopologySize()
Returns the size of the topoloy as an Integer In the case of a ring, the size of the ring, In the case of a mesh, the width ot th mesh


getNodeID

public java.math.BigInteger getNodeID(java.lang.String id)
Hashes the JXTA peer id into an overlay node id


bootstrap

public void bootstrap(java.lang.String pid)
Start the discovery for bootstrap


join

public void join(java.lang.String nodeID)
JOIN Protocol


lookup

public void lookup(java.math.BigInteger target,
                   int owner,
                   int mode)
Lookup the node handling an identifier


put

public void put(java.lang.String key,
                java.lang.String value)
Put an Object in the Hashtable


get

public void get(java.lang.String key)
Get an object from the Hashtable


${header}