public enum NetcdfFileFormat extends java.lang.Enum<NetcdfFileFormat>
Enum Constant and Description |
---|
INVALID |
NCSTREAM |
NETCDF3 |
NETCDF3_64BIT_DATA |
NETCDF3_64BIT_OFFSET |
NETCDF4 |
NETCDF4_CLASSIC |
Modifier and Type | Method and Description |
---|---|
static NetcdfFileFormat |
findNetcdfFormatType(RandomAccessFile raf)
Figure out what kind of netcdf-related file we have.
|
java.lang.String |
formatName() |
boolean |
isExtendedModel() |
boolean |
isNetcdf3Format() |
boolean |
isNetcdf4Format() |
static boolean |
isValidNetcdfObjectName(java.lang.String name)
Determine if the given name can be used for a NetCDF object, i.e.
|
static java.lang.String |
makeValidNetcdfObjectName(java.lang.String name)
Convert a name to a legal netcdf-3 name.
|
static boolean |
memequal(byte[] b1,
byte[] b2,
int len) |
static NetcdfFileFormat |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static NetcdfFileFormat[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
int |
version() |
public static final NetcdfFileFormat INVALID
public static final NetcdfFileFormat NCSTREAM
public static final NetcdfFileFormat NETCDF3
public static final NetcdfFileFormat NETCDF3_64BIT_DATA
public static final NetcdfFileFormat NETCDF3_64BIT_OFFSET
public static final NetcdfFileFormat NETCDF4
public static final NetcdfFileFormat NETCDF4_CLASSIC
public static NetcdfFileFormat findNetcdfFormatType(RandomAccessFile raf) throws java.io.IOException
raf
- to test typejava.io.IOException
public java.lang.String formatName()
public boolean isExtendedModel()
public boolean isNetcdf3Format()
public boolean isNetcdf4Format()
public static boolean isValidNetcdfObjectName(java.lang.String name)
([a-zA-Z0-9_]|{UTF8})([^\x00-\x1F\x7F/]|{UTF8})*where UTF8 represents a multi-byte UTF-8 encoding. Also, no trailing spaces are permitted in names. We do not allow '/' because HDF5 does not permit slashes in names as slash is used as a group separator. If UTF-8 is supported, then a multi-byte UTF-8 character can occur anywhere within an identifier.
name
- the name to validate.true
if the name is valid.public static java.lang.String makeValidNetcdfObjectName(java.lang.String name)
name
- the name to convert.isValidNetcdfObjectName(String)
public static boolean memequal(byte[] b1, byte[] b2, int len)
public static NetcdfFileFormat valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullpublic static NetcdfFileFormat[] values()
for (NetcdfFileFormat c : NetcdfFileFormat.values()) System.out.println(c);
public int version()