private void checkIfTrajectory(TableConfig st) { // deal with possible trajectory - only do this if dataset has metadata FeatureType ft = FeatureDatasetFactoryManager.findFeatureType(ds); if (ft == FeatureType.TRAJECTORY) { st.featureType = FeatureType.TRAJECTORY; TableConfig pc = new TableConfig(Table.Type.Top, "single"); st.parent = pc; pc.addChild(st); } else st.featureType = FeatureType.POINT; }
private void checkIfTrajectory(TableConfig st) { // deal with possible trajectory - only do this if dataset has metadata FeatureType ft = FeatureDatasetFactoryManager.findFeatureType(ds); if (ft == FeatureType.TRAJECTORY) { st.featureType = FeatureType.TRAJECTORY; TableConfig pc = new TableConfig(Table.Type.Top, "single"); st.parent = pc; pc.addChild(st); } else st.featureType = FeatureType.POINT; }
public TableConfig getConfig(FeatureType wantFeatureType, NetcdfDataset ds, Formatter errlog) { VNames vn = getVariableNames(ds, errlog); TableConfig trajTable = new TableConfig(Table.Type.Construct, "trajectory"); trajTable.featureType = FeatureType.TRAJECTORY; trajTable.feature_id = TRAJ_ID; TableConfig obs = new TableConfig(Table.Type.ParentId, "record"); obs.parentIndex = TRAJ_ID; obs.dimName = Evaluator.getDimensionName(ds, "recNum", errlog); obs.time = vn.obsTime; obs.timeNominal = vn.nominalTime; //obs.stnId = vn.stnId; //obs.stnDesc = vn.stnDesc; obs.lat = vn.lat; obs.lon = vn.lon; obs.elev = vn.elev; trajTable.addChild(obs); return trajTable; }
public TableConfig getConfig(FeatureType wantFeatureType, NetcdfDataset ds, Formatter errlog) { VNames vn = getVariableNames(ds, errlog); TableConfig trajTable = new TableConfig(Table.Type.Construct, "trajectory"); trajTable.featureType = FeatureType.TRAJECTORY; trajTable.feature_id = TRAJ_ID; TableConfig obs = new TableConfig(Table.Type.ParentId, "record"); obs.parentIndex = TRAJ_ID; obs.dimName = Evaluator.getDimensionName(ds, "recNum", errlog); obs.time = vn.obsTime; obs.timeNominal = vn.nominalTime; //obs.stnId = vn.stnId; //obs.stnDesc = vn.stnDesc; obs.lat = vn.lat; obs.lon = vn.lon; obs.elev = vn.elev; trajTable.addChild(obs); return trajTable; }
private void checkIfTrajectory(TableConfig st) { // deal with possible trajectory - only do this if dataset has metadata FeatureType ft = FeatureDatasetFactoryManager.findFeatureType(ds); if (ft == FeatureType.TRAJECTORY) { st.featureType = FeatureType.TRAJECTORY; TableConfig pc = new TableConfig(Table.Type.Top, "single"); st.parent = pc; pc.addChild(st); } else st.featureType = FeatureType.POINT; }
public TableConfig getConfig(FeatureType wantFeatureType, NetcdfDataset ds, Formatter errlog) { VNames vn = getVariableNames(ds, errlog); TableConfig trajTable = new TableConfig(Table.Type.Construct, "trajectory"); trajTable.featureType = FeatureType.TRAJECTORY; trajTable.feature_id = TRAJ_ID; TableConfig obs = new TableConfig(Table.Type.ParentId, "record"); obs.parentIndex = TRAJ_ID; obs.dimName = Evaluator.getDimensionName(ds, "recNum", errlog); obs.time = vn.obsTime; obs.timeNominal = vn.nominalTime; //obs.stnId = vn.stnId; //obs.stnDesc = vn.stnDesc; obs.lat = vn.lat; obs.lon = vn.lon; obs.elev = vn.elev; trajTable.addChild(obs); return trajTable; }
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; }
private void findNestedStructures(Structure s, TableConfig parent) { for (Variable v : s.getVariables()) { if (v instanceof Structure) { // handles Sequences too TableConfig nestedTable = new TableConfig(Table.Type.NestedStructure, v.getFullName()); nestedTable.structName = v.getFullName(); nestedTable.nestedTableName = v.getShortName(); addTable(nestedTable); parent.addChild(nestedTable); // LOOK why not add the join(parent,child) here ? //nestedTable.join = new TableConfig.JoinConfig(Join.Type.NestedStructure); //joins.add(nestedTable.join); findNestedStructures((Structure) v, nestedTable); // look for nested structures } } }
private void findNestedStructures(Structure s, TableConfig parent) { for (Variable v : s.getVariables()) { if (v instanceof Structure) { // handles Sequences too TableConfig nestedTable = new TableConfig(Table.Type.NestedStructure, v.getFullName()); nestedTable.structName = v.getFullName(); nestedTable.nestedTableName = v.getShortName(); addTable(nestedTable); parent.addChild(nestedTable); // LOOK why not add the join(parent,child) here ? //nestedTable.join = new TableConfig.JoinConfig(Join.Type.NestedStructure); //joins.add(nestedTable.join); findNestedStructures((Structure) v, nestedTable); // look for nested structures } } }
private void findNestedStructures(Structure s, TableConfig parent) { for (Variable v : s.getVariables()) { if (v instanceof Structure) { // handles Sequences too TableConfig nestedTable = new TableConfig(Table.Type.NestedStructure, v.getFullName()); nestedTable.structName = v.getFullName(); nestedTable.nestedTableName = v.getShortName(); addTable(nestedTable); parent.addChild(nestedTable); // LOOK why not add the join(parent,child) here ? //nestedTable.join = new TableConfig.JoinConfig(Join.Type.NestedStructure); //joins.add(nestedTable.join); findNestedStructures((Structure) v, nestedTable); // search for nested structures } } }
private TableConfig makeSingle(NetcdfDataset ds, Dimension obsDim, Formatter errlog) throws IOException { Table.Type obsTableType = Table.Type.Structure; TableConfig obsTable = new TableConfig(obsTableType, "single"); obsTable.dimName = obsDim.getShortName(); obsTable.lat = matchAxisTypeAndDimension(ds, AxisType.Lat, obsDim); obsTable.lon = matchAxisTypeAndDimension(ds, AxisType.Lon, obsDim); obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Height, obsDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Pressure, obsDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.GeoZ, obsDim); obsTable.time = matchAxisTypeAndDimension(ds, AxisType.Time, obsDim); makeStructureInfo(obsTable, ds, null, obsDim); return obsTable; }
private TableConfig makeSingle(NetcdfDataset ds, Dimension obsDim, Formatter errlog) throws IOException { Table.Type obsTableType = Table.Type.Structure; TableConfig obsTable = new TableConfig(obsTableType, "single"); obsTable.dimName = obsDim.getShortName(); obsTable.lat = matchAxisTypeAndDimension(ds, AxisType.Lat, obsDim); obsTable.lon = matchAxisTypeAndDimension(ds, AxisType.Lon, obsDim); obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Height, obsDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Pressure, obsDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.GeoZ, obsDim); obsTable.time = matchAxisTypeAndDimension(ds, AxisType.Time, obsDim); makeStructureInfo(obsTable, ds, null, obsDim); return obsTable; }
private TableConfig makeRaggedContiguousChildTable(NetcdfDataset ds, Dimension parentDim, Dimension childDim, Structure childStruct, Formatter errlog) throws IOException { TableConfig childTable = new TableConfig(Table.Type.Contiguous, childDim.getShortName()); childTable.dimName = childDim.getShortName(); childTable.lat = matchAxisTypeAndDimension(ds, AxisType.Lat, childDim); childTable.lon = matchAxisTypeAndDimension(ds, AxisType.Lon, childDim); childTable.elev = matchAxisTypeAndDimension(ds, AxisType.Height, childDim); if (childTable.elev == null) childTable.elev = matchAxisTypeAndDimension(ds, AxisType.Pressure, childDim); if (childTable.elev == null) childTable.elev = matchAxisTypeAndDimension(ds, AxisType.GeoZ, childDim); childTable.time = matchAxisTypeAndDimension(ds, AxisType.Time, childDim); makeStructureInfo(childTable, ds, childStruct, childDim); return childTable; }
private TableConfig makeRaggedContiguousChildTable(NetcdfDataset ds, Dimension parentDim, Dimension childDim, Structure childStruct, Formatter errlog) throws IOException { TableConfig childTable = new TableConfig(Table.Type.Contiguous, childDim.getShortName()); childTable.dimName = childDim.getShortName(); childTable.lat = matchAxisTypeAndDimension(ds, AxisType.Lat, childDim); childTable.lon = matchAxisTypeAndDimension(ds, AxisType.Lon, childDim); childTable.elev = matchAxisTypeAndDimension(ds, AxisType.Height, childDim); if (childTable.elev == null) childTable.elev = matchAxisTypeAndDimension(ds, AxisType.Pressure, childDim); if (childTable.elev == null) childTable.elev = matchAxisTypeAndDimension(ds, AxisType.GeoZ, childDim); childTable.time = matchAxisTypeAndDimension(ds, AxisType.Time, childDim); makeStructureInfo(childTable, ds, childStruct, childDim); return childTable; }
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; }
private TableConfig makeSingle(NetcdfDataset ds, Dimension obsDim, Formatter errlog) throws IOException { Table.Type obsTableType = Table.Type.Structure; TableConfig obsTable = new TableConfig(obsTableType, "single"); obsTable.dimName = obsDim.getShortName(); obsTable.lat = matchAxisTypeAndDimension(ds, AxisType.Lat, obsDim); obsTable.lon = matchAxisTypeAndDimension(ds, AxisType.Lon, obsDim); obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Height, obsDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Pressure, obsDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.GeoZ, obsDim); obsTable.time = matchAxisTypeAndDimension(ds, AxisType.Time, obsDim); boolean obsIsStruct = Evaluator.hasRecordStructure(ds) && obsDim.isUnlimited(); obsTable.structName = obsIsStruct ? "record" : obsDim.getShortName(); obsTable.structureType = obsIsStruct ? TableConfig.StructureType.Structure : TableConfig.StructureType.PsuedoStructure; return obsTable; }
private TableConfig makeRaggedIndexChildTable(NetcdfDataset ds, Dimension parentDim, Dimension childDim, Variable ragged_parentIndex, Formatter errlog) throws IOException { TableConfig childTable = new TableConfig(Table.Type.ParentIndex, childDim.getShortName()); childTable.dimName = childDim.getShortName(); childTable.lat = matchAxisTypeAndDimension(ds, AxisType.Lat, childDim); childTable.lon = matchAxisTypeAndDimension(ds, AxisType.Lon, childDim); childTable.elev = matchAxisTypeAndDimension(ds, AxisType.Height, childDim); if (childTable.elev == null) childTable.elev = matchAxisTypeAndDimension(ds, AxisType.Pressure, childDim); if (childTable.elev == null) childTable.elev = matchAxisTypeAndDimension(ds, AxisType.GeoZ, childDim); childTable.time = matchAxisTypeAndDimension(ds, AxisType.Time, childDim); makeStructureInfo(childTable, ds, ragged_parentIndex.getParentStructure(), childDim); childTable.parentIndex = ragged_parentIndex.getFullName(); return childTable; }
private TableConfig makeRaggedIndexChildTable(NetcdfDataset ds, Dimension parentDim, Dimension childDim, Variable ragged_parentIndex, Formatter errlog) throws IOException { TableConfig childTable = new TableConfig(Table.Type.ParentIndex, childDim.getShortName()); childTable.dimName = childDim.getShortName(); childTable.lat = matchAxisTypeAndDimension(ds, AxisType.Lat, childDim); childTable.lon = matchAxisTypeAndDimension(ds, AxisType.Lon, childDim); childTable.elev = matchAxisTypeAndDimension(ds, AxisType.Height, childDim); if (childTable.elev == null) childTable.elev = matchAxisTypeAndDimension(ds, AxisType.Pressure, childDim); if (childTable.elev == null) childTable.elev = matchAxisTypeAndDimension(ds, AxisType.GeoZ, childDim); childTable.time = matchAxisTypeAndDimension(ds, AxisType.Time, childDim); makeStructureInfo(childTable, ds, ragged_parentIndex.getParentStructure(), childDim); childTable.parentIndex = ragged_parentIndex.getFullName(); return childTable; }
private TableConfig makeRaggedContiguous(NetcdfDataset ds, Dimension parentDim, Dimension childDim, Variable ragged_rowSize, Formatter errlog) throws IOException { TableConfig obsTable = new TableConfig(Table.Type.Contiguous, childDim.getShortName()); obsTable.dimName = childDim.getShortName(); obsTable.lat = matchAxisTypeAndDimension(ds, AxisType.Lat, childDim); obsTable.lon = matchAxisTypeAndDimension(ds, AxisType.Lon, childDim); obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Height, childDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Pressure, childDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.GeoZ, childDim); obsTable.time = matchAxisTypeAndDimension(ds, AxisType.Time, childDim); boolean obsIsStruct = Evaluator.hasRecordStructure(ds) && childDim.isUnlimited(); obsTable.structName = obsIsStruct ? "record" : childDim.getShortName(); obsTable.structureType = obsIsStruct ? TableConfig.StructureType.Structure : TableConfig.StructureType.PsuedoStructure; obsTable.numRecords = ragged_rowSize.getFullName(); return obsTable; }
private TableConfig makeRaggedIndex(NetcdfDataset ds, Dimension parentDim, Dimension childDim, Variable ragged_parentIndex, Formatter errlog) throws IOException { TableConfig obsTable = new TableConfig(Table.Type.ParentIndex, childDim.getShortName()); obsTable.dimName = childDim.getShortName(); obsTable.lat = matchAxisTypeAndDimension(ds, AxisType.Lat, childDim); obsTable.lon = matchAxisTypeAndDimension(ds, AxisType.Lon, childDim); obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Height, childDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.Pressure, childDim); if (obsTable.elev == null) obsTable.elev = matchAxisTypeAndDimension(ds, AxisType.GeoZ, childDim); obsTable.time = matchAxisTypeAndDimension(ds, AxisType.Time, childDim); boolean obsIsStruct = Evaluator.hasRecordStructure(ds) && childDim.isUnlimited(); obsTable.structName = obsIsStruct ? "record" : childDim.getShortName(); obsTable.structureType = obsIsStruct ? TableConfig.StructureType.Structure : TableConfig.StructureType.PsuedoStructure; obsTable.parentIndex = ragged_parentIndex.getFullName(); return obsTable; }