planet.util
Interface DHTProperties

All Superinterfaces:
java.io.Serializable
All Known Implementing Classes:
DHTProperties

public interface DHTProperties
extends java.io.Serializable

This interface allows to implement all the own properties of configuration of a generic DHT application layer. It establishes a single relationship, through the method init(), so that their values are initialized. For this reason, cast will have to be made in each place where it is necessary, to the concrete implementation.

Author:
Marc Sanchez Date: 12/08/2004

Method Summary
 void init(java.lang.String propertiesFile)
          Initialize correctly the generic DHT configuration properties.
 java.lang.String typeToString(int type)
          Returns a String representation of the constant specific values of type and mode of the RouteMessage.
 

Method Detail

init

public void init(java.lang.String propertiesFile)
          throws InitializationException
Initialize correctly the generic DHT configuration properties.

Parameters:
propertiesFile - File with all configuration properties of the concrete DHT. This file must follow java.util.Properties scheme.
Throws:
InitializationException - if an error occurs during the initialization of the different properties.

typeToString

public java.lang.String typeToString(int type)
Returns a String representation of the constant specific values of type and mode of the RouteMessage. Its use is only for human readable logs.

Parameters:
type - Value to get its String representation.
Returns:
The String representation of the type.