Package ucar.nc2.dods
Class DodsNetcdfFile
- java.lang.Object
-
- ucar.nc2.NetcdfFile
-
- ucar.nc2.dods.DodsNetcdfFile
-
- All Implemented Interfaces:
Closeable,AutoCloseable,ucar.nc2.internal.cache.FileCacheable
@NotThreadSafe public class DodsNetcdfFile extends ucar.nc2.NetcdfFileA DODS dataset as seen through the Netcdf API.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classDodsNetcdfFile.Builder2
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static DodsNetcdfFile.Builder2builder()voidclose()voidgetDetailInfo(Formatter f)StringgetFileTypeDescription()StringgetFileTypeId()protected ucar.array.Array<?>readArrayData(ucar.nc2.Variable v, ucar.array.Section section)protected ucar.ma2.ArrayreadData(ucar.nc2.Variable v, ucar.ma2.Section section)ucar.ma2.ArrayreadSection(String variableSection)ucar.ma2.ArrayreadWithCE(ucar.nc2.Variable v, String CE)static voidsetAllowCompression(boolean b)Set whether to allow messages to be compressed.static voidsetAllowSessions(boolean b)Set whether to allow sessions by allowing cookies.static voidsetCoordinateVariablePreloadSize(int size)If preloading, set maximum size of coordinate variables to be preloaded.static voidsetPreload(boolean b)Set whether small variables are preloaded; only turn off for debugging.-
Methods inherited from class ucar.nc2.NetcdfFile
addLocalFieldsToBuilder, findAttribute, findDimension, findGlobalAttribute, findGlobalAttributeIgnoreCase, findGroup, findVariable, getDetailInfo, getDimensions, getFileTypeVersion, getGlobalAttributes, getId, getLastModified, getLocation, getRootGroup, getStructureDataArrayIterator, getStructureIterator, getTitle, getUnlimitedDimension, getVariables, hasUnlimitedDimension, reacquire, readSectionArray, release, sendIospMessage, setCachedData, setDebugFlags, setFileCache, showCached, showProxies, toBuilder, toNcml, toString, toStringDebug, writeNcml, writeNcml
-
-
-
-
Method Detail
-
setAllowSessions
public static void setAllowSessions(boolean b)
Set whether to allow sessions by allowing cookies. This only affects requests to the TDS. Setting this to true can eliminate consistency problems for datasets that are being updated.- Parameters:
b- true or false. default is false.
-
setAllowCompression
public static void setAllowCompression(boolean b)
Set whether to allow messages to be compressed. LOOK why not true as default?- Parameters:
b- true or false.
-
setPreload
public static void setPreload(boolean b)
Set whether small variables are preloaded; only turn off for debugging.- Parameters:
b- true if small variables are preloaded (default true)
-
setCoordinateVariablePreloadSize
public static void setCoordinateVariablePreloadSize(int size)
If preloading, set maximum size of coordinate variables to be preloaded.- Parameters:
size- maximum size of coordinate variables to be preloaded.
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceucar.nc2.internal.cache.FileCacheable- Overrides:
closein classucar.nc2.NetcdfFile- Throws:
IOException
-
readSection
public ucar.ma2.Array readSection(String variableSection) throws IOException, ucar.ma2.InvalidRangeException
- Overrides:
readSectionin classucar.nc2.NetcdfFile- Throws:
IOExceptionucar.ma2.InvalidRangeException
-
readArrayData
protected ucar.array.Array<?> readArrayData(ucar.nc2.Variable v, ucar.array.Section section) throws IOException, ucar.array.InvalidRangeException- Overrides:
readArrayDatain classucar.nc2.NetcdfFile- Throws:
IOExceptionucar.array.InvalidRangeException
-
readData
protected ucar.ma2.Array readData(ucar.nc2.Variable v, ucar.ma2.Section section) throws IOException, ucar.ma2.InvalidRangeException- Overrides:
readDatain classucar.nc2.NetcdfFile- Throws:
IOExceptionucar.ma2.InvalidRangeException
-
readWithCE
public ucar.ma2.Array readWithCE(ucar.nc2.Variable v, String CE) throws IOException- Throws:
IOException
-
getDetailInfo
public void getDetailInfo(Formatter f)
- Overrides:
getDetailInfoin classucar.nc2.NetcdfFile
-
getFileTypeId
public String getFileTypeId()
- Overrides:
getFileTypeIdin classucar.nc2.NetcdfFile
-
getFileTypeDescription
public String getFileTypeDescription()
- Overrides:
getFileTypeDescriptionin classucar.nc2.NetcdfFile
-
builder
public static DodsNetcdfFile.Builder2 builder()
-
-