Package hec.data
Class TsTranslator
java.lang.Object
hec.data.TsTranslator
Translates from hec.data.tx.DescriptionTx Objects to DSS Paths and viceversa.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic TsTranslator
static boolean
Indicated that the DSS message level needs to be set. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic DescriptionTx
dssPathToTsDescription
(HecDataManager dataManager, String dssPath) Returns a TsDescription for the DSS Path.static DescriptionTx
dssPathToTsDescription
(String dssPath, String dssType) static void
dssPathUnitsAndType
(stringContainer unitsCont, stringContainer typeCont, HecDataManager dataManager, String dssPath) static DataSetTx
static DataSetTx
dssToTs
(String translationTableFilePath, String dssFilePath, String dssPath, long startTime, long endTime) static DataSetTx
dssToTs
(String translationTableFilePath, String dssFilePath, String dssPath, String fpart, String version, long[] timewindow) static DataSetTx
dssToTs
(String translationTableFilePath, String dssFilePath, String dssPath, String fpart, String version, long startTime, long endTime) static DataSetTx
dssToTs
(Properties dssToTsProp, HecDataManager dataManager, String dssPath, String fpart, String version, long[] timewindow) static DataSetTx
dssToTs
(Properties dssToTsProp, String dssFilePath, String dssPath, String fpart, String version, long[] timewindow) static long[]
getDssStartAndEndTime
(HecDataManager dataManager, String dssPath) static Properties
getListProperties
(String filepath) static HecTimeSeries
getTimeSeries
(HecDataManager dataManager, String dssPath) Returns a HecTimeSeries from the HecDataManager described by the DSS path.static String
matchDssTypeTsParameterType
(String dssType) static String
static String[]
parseDssPath
(String path) static String
tsDescriptionToDssPath
(DescriptionTx tsdesc) static String
tsDescriptionToDssPath
(String strTsdesc) static int
-1 = no match to the tsdesc
-2 = no records found in time seriesstatic int
tsToDss
(Properties lookupTable, HecDataManager dataManager, String timeStep, long startTime, long endTime, DataSetTx tsds) static int
tsToDss
(Properties lookupTable, String dssFilePath, DataSetTx tsds) static int
tsToDss
(Properties lookupTable, String dssFilePath, String timeStep, long startTime, long endTime, DataSetTx tsds) Writes a hec.data.tx.DataSetTx to DSS.
-
Field Details
-
setDssMessageLevel
public static boolean setDssMessageLevelIndicated that the DSS message level needs to be set. -
_app
-
-
Constructor Details
-
TsTranslator
public TsTranslator()
-
-
Method Details
-
dssPathToTsDescription
Returns a TsDescription for the DSS Path. WCDS Id equals a concatination of the A part and B part. Parameter equals a match or translation of the C part. Parameter Type equals a match or translation of the Type defined in the DSS Header. Interval equals a match of the E part. Duration is determined by examining the Interval and Parameter Type. Version equals a match of the F part. -
dssPathToTsDescription
-
dssPathUnitsAndType
public static void dssPathUnitsAndType(stringContainer unitsCont, stringContainer typeCont, HecDataManager dataManager, String dssPath) -
getDssStartAndEndTime
-
tsDescriptionToDssPath
-
tsDescriptionToDssPath
-
matchDssTypeTsParameterType
-
matchTsParameterTypeDssType
-
parseDssPath
-
dssToTs
public static DataSetTx dssToTs(String translationTableFilePath, String dssFilePath, String dssPath) throws Exception - Throws:
Exception
-
dssToTs
public static DataSetTx dssToTs(String translationTableFilePath, String dssFilePath, String dssPath, long startTime, long endTime) throws Exception - Throws:
Exception
-
dssToTs
public static DataSetTx dssToTs(String translationTableFilePath, String dssFilePath, String dssPath, String fpart, String version, long startTime, long endTime) throws Exception - Throws:
Exception
-
dssToTs
public static DataSetTx dssToTs(String translationTableFilePath, String dssFilePath, String dssPath, String fpart, String version, long[] timewindow) throws Exception - Throws:
Exception
-
dssToTs
public static DataSetTx dssToTs(Properties dssToTsProp, String dssFilePath, String dssPath, String fpart, String version, long[] timewindow) throws Exception - Throws:
Exception
-
dssToTs
public static DataSetTx dssToTs(Properties dssToTsProp, HecDataManager dataManager, String dssPath, String fpart, String version, long[] timewindow) throws Exception - Throws:
Exception
-
tsToDss
-1 = no match to the tsdesc
-2 = no records found in time series -
tsToDss
-
tsToDss
public static int tsToDss(Properties lookupTable, String dssFilePath, String timeStep, long startTime, long endTime, DataSetTx tsds) Writes a hec.data.tx.DataSetTx to DSS. Return values. 0 = hec.data.tx.DataSetTx had no values. -1 = DSS Path error. -2 = Interpolate error. -
tsToDss
public static int tsToDss(Properties lookupTable, HecDataManager dataManager, String timeStep, long startTime, long endTime, DataSetTx tsds) -
getTimeSeries
Returns a HecTimeSeries from the HecDataManager described by the DSS path. The HecDataManager uses the DSS path to create the new HecTimeSeries. -
getListProperties
-