protected TableConfig getPointConfig(NetcdfDataset ds, Formatter errlog) { // the profile values are the inner sequence TableConfig obsTable = new TableConfig(Table.Type.Structure, BufrIosp.obsRecord); Structure obsStruct = (Structure) ds.findVariable(BufrIosp.obsRecord); obsTable.structName = obsStruct.getName(); obsTable.nestedTableName = obsStruct.getShortName(); obsTable.lat = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Lat.toString()); obsTable.lon = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Lon.toString()); obsTable.elev = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Height.toString()); obsTable.time = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Time.toString()); return obsTable; }
protected TableConfig getTrajectoryConfig(NetcdfDataset ds, Formatter errlog) { TableConfig topTable = new TableConfig(Table.Type.Top, "singleTrajectory"); // the profile values are the inner sequence TableConfig obsTable = new TableConfig(Table.Type.Structure, BufrIosp.obsRecord); Structure obsStruct = (Structure) ds.findVariable(BufrIosp.obsRecord); obsTable.structName = obsStruct.getName(); obsTable.nestedTableName = obsStruct.getShortName(); obsTable.lat = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Lat.toString()); obsTable.lon = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Lon.toString()); obsTable.elev = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Height.toString()); obsTable.time = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Time.toString()); topTable.addChild(obsTable); return topTable; }
protected TableConfig getProfileConfig(NetcdfDataset ds, Formatter errlog) { // construct the station table by reading through the timeseries TableConfig profileTable = new TableConfig(Table.Type.Structure, "profile"); profileTable.featureType = FeatureType.PROFILE; profileTable.structName = BufrIosp.obsRecord; Structure profileStruct = (Structure) ds.findVariable(BufrIosp.obsRecord); profileTable.lat = Evaluator.getNameOfVariableWithAttribute(profileStruct, _Coordinate.AxisType, AxisType.Lat.toString()); profileTable.lon = Evaluator.getNameOfVariableWithAttribute(profileStruct, _Coordinate.AxisType, AxisType.Lon.toString()); profileTable.time = Evaluator.getNameOfVariableWithAttribute(profileStruct, _Coordinate.AxisType, AxisType.Time.toString()); // the time series is just the outer structure TableConfig obsTable = new TableConfig(Table.Type.NestedStructure, "struct5"); Structure obsStruct = (Structure) profileStruct.findVariable("struct5"); obsTable.structName = obsStruct.getName(); obsTable.nestedTableName = obsStruct.getShortName(); obsTable.elev = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Pressure.toString()); // HEY not height profileTable.addChild(obsTable); return profileTable; }
protected TableConfig getStationProfileConfig(NetcdfDataset ds, Formatter errlog) { // construct the station table by reading through the timeseries TableConfig stnTable = new TableConfig(Table.Type.Construct, "station"); stnTable.featureType = FeatureType.STATION_PROFILE; stnTable.structName = BufrIosp.obsRecord; // the time series is just the outer structure TableConfig timeTable = new TableConfig(Table.Type.ParentId, BufrIosp.obsRecord); Structure stnStruct = (Structure) ds.findVariable(BufrIosp.obsRecord); timeTable.lat = Evaluator.getNameOfVariableWithAttribute(stnStruct, _Coordinate.AxisType, AxisType.Lat.toString()); timeTable.lon = Evaluator.getNameOfVariableWithAttribute(stnStruct, _Coordinate.AxisType, AxisType.Lon.toString()); timeTable.stnAlt = Evaluator.getNameOfVariableWithAttribute(stnStruct, _Coordinate.AxisType, AxisType.Height.toString()); timeTable.stnId = Evaluator.getNameOfVariableWithAttribute(stnStruct, CF.STANDARD_NAME, CF.STATION_ID); timeTable.stnWmoId = Evaluator.getNameOfVariableWithAttribute(stnStruct, CF.STANDARD_NAME, CF.STATION_WMOID); if (timeTable.stnId == null) timeTable.stnId = timeTable.stnWmoId; timeTable.parentIndex = timeTable.stnId; timeTable.time = Evaluator.getNameOfVariableWithAttribute(stnStruct, _Coordinate.AxisType, AxisType.Time.toString()); timeTable.structName = BufrIosp.obsRecord; stnTable.addChild(timeTable); // the profile values are the inner sequence TableConfig obsTable = new TableConfig(Table.Type.NestedStructure, "levels"); Structure obsStruct = (Structure) stnStruct.findVariable("seq1"); // kludgerino if (obsStruct == null) obsStruct = (Structure) stnStruct.findVariable("struct1"); obsTable.structName = obsStruct.getName(); obsTable.nestedTableName = obsStruct.getShortName(); obsTable.elev = Evaluator.getNameOfVariableWithAttribute(obsStruct, _Coordinate.AxisType, AxisType.Height.toString()); timeTable.addChild(obsTable); return stnTable; }