Package ucar.nc2.dataset.conv
Class CF1Convention
- java.lang.Object
-
- ucar.nc2.dataset.CoordSysBuilder
-
- ucar.nc2.dataset.conv.COARDSConvention
-
- ucar.nc2.dataset.conv.CSMConvention
-
- ucar.nc2.dataset.conv.CF1Convention
-
- All Implemented Interfaces:
CoordSysBuilderIF
- Direct Known Subclasses:
CEDRICRadarConvention
public class CF1Convention extends CSMConvention
CF-1 Convention. see http://www.cgd.ucar.edu/cms/eaton/cf-metadata/index.html "The CF conventions for climate and forecast metadata are designed to promote the processing and sharing of files created with the netCDF API. The conventions define metadata that provide a definitive description of what the data in each variable represents, and of the spatial and temporal properties of the data. This enables users of data from different sources to decide which quantities are comparable, and facilitates building applications with powerful extraction, regridding, and display capabilities."
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class ucar.nc2.dataset.CoordSysBuilder
CoordSysBuilder.ConventionNameOk, CoordSysBuilder.VarProcess
-
-
Field Summary
-
Fields inherited from class ucar.nc2.dataset.conv.COARDSConvention
checkForMeter
-
Fields inherited from class ucar.nc2.dataset.CoordSysBuilder
conventionName, coordVarMap, debug, log, parseInfo, resourcesDir, userAdvice, varList
-
-
Constructor Summary
Constructors Constructor Description CF1Convention()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
augmentDataset(NetcdfDataset ds, CancelTask cancelTask)
Make changes to the dataset that are needed before processing scale/offset in NetcdfDataset.protected AxisType
getAxisType(NetcdfDataset ncDataset, VariableEnhanced v)
Augment COARDS axis type identification with Standard names (including dimensionless vertical coordinates) and CF.AXIS attributesstatic int
getVersion(String hasConvName)
Get which CF version this is, ie CF-1.xstatic String
getZisPositive(String zaxisName, String vertCoordUnits)
Guess the value of ZisPositive based on z axis name and units-
Methods inherited from class ucar.nc2.dataset.conv.CSMConvention
addParameter2, findCoordinateAxes, makeCoordinateTransform
-
Methods inherited from class ucar.nc2.dataset.conv.COARDSConvention
checkTimeVarForCalendar, isMine
-
Methods inherited from class ucar.nc2.dataset.CoordSysBuilder
addCoordinateVariable, addUserAdvice, assignCoordinateSystemsExplicit, assignCoordinateTransforms, breakupConventionNames, buildConventionAttribute, buildCoordinateSystems, factory, findCoordinateAxis, findCoordinateSystems, findCoordinateTransforms, findVarProcess, getConventionUsed, getParseInfo, getUseMaximalCoordSys, getUserAdvice, isCoordinateAxisForVariable, makeCoordinateAxes, makeCoordinateSystems, makeCoordinateSystemsImplicit, makeCoordinateSystemsMaximal, makeCoordinateTransforms, makeCoordinateTransformVariable, registerConvention, registerConvention, registerConvention, registerNcML, setConventionUsed, setUseMaximalCoordSys
-
-
-
-
Method Detail
-
getVersion
public static int getVersion(String hasConvName)
Get which CF version this is, ie CF-1.x- Parameters:
hasConvName
- extract from convention name or list of names- Returns:
- version, or -1 if not CF
-
getZisPositive
public static String getZisPositive(String zaxisName, String vertCoordUnits)
Guess the value of ZisPositive based on z axis name and units- Parameters:
zaxisName
- z coordinate axis namevertCoordUnits
- z coordinate axis name- Returns:
- CF.POSITIVE_UP or CF.POSITIVE_DOWN
-
augmentDataset
public void augmentDataset(NetcdfDataset ds, CancelTask cancelTask) throws IOException
Description copied from interface:CoordSysBuilderIF
Make changes to the dataset that are needed before processing scale/offset in NetcdfDataset.- Specified by:
augmentDataset
in interfaceCoordSysBuilderIF
- Overrides:
augmentDataset
in classCSMConvention
- Parameters:
ds
- modify this datasetcancelTask
- give user a chance to bail out- Throws:
IOException
- on error
-
getAxisType
protected AxisType getAxisType(NetcdfDataset ncDataset, VariableEnhanced v)
Augment COARDS axis type identification with Standard names (including dimensionless vertical coordinates) and CF.AXIS attributes- Overrides:
getAxisType
in classCOARDSConvention
- Parameters:
ncDataset
- for this datasetv
- a variable alreaddy identified as a Coodinate Axis- Returns:
- AxisType or null if unknown.
-
-