databionics.modules
Class Parameter

java.lang.Object
  extended by databionics.modules.Parameter
Direct Known Subclasses:
AbstractStringParameter, FloatParameter, IntParameter, MultipleChoiceParameter, SwitchParameter

public abstract class Parameter
extends java.lang.Object

Base class for all parameters. A parameter is a command line argument neede when runnint a Tool.


Field Summary
protected  boolean constant
          flag whether this parameter should be constant or changeable
protected  java.lang.String description
          decription to be displayed in dialogs
protected static org.apache.log4j.Logger log
          log4j logging
protected  java.lang.String longName
          long name
protected  java.lang.String name
          short name
protected  boolean optional
          flag whether this parameter is optional or required
 
Constructor Summary
Parameter()
           
 
Method Summary
abstract  java.lang.Object clone()
          Creates and returns a copy of this object.
 java.lang.String getDescription()
          Get decription to be displayed in dialogs
 java.lang.String getLongName()
          Get the long name to be used as "--longname"
 java.lang.String getName()
          Get the name to be used as "-name"
abstract  java.lang.String getValueAsString()
          String representation of argument value.
 boolean isConstant()
          Get flag whether this parameter should be constant or changeable
 boolean isOptional()
          Get flag whether this parameter is optional or required
 void setConstant(boolean c)
          Set flag whether this parameter should be constant or changeable
 void setDescription(java.lang.String s)
          Set decription to be displayed in dialogs
 void setLongName(java.lang.String s)
          Set the long name to be used as "--longname"
 void setName(java.lang.String s)
          Set the name to be used as "-name"
 void setOptional(boolean opt)
          Set flag whether this parameter is optional or required
abstract  java.lang.String toString()
          String representation.
abstract  java.lang.String toXml()
          XML representation
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

log

protected static org.apache.log4j.Logger log
log4j logging


name

protected java.lang.String name
short name


longName

protected java.lang.String longName
long name


description

protected java.lang.String description
decription to be displayed in dialogs


optional

protected boolean optional
flag whether this parameter is optional or required


constant

protected boolean constant
flag whether this parameter should be constant or changeable

Constructor Detail

Parameter

public Parameter()
Method Detail

getName

public java.lang.String getName()
Get the name to be used as "-name"


getLongName

public java.lang.String getLongName()
Get the long name to be used as "--longname"


getDescription

public java.lang.String getDescription()
Get decription to be displayed in dialogs


isOptional

public boolean isOptional()
Get flag whether this parameter is optional or required


isConstant

public boolean isConstant()
Get flag whether this parameter should be constant or changeable


setName

public void setName(java.lang.String s)
Set the name to be used as "-name"


setLongName

public void setLongName(java.lang.String s)
Set the long name to be used as "--longname"


setDescription

public void setDescription(java.lang.String s)
Set decription to be displayed in dialogs


setOptional

public void setOptional(boolean opt)
Set flag whether this parameter is optional or required


setConstant

public void setConstant(boolean c)
Set flag whether this parameter should be constant or changeable


clone

public abstract java.lang.Object clone()
Creates and returns a copy of this object.

Overrides:
clone in class java.lang.Object

getValueAsString

public abstract java.lang.String getValueAsString()
String representation of argument value.


toString

public abstract java.lang.String toString()
String representation.

Overrides:
toString in class java.lang.Object

toXml

public abstract java.lang.String toXml()
XML representation



Copyright © 2005-2006 Databionics Research Group. All Rights Reserved.