compbio.metadata
Class PresetManager<T>

java.lang.Object
  extended by compbio.metadata.PresetManager<T>
Type Parameters:
T - type of executable.

public class PresetManager<T>
extends Object

Collection of presets and methods to manipulate them @see Preset

Version:
1.0 December 2009
Author:
pvtroshin

Field Summary
static String LOCAL_ENGINE_LIMIT_PRESET
           
 
Constructor Summary
PresetManager()
           
 
Method Summary
 Preset<T> getPresetByName(String presetName)
           
 List<Preset<T>> getPresets()
           
 String getRunnerClassName()
           
 void setPresets(List<Preset<T>> presets)
           
 void setRunnerClassName(String runnerClassName)
           
 String toString()
           
 void validate(RunnerConfig<T> options)
          Checks whether preset option and parameter are defined in RunnerConfig object.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

LOCAL_ENGINE_LIMIT_PRESET

public static final String LOCAL_ENGINE_LIMIT_PRESET
See Also:
Constant Field Values
Constructor Detail

PresetManager

public PresetManager()
Method Detail

getPresets

public List<Preset<T>> getPresets()

setPresets

public void setPresets(List<Preset<T>> presets)

getRunnerClassName

public String getRunnerClassName()
Returns:
fully qualified class name of type T

setRunnerClassName

public void setRunnerClassName(String runnerClassName)

getPresetByName

public Preset<T> getPresetByName(String presetName)
Parameters:
presetName -
Returns:
preset by its name, null if no preset found

validate

public void validate(RunnerConfig<T> options)
              throws ValidationException
Checks whether preset option and parameter are defined in RunnerConfig object. TODO handle parameters with values properly!

Throws:
ValidationException - if preset is found to be invalid.

toString

public String toString()
Overrides:
toString in class Object