summaryrefslogtreecommitdiffstats
path: root/java
diff options
context:
space:
mode:
authorAllen Byrne <50328838+byrnHDF@users.noreply.github.com>2023-06-15 14:50:02 (GMT)
committerGitHub <noreply@github.com>2023-06-15 14:50:02 (GMT)
commit4a6872cbf62380ec0ee3394d5e0710de2216b21d (patch)
tree4f267f9d4f3087deeb23a14084128b23741006a2 /java
parentdee5daa7a1a6e52e4fe54e18ea31b44ce5b42f88 (diff)
downloadhdf5-4a6872cbf62380ec0ee3394d5e0710de2216b21d.zip
hdf5-4a6872cbf62380ec0ee3394d5e0710de2216b21d.tar.gz
hdf5-4a6872cbf62380ec0ee3394d5e0710de2216b21d.tar.bz2
Merges from develop/1.14 (#3118)
* Fix release action that allows files to be uploaded. Add autotools h5copy help test. Update cmake tools.cmake file for clang-tidy. CMake build is missing H5FDsubfiling.h macros improved for configure output capture. Remove obsolete files * Revert parallel config with TS * Fix doxygen warnings
Diffstat (limited to 'java')
-rw-r--r--java/CMakeLists.txt2
-rw-r--r--java/examples/datasets/CMakeLists.txt26
-rw-r--r--java/examples/datatypes/CMakeLists.txt17
-rw-r--r--java/examples/groups/CMakeLists.txt30
-rw-r--r--java/examples/intro/CMakeLists.txt17
-rw-r--r--java/src/Makefile.am9
-rw-r--r--java/src/hdf/hdf5lib/CMakeLists.txt13
-rw-r--r--java/src/hdf/hdf5lib/H5.java12
-rw-r--r--java/src/hdf/hdf5lib/HDF5GroupInfo.java188
-rw-r--r--java/src/hdf/hdf5lib/HDFArray.java2
-rw-r--r--java/src/hdf/hdf5lib/callbacks/package-info.java1
-rw-r--r--java/src/hdf/hdf5lib/exceptions/package-info.java3
-rw-r--r--java/src/hdf/hdf5lib/package-info.java1
-rw-r--r--java/src/hdf/hdf5lib/structs/H5FD_hdfs_fapl_t.java1
-rw-r--r--java/src/hdf/hdf5lib/structs/H5FD_ros3_fapl_t.java1
-rw-r--r--java/src/hdf/hdf5lib/structs/package-info.java1
-rw-r--r--java/src/jni/h5fImp.c8
-rw-r--r--java/src/jni/h5lImp.c8
-rw-r--r--java/src/jni/h5pDAPLImp.c2
-rw-r--r--java/src/jni/h5pFAPLImp.c2
-rw-r--r--java/src/jni/h5tImp.c2
21 files changed, 111 insertions, 235 deletions
diff --git a/java/CMakeLists.txt b/java/CMakeLists.txt
index cc22d9e..af1aaff 100644
--- a/java/CMakeLists.txt
+++ b/java/CMakeLists.txt
@@ -1,7 +1,7 @@
cmake_minimum_required (VERSION 3.12)
project (HDF5_JAVA C Java)
-set (CMAKE_MODULE_PATH "${HDF_RESOURCES_DIR};${HDF_RESOURCES_DIR}")
+set (CMAKE_MODULE_PATH "${HDF_RESOURCES_DIR}")
find_package (Java)
#-----------------------------------------------------------------------------
diff --git a/java/examples/datasets/CMakeLists.txt b/java/examples/datasets/CMakeLists.txt
index e63ead0..6ed03ca 100644
--- a/java/examples/datasets/CMakeLists.txt
+++ b/java/examples/datasets/CMakeLists.txt
@@ -82,6 +82,7 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
get_property (target_name TARGET ${HDF5_JAVA_JNI_LIB_TARGET} PROPERTY OUTPUT_NAME)
set (CMD_ARGS "-Dhdf.hdf5lib.H5.loadLibraryName=${target_name}$<$<CONFIG:Debug>:${CMAKE_DEBUG_POSTFIX}>;")
+ set (last_test "")
foreach (example ${HDF_JAVA_EXAMPLES})
if (example STREQUAL "H5Ex_D_External")
add_test (
@@ -93,9 +94,13 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
else ()
add_test (
NAME JAVA_datasets-${example}-clear-objects
- COMMAND ${CMAKE_COMMAND} -E remove ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
)
endif ()
+ if (last_test)
+ set_tests_properties (JAVA_datasets-${example}-clear-objects PROPERTIES DEPENDS ${last_test})
+ endif ()
add_test (
NAME JAVA_datasets-${example}-copy-objects
@@ -122,5 +127,24 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
set_tests_properties (JAVA_datasets-${example} PROPERTIES
DEPENDS JAVA_datasets-${example}-copy-objects
)
+
+ if (example STREQUAL "H5Ex_D_External")
+ add_test (
+ NAME JAVA_datasets-${example}-clean-objects
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.data
+ )
+ else ()
+ add_test (
+ NAME JAVA_datasets-${example}-clean-objects
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
+ )
+ endif ()
+ set_tests_properties (JAVA_datasets-${example}-clean-objects PROPERTIES
+ DEPENDS JAVA_datasets-${example}
+ )
+ set (last_test "JAVA_datasets-${example}-clean-objects")
endforeach ()
endif ()
diff --git a/java/examples/datatypes/CMakeLists.txt b/java/examples/datatypes/CMakeLists.txt
index 4512221..47df1f8 100644
--- a/java/examples/datatypes/CMakeLists.txt
+++ b/java/examples/datatypes/CMakeLists.txt
@@ -67,11 +67,16 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
get_property (target_name TARGET ${HDF5_JAVA_JNI_LIB_TARGET} PROPERTY OUTPUT_NAME)
set (CMD_ARGS "-Dhdf.hdf5lib.H5.loadLibraryName=${target_name}$<$<CONFIG:Debug>:${CMAKE_DEBUG_POSTFIX}>;")
+ set (last_test "")
foreach (example ${HDF_JAVA_EXAMPLES})
add_test (
NAME JAVA_datatypes-${example}-clear-objects
- COMMAND ${CMAKE_COMMAND} -E remove ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
)
+ if (last_test)
+ set_tests_properties (JAVA_datatypes-${example}-clear-objects PROPERTIES DEPENDS ${last_test})
+ endif ()
add_test (
NAME JAVA_datatypes-${example}-copy-objects
@@ -97,5 +102,15 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
set_tests_properties (JAVA_datatypes-${example} PROPERTIES
DEPENDS JAVA_datatypes-${example}-copy-objects
)
+
+ add_test (
+ NAME JAVA_datatypes-${example}-clean-objects
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
+ )
+ set_tests_properties (JAVA_datatypes-${example}-clean-objects PROPERTIES
+ DEPENDS JAVA_datatypes-${example}
+ )
+ set (last_test "JAVA_datatypes-${example}-clean-objects")
endforeach ()
endif ()
diff --git a/java/examples/groups/CMakeLists.txt b/java/examples/groups/CMakeLists.txt
index 9f20abf..fdaf95c 100644
--- a/java/examples/groups/CMakeLists.txt
+++ b/java/examples/groups/CMakeLists.txt
@@ -66,6 +66,7 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
get_property (target_name TARGET ${HDF5_JAVA_JNI_LIB_TARGET} PROPERTY OUTPUT_NAME)
set (CMD_ARGS "-Dhdf.hdf5lib.H5.loadLibraryName=${target_name}$<$<CONFIG:Debug>:${CMAKE_DEBUG_POSTFIX}>;")
+ set (last_test "")
foreach (example ${HDF_JAVA_EXAMPLES})
if (NOT example STREQUAL "H5Ex_G_Iterate" AND NOT example STREQUAL "H5Ex_G_Visit")
if (example STREQUAL "H5Ex_G_Compact")
@@ -78,7 +79,8 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
else ()
add_test (
NAME JAVA_groups-${example}-clear-objects
- COMMAND ${CMAKE_COMMAND} -E remove ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
)
endif ()
else ()
@@ -87,6 +89,9 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
COMMAND ${CMAKE_COMMAND} -E echo "${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5 exists"
)
endif ()
+ if (last_test)
+ set_tests_properties (JAVA_groups-${example}-clear-objects PROPERTIES DEPENDS ${last_test})
+ endif ()
add_test (
NAME JAVA_groups-${example}-copy-objects
@@ -112,5 +117,28 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
set_tests_properties (JAVA_groups-${example} PROPERTIES
DEPENDS JAVA_groups-${example}-copy-objects
)
+
+ if (NOT example STREQUAL "H5Ex_G_Iterate" AND NOT example STREQUAL "H5Ex_G_Visit")
+ if (example STREQUAL "H5Ex_G_Compact")
+ add_test (
+ NAME JAVA_groups-${example}-clean-objects
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}1.h5
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}2.h5
+ )
+ else ()
+ add_test (
+ NAME JAVA_groups-${example}-clean-objects
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
+ )
+ endif ()
+ set_tests_properties (JAVA_groups-${example}-clean-objects PROPERTIES
+ DEPENDS JAVA_groups-${example}
+ )
+ set (last_test "JAVA_groups-${example}-clean-objects")
+ else ()
+ set (last_test "JAVA_groups-${example}")
+ endif ()
endforeach ()
endif ()
diff --git a/java/examples/intro/CMakeLists.txt b/java/examples/intro/CMakeLists.txt
index a5e2a67..f744559 100644
--- a/java/examples/intro/CMakeLists.txt
+++ b/java/examples/intro/CMakeLists.txt
@@ -56,11 +56,16 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
get_property (target_name TARGET ${HDF5_JAVA_JNI_LIB_TARGET} PROPERTY OUTPUT_NAME)
set (CMD_ARGS "-Dhdf.hdf5lib.H5.loadLibraryName=${target_name}$<$<CONFIG:Debug>:${CMAKE_DEBUG_POSTFIX}>;")
+ set (last_test "")
foreach (example ${HDF_JAVA_EXAMPLES})
add_test (
NAME JAVA_intro-${example}-clear-objects
- COMMAND ${CMAKE_COMMAND} -E remove ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
)
+ if (last_test)
+ set_tests_properties (JAVA_intro-${example}-clear-objects PROPERTIES DEPENDS ${last_test})
+ endif ()
add_test (
NAME JAVA_intro-${example}-copy-objects
@@ -87,6 +92,16 @@ if (BUILD_TESTING AND HDF5_TEST_EXAMPLES AND HDF5_TEST_SERIAL)
set_tests_properties (JAVA_intro-${example} PROPERTIES
DEPENDS JAVA_intro-${example}-copy-objects
)
+
+ add_test (
+ NAME JAVA_intro-${example}-clean-objects
+ COMMAND ${CMAKE_COMMAND} -E remove
+ ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5
+ )
+ set_tests_properties (JAVA_intro-${example}-clean-objects PROPERTIES
+ DEPENDS JAVA_intro-${example}
+ )
+ set (last_test "JAVA_intro-${example}-clean-objects")
endforeach ()
endif ()
diff --git a/java/src/Makefile.am b/java/src/Makefile.am
index c9b0d7c..67d21f8 100644
--- a/java/src/Makefile.am
+++ b/java/src/Makefile.am
@@ -108,30 +108,25 @@ hdf5_java_JAVA = \
${pkgpath}/structs/H5AC_cache_config_t.java \
${pkgpath}/H5.java \
${pkgpath}/HDF5Constants.java \
- ${pkgpath}/HDF5GroupInfo.java \
${pkgpath}/HDFArray.java \
${pkgpath}/HDFNativeData.java
-$(jarfile): classhdf5_java.stamp classes docs
+$(jarfile): classhdf5_java.stamp classes
$(JAR) cvf $@ -C $(JAVAROOT)/ $(pkgpath)
hdf5_java_DATA = $(jarfile)
-.PHONY: docs classes
+.PHONY: classes
WINDOWTITLE = 'HDF5 Java'
DOCTITLE = '<h1>HDF5 Java Wrapper</h1>'
SRCDIR = '$(pkgpath)'
-docs:
- $(JAVADOC) -sourcepath $(srcdir) -d javadoc -Xdoclint:none -use -splitIndex -windowtitle $(WINDOWTITLE) -doctitle $(DOCTITLE) -J-Xmx180m -verbose -overview $(top_srcdir)/java/src/hdf/overview.html -classpath $(CLASSPATH_ENV) hdf.hdf5lib
-
CLEANFILES = classhdf5_java.stamp $(jarfile) $(JAVAROOT)/$(pkgpath)/callbacks/*.class $(JAVAROOT)/$(pkgpath)/exceptions/*.class $(JAVAROOT)/$(pkgpath)/structs/*.class $(JAVAROOT)/$(pkgpath)/*.class
clean:
rm -rf $(JAVAROOT)/*
rm -f $(jarfile)
- rm -rf javadoc
rm -f classhdf5_java.stamp
diff --git a/java/src/hdf/hdf5lib/CMakeLists.txt b/java/src/hdf/hdf5lib/CMakeLists.txt
index 1afc8b0..1738bcf 100644
--- a/java/src/hdf/hdf5lib/CMakeLists.txt
+++ b/java/src/hdf/hdf5lib/CMakeLists.txt
@@ -101,7 +101,6 @@ set (HDF5_JAVADOC_HDF_HDF5_STRUCTS_SOURCES
set (HDF5_JAVA_HDF_HDF5_SOURCES
HDFArray.java
HDF5Constants.java
- HDF5GroupInfo.java
HDFNativeData.java
H5.java
)
@@ -135,15 +134,3 @@ set_target_properties (${HDF5_JAVA_HDF5_LIB_TARGET} PROPERTIES FOLDER libraries/
if (HDF5_ENABLE_FORMATTERS)
clang_format (HDF5_JAVA_SRC_FORMAT ${HDF5_JAVA_HDF_HDF5_CALLBACKS_SOURCES} ${HDF5_JAVA_HDF_HDF5_EXCEPTIONS_SOURCES} ${HDF5_JAVA_HDF_HDF5_STRUCTS_SOURCES} ${HDF5_JAVA_HDF_HDF5_SOURCES})
endif ()
-
-create_javadoc(hdf5_java_doc
- FILES ${HDF5_JAVADOC_HDF_HDF5_CALLBACKS_SOURCES} ${HDF5_JAVADOC_HDF_HDF5_EXCEPTIONS_SOURCES} ${HDF5_JAVADOC_HDF_HDF5_STRUCTS_SOURCES} ${HDF5_JAVADOC_HDF_HDF5_SOURCES}
- OVERVIEW ${HDF5_JAVA_HDF5_SRC_DIR}/overview.html
- CLASSPATH ${CMAKE_JAVA_INCLUDE_PATH}
- WINDOWTITLE "HDF5 Java"
- DOCTITLE "<h1>HDF5 Java Wrapper</h1>"
- INSTALLPATH ${HDF5_INSTALL_DOC_DIR}
- AUTHOR TRUE
- USE TRUE
- VERSION TRUE
-)
diff --git a/java/src/hdf/hdf5lib/H5.java b/java/src/hdf/hdf5lib/H5.java
index bb42106..90c4575 100644
--- a/java/src/hdf/hdf5lib/H5.java
+++ b/java/src/hdf/hdf5lib/H5.java
@@ -228,7 +228,7 @@ import hdf.hdf5lib.structs.H5O_token_t;
* which prints out the HDF5 error stack, as described in the HDF5 C API <i><b>@ref H5Eprint()</b>.</i> This
* may be used by Java exception handlers to print out the HDF5 error stack. <hr>
*
- * @version HDF5 1.10.10 <br />
+ * @version HDF5 1.12.3 <br />
* <b>See also: </b>
* @ref HDFARRAY hdf.hdf5lib.HDFArray<br />
* @ref HDF5CONST hdf.hdf5lib.HDF5Constants<br />
@@ -5082,8 +5082,8 @@ public class H5 implements java.io.Serializable {
*
* @param name
* IN: File name to check.
- * @param file_id
- * IN: File identifier for a currently-open HDF5 file
+ * @param fapl_id
+ * IN: File access property list identifier
*
* @return true if file is accessible, false if not.
*
@@ -5092,7 +5092,7 @@ public class H5 implements java.io.Serializable {
* @exception NullPointerException
* name is null.
**/
- public synchronized static native boolean H5Fis_accessible(String name, long file_id)
+ public synchronized static native boolean H5Fis_accessible(String name, long fapl_id)
throws HDF5LibraryException, NullPointerException;
/**
@@ -13773,7 +13773,7 @@ public class H5 implements java.io.Serializable {
/**
* @ingroup JH5T
*
- * H5Tcreate creates a new dataype of the specified class with the specified number of bytes.
+ * H5Tcreate creates a new datatype of the specified class with the specified number of bytes.
*
* @param tclass
* IN: Class of datatype to create.
@@ -15228,7 +15228,7 @@ public class H5 implements java.io.Serializable {
/**
* @ingroup JH5T
*
- * H5Tvlen_create creates a new variable-length (VL) dataype.
+ * H5Tvlen_create creates a new variable-length (VL) datatype.
*
* @param base_id
* IN: Identifier of parent datatype.
diff --git a/java/src/hdf/hdf5lib/HDF5GroupInfo.java b/java/src/hdf/hdf5lib/HDF5GroupInfo.java
deleted file mode 100644
index 50c7db0..0000000
--- a/java/src/hdf/hdf5lib/HDF5GroupInfo.java
+++ /dev/null
@@ -1,188 +0,0 @@
-/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
- * Copyright by The HDF Group. *
- * Copyright by the Board of Trustees of the University of Illinois. *
- * All rights reserved. *
- * *
- * This file is part of HDF5. The full HDF5 copyright notice, including *
- * terms governing use, modification, and redistribution, is contained in *
- * the COPYING file, which can be found at the root of the source code *
- * distribution tree, or in https://www.hdfgroup.org/licenses. *
- * If you do not have access to either file, you may request a copy from *
- * help@hdfgroup.org. *
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-
-package hdf.hdf5lib;
-
-/**
- * <p>
- * This class is a container for the information reported about an HDF5 Object
- * from the H5Gget_obj_info() method.
- * <p>
- * The fileno and objno fields contain four values which uniquely identify an
- * object among those HDF5 files which are open: if all four values are the same
- * between two objects, then the two objects are the same (provided both files
- * are still open). The nlink field is the number of hard links to the object or
- * zero when information is being returned about a symbolic link (symbolic links
- * do not have hard links but all other objects always have at least one). The
- * type field contains the type of the object, one of H5G_GROUP, H5G_DATASET, or
- * H5G_LINK. The mtime field contains the modification time. If information is
- * being returned about a symbolic link then linklen will be the length of the
- * link value (the name of the pointed-to object with the null terminator);
- * otherwise linklen will be zero. Other fields may be added to this structure
- * in the future.
- *
- * @deprecated Not for public use. It is not used by the library.
- * This class assumes that an object can contain four values which uniquely identify an
- * object among those HDF5 files which are open. This is no longer valid in future
- * HDF5 releases.
- */
-
-@Deprecated
-public class HDF5GroupInfo {
- long[] fileno;
- long[] objno;
- int nlink;
- int type;
- long mtime;
- int linklen;
-
- /**
- * Container for the information reported about an HDF5 Object
- * from the H5Gget_obj_info() method
- */
- public HDF5GroupInfo()
- {
- fileno = new long[2];
- objno = new long[2];
- nlink = -1;
- type = -1;
- mtime = 0;
- linklen = 0;
- }
-
- /**
- * Sets the HDF5 group information. Used by the JHI5.
- *
- * @param fn
- * File id number
- * @param on
- * Object id number
- * @param nl
- * Number of links
- * @param t
- * Type of the object
- * @param mt
- * Modification time
- * @param len
- * Length of link
- **/
- public void setGroupInfo(long[] fn, long[] on, int nl, int t, long mt, int len)
- {
- fileno = fn;
- objno = on;
- nlink = nl;
- type = t;
- mtime = mt;
- linklen = len;
- }
-
- /** Resets all the group information to defaults. */
- public void reset()
- {
- fileno[0] = 0;
- fileno[1] = 0;
- objno[0] = 0;
- objno[1] = 0;
- nlink = -1;
- type = -1;
- mtime = 0;
- linklen = 0;
- }
-
- /**
- * fileno accessors
- * @return the file number if successful
- */
- public long[] getFileno() { return fileno; }
-
- /**
- * accessors
- * @return the object number if successful
- */
- public long[] getObjno() { return objno; }
-
- /**
- * accessors
- * @return type of group if successful
- */
- public int getType() { return type; }
-
- /**
- * accessors
- * @return the number of links in the group if successful
- */
- public int getNlink() { return nlink; }
-
- /**
- * accessors
- * @return the modified time value if successful
- */
- public long getMtime() { return mtime; }
-
- /**
- * accessors
- * @return a length of link name if successful
- */
- public int getLinklen() { return linklen; }
-
- /**
- * The fileno and objno fields contain four values which uniquely identify
- * an object among those HDF5 files.
- */
- @Override
- public boolean equals(Object obj)
- {
- if (!(obj instanceof HDF5GroupInfo)) {
- return false;
- }
-
- HDF5GroupInfo target = (HDF5GroupInfo)obj;
- if ((fileno[0] == target.fileno[0]) && (fileno[1] == target.fileno[1]) &&
- (objno[0] == target.objno[0]) && (objno[1] == target.objno[1])) {
- return true;
- }
- else {
- return false;
- }
- }
-
- /**
- * Returns the object id.
- *
- * @return the object id
- */
- public long getOID() { return objno[0]; }
-
- /**
- * /** Converts this object to a String representation.
- *
- * @return a string representation of this object
- */
- @Override
- public String toString()
- {
- String fileStr = "fileno=null";
- String objStr = "objno=null";
-
- if (fileno != null) {
- fileStr = "fileno[0]=" + fileno[0] + ",fileno[1]=" + fileno[1];
- }
-
- if (objno != null) {
- objStr = "objno[0]=" + objno[0] + ",objno[1]=" + objno[1];
- }
-
- return getClass().getName() + "[" + fileStr + "," + objStr + ",type=" + type + ",nlink=" + nlink +
- ",mtime=" + mtime + ",linklen=" + linklen + "]";
- }
-}
diff --git a/java/src/hdf/hdf5lib/HDFArray.java b/java/src/hdf/hdf5lib/HDFArray.java
index 28d5117..637a896 100644
--- a/java/src/hdf/hdf5lib/HDFArray.java
+++ b/java/src/hdf/hdf5lib/HDFArray.java
@@ -455,6 +455,7 @@ public class HDFArray {
new HDF5JavaException("HDFArray: unsupported Object type: " + ArrayDescriptor.NT);
throw(ex);
}
+ break;
} // end of statement for arrays of boxed objects
default:
HDF5JavaException ex =
@@ -527,6 +528,7 @@ public class HDFArray {
new HDF5JavaException("HDFArray: unsupported Object type: " + ArrayDescriptor.NT);
throw(ex);
}
+ break;
} // end of statement for arrays of boxed numerics
} // end of switch statement for arrays of primitives
diff --git a/java/src/hdf/hdf5lib/callbacks/package-info.java b/java/src/hdf/hdf5lib/callbacks/package-info.java
index 5ef3fab..bf7bf3c 100644
--- a/java/src/hdf/hdf5lib/callbacks/package-info.java
+++ b/java/src/hdf/hdf5lib/callbacks/package-info.java
@@ -1,6 +1,5 @@
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Copyright by The HDF Group. *
- * *
* All rights reserved. *
* *
* This file is part of HDF5. The full HDF5 copyright notice, including *
diff --git a/java/src/hdf/hdf5lib/exceptions/package-info.java b/java/src/hdf/hdf5lib/exceptions/package-info.java
index 2ac7806..784e57d 100644
--- a/java/src/hdf/hdf5lib/exceptions/package-info.java
+++ b/java/src/hdf/hdf5lib/exceptions/package-info.java
@@ -1,6 +1,5 @@
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Copyright by The HDF Group. *
- * *
* All rights reserved. *
* *
* This file is part of HDF5. The full HDF5 copyright notice, including *
@@ -29,4 +28,4 @@
* error code returned by the HDF5 library.
*
*/
-package hdf.hdf5lib.exceptions; \ No newline at end of file
+package hdf.hdf5lib.exceptions;
diff --git a/java/src/hdf/hdf5lib/package-info.java b/java/src/hdf/hdf5lib/package-info.java
index 7ae4df9..e742197 100644
--- a/java/src/hdf/hdf5lib/package-info.java
+++ b/java/src/hdf/hdf5lib/package-info.java
@@ -1,6 +1,5 @@
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Copyright by The HDF Group. *
- * *
* All rights reserved. *
* *
* This file is part of HDF5. The full HDF5 copyright notice, including *
diff --git a/java/src/hdf/hdf5lib/structs/H5FD_hdfs_fapl_t.java b/java/src/hdf/hdf5lib/structs/H5FD_hdfs_fapl_t.java
index 181d681..9861334 100644
--- a/java/src/hdf/hdf5lib/structs/H5FD_hdfs_fapl_t.java
+++ b/java/src/hdf/hdf5lib/structs/H5FD_hdfs_fapl_t.java
@@ -1,6 +1,5 @@
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Copyright by The HDF Group. *
- * *
* All rights reserved. *
* *
* This file is part of HDF5. The full HDF5 copyright notice, including *
diff --git a/java/src/hdf/hdf5lib/structs/H5FD_ros3_fapl_t.java b/java/src/hdf/hdf5lib/structs/H5FD_ros3_fapl_t.java
index 67c2463..62b2921 100644
--- a/java/src/hdf/hdf5lib/structs/H5FD_ros3_fapl_t.java
+++ b/java/src/hdf/hdf5lib/structs/H5FD_ros3_fapl_t.java
@@ -1,6 +1,5 @@
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Copyright by The HDF Group. *
- * *
* All rights reserved. *
* *
* This file is part of HDF5. The full HDF5 copyright notice, including *
diff --git a/java/src/hdf/hdf5lib/structs/package-info.java b/java/src/hdf/hdf5lib/structs/package-info.java
index a3ec6cd..7bd3dee 100644
--- a/java/src/hdf/hdf5lib/structs/package-info.java
+++ b/java/src/hdf/hdf5lib/structs/package-info.java
@@ -1,6 +1,5 @@
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Copyright by The HDF Group. *
- * *
* All rights reserved. *
* *
* This file is part of HDF5. The full HDF5 copyright notice, including *
diff --git a/java/src/jni/h5fImp.c b/java/src/jni/h5fImp.c
index 8cfecc5..af06bdc 100644
--- a/java/src/jni/h5fImp.c
+++ b/java/src/jni/h5fImp.c
@@ -188,7 +188,7 @@ done:
* Signature: (Ljava/lang/String;J)Z
*/
JNIEXPORT jboolean JNICALL
-Java_hdf_hdf5lib_H5_H5Fis_1accessible(JNIEnv *env, jclass clss, jstring name, jlong file_id)
+Java_hdf_hdf5lib_H5_H5Fis_1accessible(JNIEnv *env, jclass clss, jstring name, jlong fapl_id)
{
const char *fileName = NULL;
htri_t bval = JNI_FALSE;
@@ -200,7 +200,7 @@ Java_hdf_hdf5lib_H5_H5Fis_1accessible(JNIEnv *env, jclass clss, jstring name, jl
PIN_JAVA_STRING(ENVONLY, name, fileName, NULL, "H5Fis_accessible: file name not pinned");
- if ((bval = H5Fis_accessible(fileName, (hid_t)file_id)) < 0)
+ if ((bval = H5Fis_accessible(fileName, (hid_t)fapl_id)) < 0)
H5_LIBRARY_ERROR(ENVONLY);
bval = (bval > 0) ? JNI_TRUE : JNI_FALSE;
@@ -741,7 +741,7 @@ Java_hdf_hdf5lib_H5_H5Fset_1dset_1no_1attrs_1hint(JNIEnv *env, jclass clss, jlon
done:
return;
-}
+} /* end Java_hdf_hdf5lib_H5_H5Fset_1dset_1no_1attrs_1hint */
/*
* Class: hdf_hdf5lib_H5
@@ -764,7 +764,7 @@ Java_hdf_hdf5lib_H5_H5Fget_1dset_1no_1attrs_1hint(JNIEnv *env, jclass clss, jlon
done:
return bval;
-}
+} /* end Java_hdf_hdf5lib_H5_H5Fget_1dset_1no_1attrs_1hint */
/*
* Class: hdf_hdf5lib_H5
diff --git a/java/src/jni/h5lImp.c b/java/src/jni/h5lImp.c
index 5389600..67f4850 100644
--- a/java/src/jni/h5lImp.c
+++ b/java/src/jni/h5lImp.c
@@ -277,7 +277,7 @@ done:
JNIEXPORT jobject JNICALL
Java_hdf_hdf5lib_H5_H5Lget_1info(JNIEnv *env, jclass clss, jlong loc_id, jstring name, jlong access_id)
{
- H5L_info2_t infobuf = {H5L_TYPE_ERROR, FALSE, -1, H5T_CSET_ERROR, 0};
+ H5L_info2_t infobuf = {H5L_TYPE_ERROR, FALSE, -1, H5T_CSET_ERROR, {{{0}}}};
const char *linkName = NULL;
jvalue args[5];
herr_t status = FAIL;
@@ -340,7 +340,7 @@ JNIEXPORT jobject JNICALL
Java_hdf_hdf5lib_H5_H5Lget_1info_1by_1idx(JNIEnv *env, jclass clss, jlong loc_id, jstring name,
jint index_field, jint order, jlong link_n, jlong access_id)
{
- H5L_info2_t infobuf = {H5L_TYPE_ERROR, FALSE, -1, H5T_CSET_ERROR, 0};
+ H5L_info2_t infobuf = {H5L_TYPE_ERROR, FALSE, -1, H5T_CSET_ERROR, {{{0}}}};
const char *groupName = NULL;
jvalue args[5];
herr_t status = FAIL;
@@ -454,7 +454,7 @@ JNIEXPORT jint JNICALL
Java_hdf_hdf5lib_H5_H5Lget_1value(JNIEnv *env, jclass clss, jlong loc_id, jstring name,
jobjectArray link_value, jlong access_id)
{
- H5L_info2_t infobuf = {H5L_TYPE_ERROR, FALSE, -1, H5T_CSET_ERROR, 0};
+ H5L_info2_t infobuf = {H5L_TYPE_ERROR, FALSE, -1, H5T_CSET_ERROR, {{{0}}}};
const char *file_name = NULL;
const char *obj_name = NULL;
const char *linkName = NULL;
@@ -544,7 +544,7 @@ Java_hdf_hdf5lib_H5_H5Lget_1value_1by_1idx(JNIEnv *env, jclass clss, jlong loc_i
jint index_field, jint order, jlong link_n,
jobjectArray link_value, jlong access_id)
{
- H5L_info2_t infobuf = {H5L_TYPE_ERROR, FALSE, -1, H5T_CSET_ERROR, 0};
+ H5L_info2_t infobuf = {H5L_TYPE_ERROR, FALSE, -1, H5T_CSET_ERROR, {{{0}}}};
const char *file_name = NULL;
const char *obj_name = NULL;
const char *grpName = NULL;
diff --git a/java/src/jni/h5pDAPLImp.c b/java/src/jni/h5pDAPLImp.c
index 01108b3..666f47d 100644
--- a/java/src/jni/h5pDAPLImp.c
+++ b/java/src/jni/h5pDAPLImp.c
@@ -80,6 +80,8 @@ Java_hdf_hdf5lib_H5_H5Pget_1chunk_1cache(JNIEnv *env, jclass clss, jlong dapl, j
if (NULL != rdcc_nbytes)
PIN_LONG_ARRAY(ENVONLY, rdcc_nbytes, nbytesArray, &isCopy,
"H5Pget_chunk_cache: nbytesArray array not pinned");
+ if (NULL == nbytesArray)
+ H5_NULL_ARGUMENT_ERROR(ENVONLY, "nbytesArray should not be NULL after pinning");
{
/* direct cast (size_t *)variable fails on 32-bit environment */
diff --git a/java/src/jni/h5pFAPLImp.c b/java/src/jni/h5pFAPLImp.c
index f094aaf..80ed6c6 100644
--- a/java/src/jni/h5pFAPLImp.c
+++ b/java/src/jni/h5pFAPLImp.c
@@ -1252,6 +1252,8 @@ Java_hdf_hdf5lib_H5_H5Pget_1cache(JNIEnv *env, jclass clss, jlong plist, jintArr
if (NULL != rdcc_nbytes)
PIN_LONG_ARRAY(ENVONLY, rdcc_nbytes, nbytesArray, &isCopy,
"H5Pget_cache: nbytesArray array not pinned");
+ if (NULL == nbytesArray)
+ H5_NULL_ARGUMENT_ERROR(ENVONLY, "nbytesArray should not be NULL after pinning");
{
/* direct cast (size_t *)variable fails on 32-bit environment */
diff --git a/java/src/jni/h5tImp.c b/java/src/jni/h5tImp.c
index a81d270..3a3a288 100644
--- a/java/src/jni/h5tImp.c
+++ b/java/src/jni/h5tImp.c
@@ -1687,7 +1687,7 @@ Java_hdf_hdf5lib_H5_H5Tflush(JNIEnv *env, jclass clss, jlong loc_id)
done:
return;
-}
+} /* end Java_hdf_hdf5lib_H5_H5Tflush */
/*
* Class: hdf_hdf5lib_H5