|
SORTIE Java Interface
1
|
Packages a data value with other information. More...
Public Member Functions | |
| ModelEnum (int[] p_iAllowedValues, String[] p_sValueLabels, String sDescriptor, String sXMLTag) | |
| Constructor. | |
| String | toString () |
| Required overridden method. | |
| void | setValue (int iValue) throws ModelException |
| Sets the value. | |
| void | setValue (String sValue) throws ModelException |
| Sets the value using one of the string literals. | |
| int | getValue () |
| Gets the integer value. | |
| String | getStringValue () |
| Get the string label corresponding to the current integer value. | |
| int[] | getAllowedValues () |
| Gets the set of all allowed values. | |
| String[] | getAllowedValueLabels () |
| Gets the set of allowed value labels. | |
| boolean | equals (Object oTest) |
| Overriding equality tester. | |
| Object | clone () |
| Clones this object. | |
Public Member Functions inherited from sortie.data.simpletypes.ModelData | |
| ModelData (String sDescriptor, String sXMLTag) | |
| Constructor. | |
| String | getDescriptor () |
| Returns the descriptor string. | |
| void | setDescriptor (String sDescriptor) |
| Sets the descriptor string. | |
| String | getXMLTag () |
| Returns the XML tag associated with this piece of data. | |
| void | setXMLTag (String sXMLTag) |
| Sets the XML tag associated with this piece of data. | |
Protected Attributes | |
| int | m_iValue |
| Variable's value. | |
| int[] | mp_iAllowedValues |
| Set of allowed values. | |
| String[] | mp_sValueLabels |
| Label to display for each value. | |
Protected Attributes inherited from sortie.data.simpletypes.ModelData | |
| String | m_sDescriptor |
| Descriptive string. | |
Packages a data value with other information.
This object has a limited number of values it can accept.
Copyright: Copyright (c) Charles D. Canham 2003
Company: Cary Institute of Ecosystem Studies
Edit history:
---------------—
April 28, 2004: Submitted in beta version (LEM)
| sortie.data.simpletypes.ModelEnum.ModelEnum | ( | int[] | p_iAllowedValues, |
| String[] | p_sValueLabels, | ||
| String | sDescriptor, | ||
| String | sXMLTag | ||
| ) |
Constructor.
| p_iAllowedValues | Allowed values. |
| p_sValueLabels | Text label for each allowed value. Optional. |
| sDescriptor | Descriptor string. |
| sXMLTag | The XML tag associated with this piece of data. |
| Object sortie.data.simpletypes.ModelEnum.clone | ( | ) |
Clones this object.
| boolean sortie.data.simpletypes.ModelEnum.equals | ( | Object | oTest | ) |
Overriding equality tester.
| oTest | Object to test for equality |
| String [] sortie.data.simpletypes.ModelEnum.getAllowedValueLabels | ( | ) |
Gets the set of allowed value labels.
| int [] sortie.data.simpletypes.ModelEnum.getAllowedValues | ( | ) |
Gets the set of all allowed values.
| String sortie.data.simpletypes.ModelEnum.getStringValue | ( | ) |
Get the string label corresponding to the current integer value.
| int sortie.data.simpletypes.ModelEnum.getValue | ( | ) |
Gets the integer value.
| void sortie.data.simpletypes.ModelEnum.setValue | ( | int | iValue | ) | throws ModelException |
Sets the value.
| iValue | Value to set. |
| ModelException | if the value is not an allowed value. |
| void sortie.data.simpletypes.ModelEnum.setValue | ( | String | sValue | ) | throws ModelException |
Sets the value using one of the string literals.
| sValue | String value. |
| ModelException | if the string literal does not correspond to an allowed value. |
|
virtual |
Required overridden method.
Implements sortie.data.simpletypes.ModelData.
|
protected |
Variable's value.
|
protected |
Set of allowed values.
|
protected |
Label to display for each value.
1.8.2