public class HdfWriterFactory
extends java.lang.Object
The HdfWriterFactory class contains static methods used to write elements to an HDF5 file.
Constructor and Description |
---|
HdfWriterFactory() |
Modifier and Type | Method and Description |
---|---|
static ncsa.hdf.object.h5.H5Datatype |
createFloatH5Datatype(ncsa.hdf.object.h5.H5File h5File)
Creates and returns a 64-bit floating point H5Datatype from h5File.
|
static ncsa.hdf.object.h5.H5Group |
createH5Group(ncsa.hdf.object.h5.H5File h5File,
java.lang.String name,
ncsa.hdf.object.h5.H5Group parentH5Group)
Creates and returns a child H5Group called name for parentH5Group using
the h5File.
|
static ncsa.hdf.object.h5.H5Datatype |
createIntegerH5Datatype(ncsa.hdf.object.h5.H5File h5File)
Creates and returns an integer H5Datatype from h5File.
|
static boolean |
writeDoubleAttribute(ncsa.hdf.object.h5.H5File h5File,
ncsa.hdf.object.h5.H5Group h5Group,
java.lang.String name,
double value)
Writes an Attribute to h5Group called name with a double value using
h5File.
|
static boolean |
writeIntegerAttribute(ncsa.hdf.object.h5.H5File h5File,
ncsa.hdf.object.h5.H5Group h5Group,
java.lang.String name,
int value)
Writes an Attribute to h5Group called name with an integer value using
h5File.
|
static boolean |
writeStringAttribute(ncsa.hdf.object.h5.H5File h5File,
ncsa.hdf.object.h5.H5Group h5Group,
java.lang.String name,
java.lang.String value)
Writes an Attribute to h5Group called name with a String value using
h5File.
|
public static ncsa.hdf.object.h5.H5Group createH5Group(ncsa.hdf.object.h5.H5File h5File, java.lang.String name, ncsa.hdf.object.h5.H5Group parentH5Group)
Creates and returns a child H5Group called name for parentH5Group using the h5File. If h5File is null or can not be opened, then null is returned. If name is null or is an empty String, then null is returned. If parentH5Group is null, then null is returned. If an exception is thrown, then null is returned.
h5File
- An H5File.
name
- The name of the new H5Group.
parentH5Group
- The parent H5Group of the new H5Group.
An H5Group called name which is a child of parentH5Group.
public static ncsa.hdf.object.h5.H5Datatype createFloatH5Datatype(ncsa.hdf.object.h5.H5File h5File)
Creates and returns a 64-bit floating point H5Datatype from h5File. If h5File is null or can not be opened, then null is returned. If an exception is thrown, then null is returned.
h5File
- An H5File.
A 64-bit floating point H5Datatype.
public static ncsa.hdf.object.h5.H5Datatype createIntegerH5Datatype(ncsa.hdf.object.h5.H5File h5File)
Creates and returns an integer H5Datatype from h5File. If h5File is null or can not be opened, then null is returned. If an exception is thrown, then null is returned.
h5File
- An H5File.
A 32-bit integer H5Datatype.
public static boolean writeDoubleAttribute(ncsa.hdf.object.h5.H5File h5File, ncsa.hdf.object.h5.H5Group h5Group, java.lang.String name, double value)
Writes an Attribute to h5Group called name with a double value using h5File. If h5File is null or can not be opened, then false is returned. If name is null or is an empty String, then false is returned. If h5Group is null, then false is returned. If an exception is thrown, then false is returned. Otherwise, true is returned.
h5File
- An H5File.
h5Group
- The H5Group to write the attribute to.
name
- The name of the Attribute.
value
- The value of the Attribute.
If h5File is null or can not be opened, then false is returned. If name is null or is an empty String, then false is returned. If h5Group is null, then false is returned. If an exception is thrown, then false is returned. Otherwise, true is returned.
public static boolean writeIntegerAttribute(ncsa.hdf.object.h5.H5File h5File, ncsa.hdf.object.h5.H5Group h5Group, java.lang.String name, int value)
Writes an Attribute to h5Group called name with an integer value using h5File. If h5File is null or can not be opened, then false is returned. If name is null or is an empty String, then false is returned. If h5Group is null, then false is returned. If an exception is thrown, then false is returned. Otherwise, true is returned.
h5File
- An H5File.
h5Group
- The H5Group to write the attribute to.
name
- The name of the Attribute.
value
- The value of the Attribute.
If h5File is null or can not be opened, then false is returned. If name is null or is an empty String, then false is returned. If h5Group is null, then false is returned. If an exception is thrown, then false is returned. Otherwise, true is returned.
public static boolean writeStringAttribute(ncsa.hdf.object.h5.H5File h5File, ncsa.hdf.object.h5.H5Group h5Group, java.lang.String name, java.lang.String value)
Writes an Attribute to h5Group called name with a String value using h5File. If h5File is null or can not be opened, then false is returned. If name is null or is an empty String, then false is returned. If value is null or is an empty String, then false is returned. If an exception is thrown, then false is returned. If h5Group is null, then false is returned. Otherwise, true is returned.
h5File
- An H5File.
h5Group
- The H5Group to write the attribute to.
name
- The name of the Attribute.
value
- The value of the Attribute.
If h5File is null or can not be opened, then false is returned. If name is null or is an empty String, then false is returned. If value is null or is an empty String, then false is returned. If an exception is thrown, then false is returned. If h5Group is null, then false is returned. Otherwise, true is returned.