Package ucar.nc2.dt.radial
Class Dorade2RadialAdapter
- java.lang.Object
-
- ucar.nc2.dt.radial.AbstractRadialAdapter
-
- ucar.nc2.dt.radial.Dorade2RadialAdapter
-
- All Implemented Interfaces:
Closeable
,AutoCloseable
,RadialDatasetSweep
,FeatureDataset
,FeatureDatasetFactory
,FileCacheable
public class Dorade2RadialAdapter extends AbstractRadialAdapter
Make a Dorade 2 NetcdfDataset into a RadialDataset.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class ucar.nc2.dt.radial.AbstractRadialAdapter
AbstractRadialAdapter.MyRadialVariableAdapter
-
Nested classes/interfaces inherited from interface ucar.nc2.dt.RadialDatasetSweep
RadialDatasetSweep.RadialVariable, RadialDatasetSweep.Sweep, RadialDatasetSweep.Type
-
-
Field Summary
-
Fields inherited from class ucar.nc2.dt.radial.AbstractRadialAdapter
boundingBox, calDateUnits, csHash, dataVariables, dateUnits, desc, endDate, fileCache, location, netcdfDataset, origin, parseInfo, startDate, title
-
-
Constructor Summary
Constructors Constructor Description Dorade2RadialAdapter()
Dorade2RadialAdapter(NetcdfDataset ds)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addRadialVariable(NetcdfDataset nds, Variable var)
void
clearDatasetMemory()
Remove cached data, if any.List
getAttributes()
EarthLocation
getCommonOrigin()
If all sweeps have the same origin, return it here, else nullString
getDataFormat()
String
getRadarID()
String
getRadarName()
FeatureType
getScientificDataType()
DateUnit
getTimeUnits()
Get the units of Calendar time.void
getTimeUnits(DateUnit dateUnits)
Object
isMine(FeatureType wantFeatureType, NetcdfDataset ncd, Formatter errlog)
Determine if the factory can open this dataset as an instance of the given feature typeboolean
isStationary()
Stationary versus moving radar.boolean
isVolume()
Get the basic property of Radar,protected RadialDatasetSweep.RadialVariable
makeRadialVariable(NetcdfDataset nds, Variable v0)
FeatureDataset
open(FeatureType ftype, NetcdfDataset ncd, Object analysis, CancelTask task, Formatter errlog)
Open a NetcdfDataset as a FeatureDataset.protected void
setEarthLocation()
protected void
setEndDate()
protected void
setStartDate()
protected void
setTimeUnits()
-
Methods inherited from class ucar.nc2.dt.radial.AbstractRadialAdapter
attributes, calcBounds, close, findGlobalAttributeIgnoreCase, getBoundingBox, getCalendarDateEnd, getCalendarDateRange, getCalendarDateStart, getCalendarDateUnit, getCommonType, getDataVariable, getDataVariables, getDateRange, getDescription, getDetailInfo, getDetailInfo, getEarthLocation, getEndDate, getFeatureType, getFeatureTypes, getGlobalAttributes, getImplementationName, getLastModified, getLocation, getLocationURI, getNetcdfFile, getStartDate, getTitle, reacquire, release, removeDataVariable, setBoundingBox, setDescription, setFileCache, setLocationURI, setTitle
-
-
-
-
Constructor Detail
-
Dorade2RadialAdapter
public Dorade2RadialAdapter()
-
Dorade2RadialAdapter
public Dorade2RadialAdapter(NetcdfDataset ds)
Constructor.- Parameters:
ds
- must be from dorade IOSP
-
-
Method Detail
-
isMine
public Object isMine(FeatureType wantFeatureType, NetcdfDataset ncd, Formatter errlog)
Description copied from interface:FeatureDatasetFactory
Determine if the factory can open this dataset as an instance of the given feature type- Parameters:
wantFeatureType
- can factory open as this feature type? If null, can factory open as any feature type?ncd
- examine this NetcdfDataset.errlog
- place errors here- Returns:
- "analysis object" - null if cannot open, else an Object that is passed back into FeatureDatasetFactory.open(). This allows expensive analysis results to be reused
-
open
public FeatureDataset open(FeatureType ftype, NetcdfDataset ncd, Object analysis, CancelTask task, Formatter errlog)
Description copied from interface:FeatureDatasetFactory
Open a NetcdfDataset as a FeatureDataset. Should only be called if isMine() returns non-null.- Parameters:
ftype
- open as this feature type. If null, open as any feature type.ncd
- an already opened NetcdfDataset.analysis
- the object returned from isMine(). Likely given to a different instance of FeatureDatasetFactorytask
- user may cancel, may be nullerrlog
- write error messages here, may be null- Returns:
- a subclass of FeatureDataset
-
getScientificDataType
public FeatureType getScientificDataType()
-
getRadarID
public String getRadarID()
- Returns:
- radar id
-
getRadarName
public String getRadarName()
- Returns:
- radar name
-
getDataFormat
public String getDataFormat()
- Returns:
- data format
-
getCommonOrigin
public EarthLocation getCommonOrigin()
Description copied from interface:RadialDatasetSweep
If all sweeps have the same origin, return it here, else null- Returns:
- common origin, or null
-
isStationary
public boolean isStationary()
Description copied from interface:RadialDatasetSweep
Stationary versus moving radar.- Returns:
- true if this is stationary.
-
isVolume
public boolean isVolume()
Description copied from interface:RadialDatasetSweep
Get the basic property of Radar,- Returns:
- 0 if there is only one sweep
-
setEarthLocation
protected void setEarthLocation()
- Specified by:
setEarthLocation
in classAbstractRadialAdapter
-
addRadialVariable
protected void addRadialVariable(NetcdfDataset nds, Variable var)
- Specified by:
addRadialVariable
in classAbstractRadialAdapter
-
makeRadialVariable
protected RadialDatasetSweep.RadialVariable makeRadialVariable(NetcdfDataset nds, Variable v0)
- Specified by:
makeRadialVariable
in classAbstractRadialAdapter
-
setStartDate
protected void setStartDate()
- Specified by:
setStartDate
in classAbstractRadialAdapter
-
setEndDate
protected void setEndDate()
- Specified by:
setEndDate
in classAbstractRadialAdapter
-
setTimeUnits
protected void setTimeUnits() throws Exception
- Specified by:
setTimeUnits
in classAbstractRadialAdapter
- Throws:
Exception
-
getAttributes
public List getAttributes()
-
getTimeUnits
public DateUnit getTimeUnits()
Description copied from interface:RadialDatasetSweep
Get the units of Calendar time. To get a Date, from a time value, call DateUnit.getStandardDate(double value). To get units as a String, call DateUnit.getUnitsString().- Specified by:
getTimeUnits
in interfaceRadialDatasetSweep
- Overrides:
getTimeUnits
in classAbstractRadialAdapter
- Returns:
- units of Calendar time
-
getTimeUnits
public void getTimeUnits(DateUnit dateUnits)
-
clearDatasetMemory
public void clearDatasetMemory()
Description copied from interface:RadialDatasetSweep
Remove cached data, if any.
-
-