planet.generic.commonapi
Class GenericAppWithGML

java.lang.Object
  extended byplanet.generic.commonapi.GenericAppWithGML
Direct Known Subclasses:
GMLTopologyTest

public class GenericAppWithGML
extends java.lang.Object

This class only attemps to help to programmers make more simple the initialization of the required context of new applications. Are two ways to initialize the context:

One
The new application must extends this GenericApp and includes in theirs constructors the sentence super() or super(factoriesProperties,simProperties,kbrProperties). For example:

 public NewTest() throws InitializationException {
     super(factoriesProperties,simProperties,kbrProperties);
 
where parameters of super() constructor are the path to specified files.

Two
Includes theese lines before anything that make reference to the network and the simulator and ...
 Properties.init(factoriesProperties,simProperties,kbrProperties);
 GenericFactory.init();
 
where parameters of init() method are the path to specified files.

Author:
Jordi Pujol

Constructor Summary
GenericAppWithGML(java.lang.String factoriesProperties, java.lang.String simProperties, java.lang.String kbrProperties, java.lang.String gmlGraphicalProperties, java.lang.String gmlClassesProperties)
          Make required initialization on the context of the application.
GenericAppWithGML(java.lang.String factoriesProperties, java.lang.String simProperties, java.lang.String kbrProperties, java.lang.String dhtProperties, java.lang.String gmlGraphicalProperties, java.lang.String gmlClassesProperties)
          Make required initialization on the context of the application.
GenericAppWithGML(java.lang.String factoriesProperties, java.lang.String simProperties, java.lang.String kbrProperties, java.lang.String dhtProperties, java.lang.String behProperties, java.lang.String gmlGraphicalProperties, java.lang.String gmlClassesProperties)
          Make required initialization on the context of the application.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GenericAppWithGML

public GenericAppWithGML(java.lang.String factoriesProperties,
                         java.lang.String simProperties,
                         java.lang.String kbrProperties,
                         java.lang.String gmlGraphicalProperties,
                         java.lang.String gmlClassesProperties)
                  throws InitializationException
Make required initialization on the context of the application. In concrete:
 Properties.init(factoriesProperties,simProperties,kbrProperties);
 GenericFactory.init();
 
Because of theese lines, the new application must be executed under the implicitly specified directory by the parameters files.

Parameters:
factoriesProperties - Path to properties file of factories attributes.
simProperties - Path to properties file of simulator attributes.
kbrProperties - Path to properties file of chord attributes.
gmlGraphicalProperties - Path to properties file of graphical attributes.
gmlClassesProperties - Path to properties file of classes definition.
Throws:
InitializationException - if any error has occurred during initialization of the context.

GenericAppWithGML

public GenericAppWithGML(java.lang.String factoriesProperties,
                         java.lang.String simProperties,
                         java.lang.String kbrProperties,
                         java.lang.String dhtProperties,
                         java.lang.String gmlGraphicalProperties,
                         java.lang.String gmlClassesProperties)
                  throws InitializationException
Make required initialization on the context of the application. In concrete:
 Properties.init(factoriesProperties,simProperties,chordProperties);
 GenericFactory.init();
 
Because of theese lines, the new application must be executed under the implicitly specified directory by the parameters files.

Parameters:
factoriesProperties - Path to properties file of factories attributes.
simProperties - Path to properties file of simulator attributes.
kbrProperties - Path to properties file of kbr attributes.
dhtProperties - Path to properties file of dht attributes.
gmlGraphicalProperties - Path to properties file of graphical attributes.
gmlClassesProperties - Path to properties file of classes definition.
Throws:
InitializationException - if any error has occurred during initialization of the context.

GenericAppWithGML

public GenericAppWithGML(java.lang.String factoriesProperties,
                         java.lang.String simProperties,
                         java.lang.String kbrProperties,
                         java.lang.String dhtProperties,
                         java.lang.String behProperties,
                         java.lang.String gmlGraphicalProperties,
                         java.lang.String gmlClassesProperties)
                  throws InitializationException
Make required initialization on the context of the application. In concrete:
 Properties.init(factoriesProperties,simProperties,chordProperties);
 GenericFactory.init();
 
Because of theese lines, the new application must be executed under the implicitly specified directory by the parameters files.

Parameters:
factoriesProperties - Path to properties file of factories attributes.
simProperties - Path to properties file of simulator attributes.
kbrProperties - Path to properties file of kbr attributes.
dhtProperties - Path to properties file of dht attributes.
behProperties - Paht to properties file of behaviours attributes
gmlGraphicalProperties - Path to properties file of graphical attributes.
gmlClassesProperties - Path to properties file of classes definition.
Throws:
InitializationException - if any error has occurred during initialization of the context.