SigPath

org.sigpath.tapestry.util
Class ConcentrationUnitModel

java.lang.Object
  extended by org.sigpath.tapestry.util.ConcentrationUnitModel
All Implemented Interfaces:
IPropertySelectionModel

public class ConcentrationUnitModel
extends Object
implements IPropertySelectionModel

Model for concentration property selection menu. This will dynamically build the pull down menu for the concentration types.


Constructor Summary
ConcentrationUnitModel()
          Constructs a new unit model for SigPath concentration units.
 
Method Summary
 String getLabel(int index)
          String representation of the label for unit at the given index.
 Object getOption(int index)
          Returns the Unit object at the given index.
 int getOptionCount()
          Returns the total number of concentration units.
 String getValue(int index)
          String representation of the unit at the given index.
 Object translateValue(String value)
          Returns the object that corresponds to the string value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConcentrationUnitModel

public ConcentrationUnitModel()
Constructs a new unit model for SigPath concentration units.

Method Detail

getOptionCount

public int getOptionCount()
Returns the total number of concentration units.

Specified by:
getOptionCount in interface IPropertySelectionModel
Returns:
Number of possible concentration unit types

getOption

public Object getOption(int index)
Returns the Unit object at the given index.

Specified by:
getOption in interface IPropertySelectionModel
Parameters:
index -
Returns:

getLabel

public String getLabel(int index)
String representation of the label for unit at the given index.

Specified by:
getLabel in interface IPropertySelectionModel
Parameters:
index -
Returns:

getValue

public String getValue(int index)
String representation of the unit at the given index.

Specified by:
getValue in interface IPropertySelectionModel
Parameters:
index -
Returns:

translateValue

public Object translateValue(String value)
Returns the object that corresponds to the string value.

Specified by:
translateValue in interface IPropertySelectionModel
Parameters:
value - Unit type
Returns:
Unit object that matches the string value

SigPath

Copyright © 2002-2005 Institute for Computational Biomedicine, All Rights Reserved.