|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectucar.nc2.iosp.AbstractIOServiceProvider
ucar.nc2.iosp.grid.GridServiceProvider
public abstract class GridServiceProvider
Superclass for Gempak grid, MciDAS grid, and GRIB IOSPs
Nested Class Summary | |
---|---|
static class |
GridServiceProvider.IndexExtendMode
|
Field Summary | |
---|---|
protected static boolean |
addLatLon
|
protected static boolean |
alwaysInCache
|
static boolean |
debugMissing
debug flags |
static boolean |
debugMissingDetails
debug flags |
static boolean |
debugOpen
debug flags |
static boolean |
debugProj
debug flags |
static boolean |
debugTiming
debug flags |
static boolean |
debugVert
debug flags |
protected FmrcCoordSys |
fmrcCoordSys
set by the FMRC from the inventory definition, otherwise null |
protected static boolean |
forceNewIndex
|
protected static GridServiceProvider.IndexExtendMode |
indexFileModeOnOpen
|
protected static GridServiceProvider.IndexExtendMode |
indexFileModeOnSync
|
protected NetcdfFile |
ncfile
The netCDF file that the iosp is part of |
protected static boolean |
useMaximalCoordSys
|
Fields inherited from class ucar.nc2.iosp.AbstractIOServiceProvider |
---|
raf |
Constructor Summary | |
---|---|
GridServiceProvider()
|
Method Summary | |
---|---|
protected abstract float[] |
_readData(GridRecord gr)
Read the data for this GridRecord |
static void |
forceNewIndex(boolean b)
Set whether to force new index or not |
String |
getDetailInfo()
Get the detail information |
boolean |
isMissingXY(Variable v2,
int timeIdx,
int ensIdx,
int levIdx)
Is this XY level missing? |
protected abstract void |
open(GridIndex index,
CancelTask cancelTask)
Use the given index to fill the NetcdfFile object with attributes and variables. |
void |
open(RandomAccessFile raf,
NetcdfFile ncfile,
CancelTask cancelTask)
Open the service provider for reading. |
Array |
readData(Variable v2,
Section section)
Read the data for the variable |
Object |
sendIospMessage(Object special)
Send an IOSP message |
static void |
setDebugFlags(DebugFlags debugFlag)
Set the debug flags |
static void |
setExtendIndex(boolean b)
Deprecated. use setIndexFileModeOnSync and setIndexFileModeOnOpen |
static void |
setIndexAlwaysInCache(boolean b)
Set disk cache policy for index files. |
static void |
setIndexFileModeOnOpen(GridServiceProvider.IndexExtendMode mode)
This controls what happens when a GRIB file is opened, and the data file has changed since the index was written. |
static void |
setIndexFileModeOnSync(GridServiceProvider.IndexExtendMode mode)
This controls what happens when a GRIB file is synced (usually from FileCache), and the data or index file has changed since the file was placed in the cache. |
static void |
useMaximalCoordSys(boolean b)
Set whether to use the maximal coordinate system or not |
Methods inherited from class ucar.nc2.iosp.AbstractIOServiceProvider |
---|
close, getFileTypeVersion, getStructureIterator, readSection, readToByteChannel, sync, syncExtend, toStringDebug |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface ucar.nc2.iosp.IOServiceProvider |
---|
getFileTypeDescription, getFileTypeId, isValidFile |
Field Detail |
---|
protected static GridServiceProvider.IndexExtendMode indexFileModeOnOpen
protected static GridServiceProvider.IndexExtendMode indexFileModeOnSync
protected static boolean addLatLon
protected static boolean useMaximalCoordSys
protected static boolean forceNewIndex
protected static boolean alwaysInCache
public static boolean debugOpen
public static boolean debugMissing
public static boolean debugMissingDetails
public static boolean debugProj
public static boolean debugTiming
public static boolean debugVert
protected FmrcCoordSys fmrcCoordSys
protected NetcdfFile ncfile
Constructor Detail |
---|
public GridServiceProvider()
Method Detail |
---|
public static void useMaximalCoordSys(boolean b)
b
- true to usepublic static void forceNewIndex(boolean b)
b
- true to usepublic static void setDebugFlags(DebugFlags debugFlag)
debugFlag
- debug flagspublic static void setIndexFileModeOnOpen(GridServiceProvider.IndexExtendMode mode)
mode
- IndexExtendMode when file is openedpublic static void setIndexFileModeOnSync(GridServiceProvider.IndexExtendMode mode)
mode
- IndexExtendMode when file is openedpublic static void setExtendIndex(boolean b)
b
- if true, set modes to IndexExtendMode.extendwrite, else IndexExtendMode.readonlypublic static void setIndexAlwaysInCache(boolean b)
b
- set to this valueprotected abstract void open(GridIndex index, CancelTask cancelTask) throws IOException
index
- GridIndex to usecancelTask
- cancel task
IOException
- problem reading the filepublic void open(RandomAccessFile raf, NetcdfFile ncfile, CancelTask cancelTask) throws IOException
open
in interface IOServiceProvider
open
in class AbstractIOServiceProvider
raf
- file to read fromncfile
- netCDF file we are writing to (memory)cancelTask
- task for cancelling
IOException
- problem reading filepublic String getDetailInfo()
getDetailInfo
in interface IOServiceProvider
getDetailInfo
in class AbstractIOServiceProvider
public Object sendIospMessage(Object special)
sendIospMessage
in interface IOServiceProvider
sendIospMessage
in class AbstractIOServiceProvider
special
- isn't that special?
public Array readData(Variable v2, Section section) throws IOException, InvalidRangeException
v2
- Variable to readsection
- section infomation
IOException
- problem reading from file
InvalidRangeException
- invalid RangeRange
public boolean isMissingXY(Variable v2, int timeIdx, int ensIdx, int levIdx) throws InvalidRangeException
v2
- VariabletimeIdx
- time indexensIdx
- ensemble indexlevIdx
- level index
InvalidRangeException
- invalid rangeprotected abstract float[] _readData(GridRecord gr) throws IOException
gr
- grid identifier
IOException
- problem reading the data
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |