Package ucar.nc2.ft.fmrc
Class Fmrc
- java.lang.Object
-
- ucar.nc2.ft.fmrc.Fmrc
-
- All Implemented Interfaces:
Closeable
,AutoCloseable
@ThreadSafe public class Fmrc extends Object implements Closeable
Forecast Model Run Collection, manages dynamic collections of GridDatasets. Fmrc represents a virtual dataset. To instantiate, you obtain an FmrcInv "snapshot" from which you can call getDatatset(). Assumes that we dont have multiple runtimes in the same file. Can handle different time steps in different files. Can handle different grids in different files. However this creates problems for the "typical dataset". Cannot handle different ensembles in different files. (LOOK fix) Cannot handle different levels in different files. ok- Since:
- Jan 11, 2010
-
-
Constructor Summary
Constructors Constructor Description Fmrc(MCollection manager, FeatureCollectionConfig config)
-
Method Summary
-
-
-
Constructor Detail
-
Fmrc
public Fmrc(MCollection manager, FeatureCollectionConfig config)
-
-
Method Detail
-
open
public static Fmrc open(String collection, Formatter errlog) throws IOException
Factory method- Parameters:
collection
- describes the collection. May be one of:- collection specification string
- catalog:catalogURL
- filename.ncml
errlog
- place error messages here- Returns:
- Fmrc or null on error
- Throws:
IOException
- on read error- See Also:
- "https://www.unidata.ucar.edu/software/netcdf-java/reference/collections/CollectionSpecification.html"
-
readNcML
public static Fmrc readNcML(String ncmlString, Formatter errlog) throws IOException
- Throws:
IOException
-
open
public static Fmrc open(FeatureCollectionConfig config, Formatter errlog)
-
setNcml
public void setNcml(org.jdom2.Element outerNcml, org.jdom2.Element innerNcml)
-
close
public void close()
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
-
getManager
public MCollection getManager()
-
getDateRangeForRun
public CalendarDateRange getDateRangeForRun(CalendarDate run)
-
getDateRangeForOffset
public CalendarDateRange getDateRangeForOffset(double offset)
-
getRunDates
public List<CalendarDate> getRunDates()
-
getForecastDates
public List<CalendarDate> getForecastDates()
-
getForecastOffsets
public double[] getForecastOffsets()
-
getDataset2D
public GridDataset getDataset2D(NetcdfDataset result) throws IOException
- Throws:
IOException
-
getDatasetBest
public GridDataset getDatasetBest() throws IOException
- Throws:
IOException
-
getDatasetBest
public GridDataset getDatasetBest(FeatureCollectionConfig.BestDataset bd) throws IOException
- Throws:
IOException
-
getRunTimeDataset
public GridDataset getRunTimeDataset(CalendarDate run) throws IOException
- Throws:
IOException
-
getConstantForecastDataset
public GridDataset getConstantForecastDataset(CalendarDate time) throws IOException
- Throws:
IOException
-
getConstantOffsetDataset
public GridDataset getConstantOffsetDataset(double hour) throws IOException
- Throws:
IOException
-
updateProto
public void updateProto()
-
update
public void update()
-
checkInvState
public boolean checkInvState(long lastInvChange)
-
checkProtoState
public boolean checkProtoState(long lastProtoChanged)
-
showDetails
public void showDetails(Formatter out)
-
-