Package hec.model
Class ModelVariable
java.lang.Object
hec.model.ModelVariable
- All Implemented Interfaces:
AsciiSerializable
,FieldAccessor
,Serializable
,Cloneable
,Comparable
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionModelVariable
(int type, String objectType, String name, String nqual, int paramId, int dataId) ModelVariable
(int type, String objectType, String name, String nqual, int paramId, int dataId, boolean required) ModelVariable
(int type, String objectType, String name, String nqual, int paramId, int dataId, boolean required, String unitStr, String unitTypeStr) ModelVariable
(String objectType, String name, int type, int paramId) -
Method Summary
Modifier and TypeMethodDescriptionclone()
int
boolean
equals
(ModelVariable mv) basic equality test.int
getFieldObject
(Field fld) This method allows access to java.lang.reflect.Field objects within the implementing class.getName()
int
double
int
int
getType()
int
boolean
boolean
read
(BufferedReader reader) boolean
setFieldObject
(Field fld, Object fobj) This allows access to fields withing the implementing object to set there data.void
setPriority
(double priority) void
setScaleIndex
(int idx) void
void
void
setViewportIndex
(int idx) toString()
boolean
write
(BufferedWriter writer)
-
Field Details
-
MODEL_VARIABLE_BEGIN
- See Also:
-
-
Constructor Details
-
ModelVariable
public ModelVariable() -
ModelVariable
-
ModelVariable
-
ModelVariable
-
ModelVariable
-
-
Method Details
-
equals
basic equality test.- Parameters:
mv
-- Returns:
- true if name, object type, type id, and param id are equal
-
isRequired
public boolean isRequired() -
getNameQualifier
-
getDataSetId
public int getDataSetId() -
getName
-
getType
public int getType() -
getObjectType
-
getParamId
public int getParamId() -
toString
-
getViewportIndex
public int getViewportIndex() -
setViewportIndex
public void setViewportIndex(int idx) -
getScaleIndex
public int getScaleIndex() -
setScaleIndex
public void setScaleIndex(int idx) -
getUnitString
-
setUnitString
-
getUnitTypeString
-
setUnitTypeString
-
write
- Throws:
IOException
-
read
- Throws:
IOException
-
setPriority
public void setPriority(double priority) -
getPriority
public double getPriority() -
compareTo
- Specified by:
compareTo
in interfaceComparable
-
clone
-
getFieldObject
Description copied from interface:FieldAccessor
This method allows access to java.lang.reflect.Field objects within the implementing class.- Specified by:
getFieldObject
in interfaceFieldAccessor
- Parameters:
fld
- The field to get.- Returns:
- The data object that is stored in the given field
-
setFieldObject
Description copied from interface:FieldAccessor
This allows access to fields withing the implementing object to set there data.- Specified by:
setFieldObject
in interfaceFieldAccessor
- Parameters:
fld
- The java field object representing the member field to be setfobj
- The data to set in that field- Returns:
- returns true if successful
-