public class Nc4Iosp extends AbstractIOServiceProvider implements IOServiceProviderWriter
| Modifier and Type | Field and Description |
|---|---|
protected static String |
DEFAULTNETCDF4LIBNAME |
static String |
JNA_PATH |
static String |
JNA_PATH_ENV |
protected static String |
netcdf4libname |
raf| Constructor and Description |
|---|
Nc4Iosp() |
Nc4Iosp(NetcdfFileWriter.Version version) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
create(String filename,
NetcdfFile ncfile,
int extra,
long preallocateSize,
boolean largeFile) |
protected static String |
defaultNetcdf4Library()
Use the default path to try to set jna.library.path
|
void |
flush() |
String |
getFileTypeDescription() |
String |
getFileTypeId() |
static boolean |
isClibraryPresent()
Test if the netcdf C library is present and loaded
|
boolean |
isValidFile(RandomAccessFile raf) |
static void |
main(String[] args) |
protected static String |
nullify(String s)
Convert a zero-length string to null
|
void |
open(RandomAccessFile raf,
NetcdfFile ncfile,
CancelTask cancelTask) |
NetcdfFile |
open(String location) |
void |
openForWriting(RandomAccessFile raf,
NetcdfFile ncfile,
CancelTask cancelTask) |
Array |
readData(Variable v2,
Section section) |
boolean |
rewriteHeader(boolean largeFile) |
void |
setChunker(Nc4Chunking chunker) |
static void |
setDebugFlags(DebugFlags flags) |
void |
setFill(boolean fill) |
static void |
setLibraryAndPath(String jna_path,
String lib_name)
set the path and name of the netcdf c library.
|
static void |
setWarnOff()
Suppress warning messages
|
void |
updateAttribute(Variable v2,
Attribute att) |
void |
writeData(Variable v2,
Section section,
Array values) |
getDetailInfo, getFileTypeVersion, getLastModified, getStructureIterator, readSection, readToByteChannel, readToOutputStream, sendIospMessage, streamToByteChannel, syncExtend, toStringDebugclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetDetailInfo, getFileTypeVersion, getStructureIterator, readSection, readToByteChannel, readToOutputStream, sendIospMessage, streamToByteChannel, syncExtend, toStringDebugpublic static final String JNA_PATH
public static final String JNA_PATH_ENV
protected static String DEFAULTNETCDF4LIBNAME
protected static String netcdf4libname
public Nc4Iosp()
public Nc4Iosp(NetcdfFileWriter.Version version)
public static boolean isClibraryPresent()
protected static String defaultNetcdf4Library()
public static void setLibraryAndPath(String jna_path, String lib_name)
jna_path - path to shared librarieslib_name - library nameprotected static String nullify(String s)
s - the string to check for lengthpublic static void setWarnOff()
public static void setDebugFlags(DebugFlags flags)
public void setChunker(Nc4Chunking chunker)
public boolean isValidFile(RandomAccessFile raf) throws IOException
isValidFile in interface IOServiceProviderIOExceptionpublic String getFileTypeId()
getFileTypeId in interface IOServiceProviderpublic String getFileTypeDescription()
getFileTypeDescription in interface IOServiceProviderpublic void close()
throws IOException
close in interface IOServiceProviderclose in class AbstractIOServiceProviderIOExceptionpublic void open(RandomAccessFile raf, NetcdfFile ncfile, CancelTask cancelTask) throws IOException
open in interface IOServiceProvideropen in class AbstractIOServiceProviderIOExceptionpublic void openForWriting(RandomAccessFile raf, NetcdfFile ncfile, CancelTask cancelTask) throws IOException
openForWriting in interface IOServiceProviderWriterIOExceptionpublic Array readData(Variable v2, Section section) throws IOException, InvalidRangeException
readData in interface IOServiceProviderIOExceptionInvalidRangeExceptionpublic void create(String filename, NetcdfFile ncfile, int extra, long preallocateSize, boolean largeFile) throws IOException
create in interface IOServiceProviderWriterIOExceptionpublic void writeData(Variable v2, Section section, Array values) throws IOException, InvalidRangeException
writeData in interface IOServiceProviderWriterIOExceptionInvalidRangeExceptionpublic void flush()
throws IOException
flush in interface IOServiceProviderWriterIOExceptionpublic void setFill(boolean fill)
setFill in interface IOServiceProviderWriterpublic boolean rewriteHeader(boolean largeFile)
throws IOException
rewriteHeader in interface IOServiceProviderWriterIOExceptionpublic void updateAttribute(Variable v2, Attribute att) throws IOException
updateAttribute in interface IOServiceProviderWriterIOExceptionpublic NetcdfFile open(String location) throws Exception
ExceptionCopyright © 1999–2014 UCAR/Unidata. All rights reserved.