uk.ac.ic.doc.automed.p2p.overlay
Class EnhancedDHTFactory

java.lang.Object
  extended by ow.dht.DHTFactory
      extended by uk.ac.ic.doc.automed.p2p.overlay.EnhancedDHTFactory

public class EnhancedDHTFactory
extends ow.dht.DHTFactory

EnhancedDHTFactory.java

Author:
Duc M Le dmle@doc.ic.ac.uk
Created on August 20, 2006
Department of Computing, Imperial College

Constructor Summary
EnhancedDHTFactory()
           
 
Method Summary
static ow.dht.DHT getDHT(ow.dht.DHTConfiguration config)
          Returns an instance of DHT.
static ow.dht.DHT getDHT(ow.dht.DHTConfiguration config, ow.id.ID selfID)
          Returns an instance of DHT.
static ow.dht.DHT getDHT(ow.dht.DHTConfiguration config, ow.routing.RoutingService routingSvc)
          Returns an instance of DHT.
static ow.dht.DHT getDHT(short applicationID, short applicationVersion, ow.dht.DHTConfiguration config)
          Returns an instance of DHT.
static ow.dht.DHT getDHT(short applicationID, short applicationVersion, ow.dht.DHTConfiguration config, ow.id.ID selfID)
          Returns an instance of DHT.
 
Methods inherited from class ow.dht.DHTFactory
getDefaultConfiguration
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EnhancedDHTFactory

public EnhancedDHTFactory()
Method Detail

getDHT

public static ow.dht.DHT getDHT(ow.dht.DHTConfiguration config)
                         throws java.lang.Exception
Returns an instance of DHT. ID of this instance is determined consistently based on the hostname. Note that the working directory specified in the DHTConfiguration is created.

Throws:
java.lang.Exception

getDHT

public static ow.dht.DHT getDHT(ow.dht.DHTConfiguration config,
                                ow.id.ID selfID)
                         throws java.lang.Exception
Returns an instance of DHT. Note that the working directory specified in the DHTConfiguration is created.

Throws:
java.lang.Exception

getDHT

public static ow.dht.DHT getDHT(short applicationID,
                                short applicationVersion,
                                ow.dht.DHTConfiguration config)
                         throws java.lang.Exception
Returns an instance of DHT. ID of this instance is determined consistently based on the hostname. Note that the working directory specified in the DHTConfiguration is created.

Parameters:
applicationID - ID of application embedded in a message signature to avoid cross-talk between different applications.
Throws:
java.lang.Exception

getDHT

public static ow.dht.DHT getDHT(short applicationID,
                                short applicationVersion,
                                ow.dht.DHTConfiguration config,
                                ow.id.ID selfID)
                         throws java.lang.Exception
Returns an instance of DHT. Note that the working directory specified in the DHTConfiguration is created.

Parameters:
applicationID - ID of application embedded in a message signature to avoid cross-talk between different applications.
Throws:
java.lang.Exception

getDHT

public static ow.dht.DHT getDHT(ow.dht.DHTConfiguration config,
                                ow.routing.RoutingService routingSvc)
                         throws java.lang.Exception
Returns an instance of DHT. Note that the working directory specified in the DHTConfiguration is created.

Throws:
java.lang.Exception