cdx.scorebot.net.tests
Class Configuration

java.lang.Object
  extended by cdx.scorebot.net.tests.Configuration

public class Configuration
extends java.lang.Object

Describes a configuration and defines method for getting that configuration in various forms.

Author:
David Underhill

Constructor Summary
Configuration()
          this default constructor instantiates an empty configuration
Configuration(java.util.HashMap<java.lang.String,ConfigOption> config)
          instantiates a configuration with the specified options
 
Method Summary
 boolean equals(java.lang.Object o)
           
 java.util.Vector<java.lang.String> getOptionNames()
          gets a vector which holds the configuration option names (in alphabetical order)
 java.util.HashMap<java.lang.String,ConfigOption> getOptions()
          gets the configuration of the test which generated this event
 java.util.Vector<ConfigOption> getOptionsWithNames()
          gets a vector which holds the configuration option values (sorted by their corresponding option name in alphabetical order) which contain their names which can be retrieved with the getName or toString methods of ConfigOption.
 void setOptionValues(java.util.Vector<ConfigOption> optionValues)
          sets the configuration values from a vector which holds the configuration option values (must be sorted by their corresponding option name in alphabetical order)
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Configuration

public Configuration()
this default constructor instantiates an empty configuration


Configuration

public Configuration(java.util.HashMap<java.lang.String,ConfigOption> config)
instantiates a configuration with the specified options

Parameters:
config - the options in this configuration
Method Detail

getOptions

public java.util.HashMap<java.lang.String,ConfigOption> getOptions()
gets the configuration of the test which generated this event


getOptionNames

public java.util.Vector<java.lang.String> getOptionNames()
gets a vector which holds the configuration option names (in alphabetical order)


getOptionsWithNames

public java.util.Vector<ConfigOption> getOptionsWithNames()
gets a vector which holds the configuration option values (sorted by their corresponding option name in alphabetical order) which contain their names which can be retrieved with the getName or toString methods of ConfigOption.


setOptionValues

public void setOptionValues(java.util.Vector<ConfigOption> optionValues)
sets the configuration values from a vector which holds the configuration option values (must be sorted by their corresponding option name in alphabetical order)


equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object