Package ucar.nc2.ft2.coverage
Class CoverageDatasetFactory
- java.lang.Object
-
- ucar.nc2.ft2.coverage.CoverageDatasetFactory
-
public class CoverageDatasetFactory extends Object
factory for CoverageDataset 1) Remote CdmrFeatureDataset: cdmremote:url 2) GRIB collections: must be a grib file, or grib index file 3) DtCoverageDataset (forked from ucar.nc2.dt.grid), the cdm IOSP / CoordSys stackWould like to add a separate implementation for FMRC collections
- Since:
- 5/26/2015
-
-
Field Summary
Fields Modifier and Type Field Description static String
NO_GRIB_CLASS
static String
NOT_GRIB_FILE
-
Constructor Summary
Constructors Constructor Description CoverageDatasetFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static FeatureDatasetCoverage
open(String endpoint)
static Optional<FeatureDatasetCoverage>
openCoverageDataset(String endpoint)
static Optional<FeatureDatasetCoverage>
openGrib(String endpoint)
static Optional<FeatureDatasetCoverage>
openNcmlString(String ncml)
Deprecated.Use openNcmlString(String, String)static Optional<FeatureDatasetCoverage>
openNcmlString(String ncml, String location)
-
-
-
Field Detail
-
NOT_GRIB_FILE
public static final String NOT_GRIB_FILE
- See Also:
- Constant Field Values
-
NO_GRIB_CLASS
public static final String NO_GRIB_CLASS
- See Also:
- Constant Field Values
-
-
Method Detail
-
openCoverageDataset
public static Optional<FeatureDatasetCoverage> openCoverageDataset(String endpoint) throws IOException
- Parameters:
endpoint
- cdmrFeature:url, local GRIB data or index file, or NetcdfDataset locationucar.nc2.util.Optional
opt = CoverageDatasetFactory.openCoverageDataset(location); if (!opt.isPresent()) { JOptionPane.showMessageDialog(null, opt.getErrorMessage()); return false; } covDatasetCollection = opt.get(); - Throws:
IOException
-
open
public static FeatureDatasetCoverage open(String endpoint) throws IOException
- Parameters:
endpoint
- cdmrFeature:url, local GRIB data or index file, or NetcdfDataset location- Returns:
- FeatureDatasetCoverage or null on failure. use openCoverageDataset to get error message
- Throws:
IOException
-
openGrib
public static Optional<FeatureDatasetCoverage> openGrib(String endpoint)
- Parameters:
endpoint
- local GRIB data or index file- Returns:
- FeatureDatasetCoverage or null on failure.
-
openNcmlString
@Deprecated public static Optional<FeatureDatasetCoverage> openNcmlString(String ncml) throws IOException
Deprecated.Use openNcmlString(String, String)- Throws:
IOException
-
openNcmlString
public static Optional<FeatureDatasetCoverage> openNcmlString(String ncml, String location) throws IOException
- Parameters:
ncml
- the NcML as a Stringlocation
- the URL location string of the NcML document, or may be just a unique name for caching purposes (if null, aggregation cache will not be used).- Throws:
IOException
-
-