public class RecordDatasetHelper extends Object
Modifier and Type | Field and Description |
---|---|
protected double |
altScaleFactor |
protected LatLonRect |
boundingBox |
protected Formatter |
errs |
protected String |
latVName |
protected String |
lonVName |
protected double |
maxDate |
protected double |
minDate |
protected NetcdfDataset |
ncfile |
protected String |
nomTimeVName |
protected Dimension |
obsDim |
protected String |
obsTimeVName |
protected StructureDS |
recordVar |
protected boolean |
showErrors |
protected StationHelper |
stationHelper |
protected DataType |
stationIdType |
protected String |
stnDescVName |
protected String |
stnIdVName |
protected String |
stnIndexVName |
protected DateUnit |
timeUnit |
protected String |
zcoordUnits |
protected String |
zcoordVName |
Constructor and Description |
---|
RecordDatasetHelper(NetcdfDataset ncfile,
String obsTimeVName,
String nomTimeVName,
List<VariableSimpleIF> typedDataVariables,
String recDimName,
Formatter errBuffer)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
PointFeature |
factory(StationImpl s,
StructureData sdata,
int recno) |
double |
getLatitude(StructureData sdata) |
LatLonPoint |
getLocation(StructureData sdata) |
double |
getLongitude(StructureData sdata) |
protected static double |
getMetersConversionFactor(String unitsString) |
double |
getObservationTime(StructureData sdata) |
Date |
getObservationTimeAsDate(StructureData sdata) |
int |
getRecordCount() |
Structure |
getRecordVar() |
DateUnit |
getTimeUnit() |
double |
getZcoordinate(StructureData sdata) |
String |
getZcoordUnits() |
void |
setLocationInfo(String latVName,
String lonVName,
String zcoordVName) |
void |
setShortNames(String latVName,
String lonVName,
String altVName,
String obsTimeVName,
String nomTimeVName) |
void |
setStationInfo(String stnIdVName,
String stnDescVName,
String stnIndexVName,
StationHelper stationHelper)
Set extra information used by station obs datasets.
|
void |
setTimeUnit(DateUnit timeUnit) |
protected NetcdfDataset ncfile
protected String obsTimeVName
protected String nomTimeVName
protected String latVName
protected String lonVName
protected String zcoordVName
protected String zcoordUnits
protected String stnIdVName
protected String stnIndexVName
protected String stnDescVName
protected StationHelper stationHelper
protected DataType stationIdType
protected StructureDS recordVar
protected Dimension obsDim
protected LatLonRect boundingBox
protected double minDate
protected double maxDate
protected DateUnit timeUnit
protected double altScaleFactor
protected Formatter errs
protected boolean showErrors
public RecordDatasetHelper(NetcdfDataset ncfile, String obsTimeVName, String nomTimeVName, List<VariableSimpleIF> typedDataVariables, String recDimName, Formatter errBuffer)
ncfile
- the netccdf filetypedDataVariables
- list of data variables; all record variables will be added to this list, except . You
can remove extraobsTimeVName
- observation time variable name (required)nomTimeVName
- nominal time variable name (may be null)IllegalArgumentException
- if ncfile has no unlimited dimension and recDimName is null.public void setStationInfo(String stnIdVName, String stnDescVName, String stnIndexVName, StationHelper stationHelper)
stnIdVName
- the obs variable that is used to find the station in the stnHash; may be type int or a String (char).stnDescVName
- optional station var containing station descriptionpublic void setShortNames(String latVName, String lonVName, String altVName, String obsTimeVName, String nomTimeVName)
protected static double getMetersConversionFactor(String unitsString) throws Exception
Exception
public Structure getRecordVar()
public int getRecordCount()
public void setTimeUnit(DateUnit timeUnit)
public DateUnit getTimeUnit()
public LatLonPoint getLocation(StructureData sdata)
public double getLatitude(StructureData sdata)
public double getLongitude(StructureData sdata)
public double getZcoordinate(StructureData sdata)
public String getZcoordUnits()
public Date getObservationTimeAsDate(StructureData sdata)
public double getObservationTime(StructureData sdata)
public PointFeature factory(StationImpl s, StructureData sdata, int recno)
Copyright © 1999–2018 UCAR/Unidata. All rights reserved.