Package hec.model
Class BaseTSDataSet
java.lang.Object
hec.model.BaseTSDataSet
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final String
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
appendTSRecords
(BaseTSDataSet tsdataset) appends all unique records from the given TSDataSet into this TSDataSet Uniqueness is defined by having a unique NAME/PARAMETER/DSS PATHNAMEboolean
checkTSRecords
(Vector tsrecVec) read in the data for the record and check completeness of the datavoid
createTSRecord
(String name, int varid, String param) createTSRecord
(String name, String param) long
getName()
getTSRecord
(String name, int varid) getTSRecord
(String name, String param) getTSRecordByPathParts
(String bPart, String cPart) int
getTSRecordSummaryTable
(String typestr) int
getType()
void
init()
boolean
initialize
(int beginDate, int beginTime, int timeStepMin, int numSteps, String timeWindow) boolean
initialize
(RunTimeWindow rtw) set up time series records forboolean
isValidToWrite
(TSRecord rec) loadTSRecord
(String name, int varId, String timewinstr) loadTSRecord
(String name, String param, String timewinstr) boolean
boolean
loadTSRecords
(Vector tsrecVec) boolean
readData
(BufferedReader input) Reads time series records from an existing opened BufferedReaderboolean
readDataFromRas
(BufferedReader input) Reads time series records from an existing opened BufferedReader according to RAS v.2.2 flow file formatboolean
readFile
(BufferedReader input) boolean
reset time series records for new time windowboolean
reLoadFile
(BufferedReader reader) void
reset()
void
setAltName
(String name) void
setCompressData
(boolean comp) void
setDescription
(String description) void
setMessagePrinter
(MessagePrinter printer) void
void
setParentPath
(String path, String classname) void
boolean
setType
(int t) void
shiftDataSet
(HecTime newStartTime) Shifts all data in a data set by a given amount.void
Shifts all data in a data set by a given amount.void
boolean
writeData
(BufferedWriter out) Writes time series records to an existing opened BufferedWriterboolean
Writes time series records to an existing opened BufferedWriter according to RAS v.2.2 flow file formatboolean
writeFile
(BufferedWriter out) Writes time series records to ascii file given in identifier.boolean
-
Field Details
-
INST
public static final int INST- See Also:
-
PER_AVG
public static final int PER_AVG- See Also:
-
PER_CUM
public static final int PER_CUM- See Also:
-
SUMMARY_DELIM
- See Also:
-
-
Constructor Details
-
BaseTSDataSet
public BaseTSDataSet()
-
-
Method Details
-
setAltName
-
getAltName
-
setTSRecordCreator
-
getTSRecordList
-
getLastModifiedTime
public long getLastModifiedTime() -
setName
-
getName
-
setDescription
-
getDescription
-
setMessagePrinter
-
getTSRecordCount
public int getTSRecordCount() -
getTSRecordSummaryTable
-
setParentPath
-
getParentPath
-
getParentClassName
-
getType
public int getType() -
setType
public boolean setType(int t) -
appendTSRecords
appends all unique records from the given TSDataSet into this TSDataSet Uniqueness is defined by having a unique NAME/PARAMETER/DSS PATHNAME -
init
public void init() -
getTSRecords
-
getTSRecord
-
getTSRecord
-
getTSRecordByPathParts
-
reset
public void reset() -
initialize
public boolean initialize(int beginDate, int beginTime, int timeStepMin, int numSteps, String timeWindow) -
initialize
set up time series records for -
reinitialize
reset time series records for new time window -
reLoadFile
-
readFile
-
writeDataToRas
Writes time series records to an existing opened BufferedWriter according to RAS v.2.2 flow file format -
readDataFromRas
Reads time series records from an existing opened BufferedReader according to RAS v.2.2 flow file format -
readData
Reads time series records from an existing opened BufferedReader -
writeData
Writes time series records to an existing opened BufferedWriter -
writeFile
Writes time series records to ascii file given in identifier. -
setCompressData
public void setCompressData(boolean comp) -
writeTSRecords
public boolean writeTSRecords() -
isValidToWrite
- Parameters:
rec
-- Returns:
- true if the record has a dss path and file
-
loadTSRecords
public boolean loadTSRecords() -
loadTSRecords
-
loadTSRecord
-
loadTSRecord
-
checkTSRecords
read in the data for the record and check completeness of the data -
clearTSRecordList
public void clearTSRecordList() -
createTSRecord
-
createTSRecord
-
unloadTSRecord
public void unloadTSRecord() -
shiftDataSet
Shifts all data in a data set by a given amount. The newStartTime passed in becomes the new start time of the data. The end time and the lookback time still differ by the same amount. It is just simple shift. If newStartTime occurs as a time in between to time steps the the greatest time value the is not more than newStartTime is shifted to the first position- Parameters:
newStartTime
-
-
shiftDataSet
Shifts all data in a data set by a given amount. The newStartTime passed in becomes the new start time of the data. The end time and the lookback time still differ by the same amount. It is just simple shift. If newStartTime occurs as a time in between to time steps the the greatest time value the is not more than newStartTime is shifted to the first position
-