Package hec.clientapp.model
Class TSRecordImpl
java.lang.Object
java.util.Observable
hec.lang.NamedType
hec.model.AbstractTSRecord
hec.clientapp.model.TSRecordImpl
- All Implemented Interfaces:
AsciiSerializable,FieldAccessor,TSRecord,Serializable,Cloneable,Comparable,Observer,mil.army.usace.hec.metadata.VerticalDatum,rma.lang.Modifiable
- Direct Known Subclasses:
AltTimeSeriesGlobalData,LocalTSRecordImpl,RssTSRecordImpl,TSRecordProxy
- See Also:
-
Field Summary
FieldsFields inherited from class hec.model.AbstractTSRecord
_beginDate, _beginTime, _compressData, _dataArray, _dssArray, _dssFilename, _dssPathname, _endTime, _inputDataPos, _interpUnitsType, _isObservedData, _numSteps, _paramName, _size, _startTime, _timeArray, _timeIncrString, _timeStepMin, _timeWindow, _units, _unitsType, _varId, _vdc, INPUT, OUTPUTFields inherited from class hec.lang.NamedType
_description, _ignoreModifiedEvents, _index, _isValid, _modified, _name, defaultDescription, defaultName, DESCRIPTION_CHANGED, NAME_CHANGED, RENAME_EVENTFields inherited from interface hec.model.TSRecord
DEFAULT_INPUT, OBS_INPUT, SUMMARY_AVG, SUMMARY_CNT, SUMMARY_MAX, SUMMARY_MIN, SUMMARY_NUMID -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedInstantiates a new tS record impl.TSRecordImpl(int index) Instantiates a new tS record impl.TSRecordImpl(TSDataSet tsData, int index) Instantiates a new tS record impl.TSRecordImpl(TSDataSet tsData, Integer index) Instantiates a new tS record impl.TSRecordImpl(TSRecordImpl tsRecord) Instantiates a new tS record impl. -
Method Summary
Modifier and TypeMethodDescriptionbooleanload without interpolation and check data for undefined values or other problems.protected booleanCheck if data should be interpolated.getRelativePath(String pathName) protected booleanChecks if is evap data.protected booleanChecks if is input data.booleanbooleanisValidValue(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager) Checks if is valid value.booleanload without interpolation and with minimal error checking and messages.booleanloadRawTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager) Load raw ts data.booleanRead Time Series record from DSS and perform interpolation in time if necessary.booleanloadTSData(HecTime startTime, HecTime endTime) Load Time Series record for the start and end times (HecTime).protected booleanloadTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager) Read Time Series record from DSS and perform interpolation in time if an offset occurs in data.booleanloadTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager, HecTime startTime, HecTime endTime) Load ts data.voidsetTSDataSet(TSDataSet tsds) Sets the tS data set.protected booleanreturn true to interpolate evap data.voidUnload ts data.protected booleanChecks if interpolated input data should be written out to the DSS file.booleanbooleanwriteTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager) Write ts data.protected booleanwriteTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager, String dssPathname, intArrayContainer timeArray, doubleArrayContainer dataArray, String unitsType) Write ts data.booleanwriteTSDataAs(String pathname, String interpUnitsType) Methods inherited from class hec.model.AbstractTSRecord
average, clone, copyInto, forceVerticalDatum, getBeginDate, getBeginTime, getCumulativeTotal, getCumulativeTotal, getCurrentOffset, getCurrentOffset, getCurrentValue, getCurrentVerticalDatum, getDataArrayFor, getDSSFilename, getDSSPathname, getFieldObject, getInputDataPos, getInterpolatedTSArray, getInterpUnitsType, getLaggedValue, getNativeVerticalDatum, getNAVD88Offset, getNAVD88Offset, getNGVD29Offset, getNGVD29Offset, getNumSteps, getParamName, getPeriodAverage, getPeriodAverage, getPeriodAverage, getPeriodAverage, getPreviousValue, getSummaryArray, getTimeArray, getTimeSeriesContainer, getTimeSeriesContainerFor, getTimeStepMinutes, getTimeWindowString, getTSArray, getTSContainer, getTSValueAt, getUnits, getUnitsType, getValue, getValue, getVariableId, getVerticalDatumContainer, getVerticalDatumInfo, hasVerticalDatum, initialize, initialize, isCurrentVerticalDatumEstimated, isDefaultData, isNAVD88OffsetEstimated, isNGVD29OffsetEstimated, isObservedData, max, min, parseDssPath, readData, readDataFromRas, reinitialize, reset, setCompressData, setCurrentValue, setCurrentValue, setDSSFilename, setDSSPathname, setDSSPathname, setFieldObject, setInputDataPos, setInterpUnitsType, setParamName, setTimeWindow, setTimeWindowString, setUnits, setUnitsType, setVariableId, setVerticalDatumContainer, setVerticalDatumInfo, shiftLeft, shiftLeft, standardDeviation, sum, toNativeVerticalDatum, toNAVD88, toNGVD29, toVerticalDatum, writeData, writeDataToRasMethods inherited from class hec.lang.NamedType
addModifiableListener, compareTo, fireModifiedStateChanged, getDescription, getDisplayName, getIgnoreModifiedEvents, getIndex, getName, isModified, isValid, readResolve, removeModifiableListener, rename, set, setDescription, setIgnoreModifiedEvents, setIndex, setModified, setName, setValid, toString, update, useRecursiveModifiedTestMethods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
-
Field Details
-
_tsDataSet
The _ts data set.
-
-
Constructor Details
-
TSRecordImpl
protected TSRecordImpl()Instantiates a new tS record impl. -
TSRecordImpl
public TSRecordImpl(int index) Instantiates a new tS record impl.- Parameters:
index- the index
-
TSRecordImpl
Instantiates a new tS record impl.- Parameters:
tsData- the ts dataindex- the index
-
TSRecordImpl
Instantiates a new tS record impl.- Parameters:
tsData- the ts dataindex- the index
-
TSRecordImpl
Instantiates a new tS record impl.- Parameters:
tsRecord- the ts record
-
-
Method Details
-
getRelativePath
- Specified by:
getRelativePathin classAbstractTSRecord
-
writeTSDataAs
-
writeTSData
public boolean writeTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager) Write ts data.- Parameters:
dssManager- the dss manager- Returns:
- true, if successful
-
writeTSData
protected boolean writeTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager, String dssPathname, intArrayContainer timeArray, doubleArrayContainer dataArray, String unitsType) Write ts data.- Parameters:
dssManager- the dss managerdssPathname- the dss pathnametimeArray- the time arraydataArray- the data arrayunitsType- the units type- Returns:
- true, if successful
-
writeTSData
public boolean writeTSData() -
loadTSData
Load Time Series record for the start and end times (HecTime). Performs no interpolation.- Parameters:
startTime- the start timeendTime- the end time- Returns:
- true, if successful
-
loadTSData
public boolean loadTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager, HecTime startTime, HecTime endTime) Load ts data.- Parameters:
dssManager- the dss managerstartTime- the start timeendTime- the end time- Returns:
- true, if successful
-
loadTSData
public boolean loadTSData()Read Time Series record from DSS and perform interpolation in time if necessary. Time window and time step size must be first set in one of the initialize() methods. This form of loadTSData() reads in the data for the time window and interpolates if necessary to an interval given by _timeStepMin.- Returns:
- true, if successful
-
loadTSData
protected boolean loadTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager) Read Time Series record from DSS and perform interpolation in time if an offset occurs in data. Convert data type to PER-AVER or INST-VAL if applicable. Time window and time step size must be first set in one of the initialize() methods. This form of loadTSData() reads in the data for the time window and interpolates if necessary to an interval given by _timeStepMin.- Parameters:
dssManager- the dss manager- Returns:
- true, if successful
-
shouldInterpEvapData
protected boolean shouldInterpEvapData()return true to interpolate evap data.- Returns:
- false by default
-
isEvapData
protected boolean isEvapData()Checks if is evap data.- Returns:
- true, if is evap data
-
isInputData
protected boolean isInputData()Checks if is input data.- Returns:
- true, if is input data
-
writeInterpolatedInputData
protected boolean writeInterpolatedInputData()Checks if interpolated input data should be written out to the DSS file.- Returns:
- true, if is input data should write out
-
doInterpolations
protected boolean doInterpolations()Check if data should be interpolated. Note - Method created so classes extending this one could override the interpolations.- Returns:
- true by default
-
loadRawTSData
public boolean loadRawTSData()load without interpolation and with minimal error checking and messages.- Returns:
- true, if successful
-
loadRawTSData
public boolean loadRawTSData(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager) Load raw ts data.- Parameters:
dssManager- the dss manager- Returns:
- true, if successful
-
isValidValue
public boolean isValidValue() -
isValidValue
public boolean isValidValue(mil.army.usace.hec.rmi.csinterface.DSSManager dssManager) Checks if is valid value.- Parameters:
dssManager- the dss manager- Returns:
- true, if is valid value
-
checkTSData
public boolean checkTSData()load without interpolation and check data for undefined values or other problems.- Returns:
- true, if successful
-
setTSDataSet
Sets the tS data set.- Parameters:
tsds- the new tS data set
-
unloadTSData
public void unloadTSData()Unload ts data. -
getDataSet
-
getAltName
-