Overview
Imports Austrian Hydro Data time series data as XML files that are delivered to FOEN in Switzerland. The files contain discharge time series in m3/s and water levels in cm. The files have an extension that contains the delivery date, example of file name "200642_Q.2016010910".
Configuration (Example)
A complete import module configuration consists of an ID Mapping file and an Import Module Instance file. Examples of the two are provided below.
The HYDAMS-XML file has the following characteristics:
- File is checked for XML element that start with “TSD”
- Location and parameter ID's are taken from the file name; first locationId, then parameter ID.
- Element that starts with "DEF" contains the header with the unit: EINHEIT
ModuleConfigFiles/
The following example of an Import Module Instance will import the time series as equidistant 15 minute interval series for time zone GMT+1 hour.
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<timeSeriesImportRun xmlns="http://www.wldelft.nl/fews" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.wldelft.nl/fews http://fews.wldelft.nl/schemas/version1.0/timeSeriesImportRun.xsd">
<import>
<general>
<importType>HYDAMS-XML</importType>
<folder>$IMPORT_FOLDER_ROOT$/austrian_hydro</folder>
<failedFolder>$FAILED_FOLDER_ROOT$</failedFolder>
<idMapId>ImportAustrian</idMapId>
<unitConversionsId>ImportHydroUnits</unitConversionsId>
<importTimeZone>
<timeZoneOffset>+01:00</timeZoneOffset>
</importTimeZone>
<dataFeedId>Import.Austrian</dataFeedId>
<actionLogEventTypeId>Import.Austrian</actionLogEventTypeId>
</general>
<timeSeriesSet>
<moduleInstanceId>Observed</moduleInstanceId>
<valueType>scalar</valueType>
<parameterId>Q.m</parameterId>
<locationSetId>HydroStations_AUSTRIA</locationSetId>
<timeSeriesType>external historical</timeSeriesType>
<timeStep unit="minute" multiplier="15"/>
<readWriteMode>add originals</readWriteMode>
<synchLevel>1</synchLevel>
</timeSeriesSet>
<timeSeriesSet>
<moduleInstanceId>Observed</moduleInstanceId>
<valueType>scalar</valueType>
<parameterId>H.m</parameterId>
<locationSetId>HydroStations_AUSTRIA</locationSetId>
<timeSeriesType>external historical</timeSeriesType>
<timeStep unit="minute" multiplier="15"/>
<readWriteMode>add originals</readWriteMode>
<synchLevel>1</synchLevel>
</timeSeriesSet>
<externUnit parameterId="Q.m" unit="m3/s"/>
</import>
</timeSeriesImportRun>
|
IdMapFiles/
The ID mapping file will contain a mapping of the parameters and locations in the data file with the internal parameter and location ID’s of the Delft-FEWS application.
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<idMap xmlns="http://www.wldelft.nl/fews" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.wldelft.nl/fews http://fews.wldelft.nl/schemas/version1.0/idMap.xsd" version="1.1">
<parameter external="W" internal="H.m"></parameter>
<parameter external="Q" internal="Q.m"></parameter>
<locationIdFunction externalLocationFunction="@EXTERNAL_ID@" internalLocationSet="HydroStations_AUSTRIA"></locationIdFunction>
</idMap>
|
Example File/
Code Block | ||||
---|---|---|---|---|
| ||||
<?xml version="1.0" encoding="ISO-8859-1"?>
<TSD RELEASE="1">
<DEF REIHENART="Z" TEXT="Nein" DEFART="I" EINHEIT="m│/s" LEN="0" ANZ="289" />
<DATA><![CDATA[
2016-01-07T13:15:00Z 0.31699881
2016-01-07T13:30:00Z 0.31699881
2016-01-07T13:45:00Z 0.31886774
2016-01-07T14:00:00Z 0.31949073
2016-01-07T14:15:00Z 0.31949073
........
|
Java source code
Delft-FEWS Java import parser source code: HydamsXMLTimeSeriesParser.java