summaryrefslogtreecommitdiffstats
path: root/src/H5.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>1998-10-13 21:28:53 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>1998-10-13 21:28:53 (GMT)
commit5389806ce86337bad48fe293b4faabd8c8c61b53 (patch)
tree0cb9dbd4c8abe67fdc7db50191ba9551bb69dd6b /src/H5.c
parent6fd7f81615780776b3e78860e9f386ac55994db9 (diff)
downloadhdf5-5389806ce86337bad48fe293b4faabd8c8c61b53.zip
hdf5-5389806ce86337bad48fe293b4faabd8c8c61b53.tar.gz
hdf5-5389806ce86337bad48fe293b4faabd8c8c61b53.tar.bz2
[svn-r757] Added code for object references.
Diffstat (limited to 'src/H5.c')
-rw-r--r--src/H5.c73
1 files changed, 73 insertions, 0 deletions
diff --git a/src/H5.c b/src/H5.c
index 5ca82e3..fa6eba3 100644
--- a/src/H5.c
+++ b/src/H5.c
@@ -53,6 +53,7 @@ FILE *fdopen(int fd, const char *mode);
#include <H5Iprivate.h> /*atoms */
#include <H5MMprivate.h> /*memory management */
#include <H5Pprivate.h> /*property lists */
+#include <H5Rpublic.h> /* References */
#include <H5Sprivate.h> /*data spaces */
#include <H5Tprivate.h> /*data types */
#include <H5Zprivate.h> /*filters */
@@ -1911,6 +1912,78 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
}
break;
+ case 'r':
+ if (ptr) {
+ if (vp) {
+ fprintf (out, "0x%lx", (unsigned long)vp);
+ } else {
+ fprintf(out, "NULL");
+ }
+ } else {
+ href_t ref = va_arg (ap, href_t);
+ switch (ref.type) {
+ case H5R_BADTYPE:
+ fprintf (out, "H5R_BADTYPE");
+ break;
+ case H5R_OBJECT:
+ fprintf (out, "H5R_OBJECT");
+ break;
+ case H5R_DATASET_REGION:
+ fprintf (out, "H5R_DATASET_REGION");
+ break;
+ case H5R_INTERNAL:
+ fprintf (out, "H5R_INTERNAL");
+ break;
+ case H5R_MAXTYPE:
+ fprintf (out, "H5R_MAXTYPE");
+ break;
+ default:
+ fprintf (out, "BADTYPE(%ld)", (long)ref.type);
+ break;
+ }
+ }
+ break;
+
+ case 'R':
+ switch (type[1]) {
+ case 't':
+ if (ptr) {
+ if (vp) {
+ fprintf(out, "0x%lx", (unsigned long)vp);
+ } else {
+ fprintf(out, "NULL");
+ }
+ } else {
+ H5R_type_t reftype = va_arg(ap, H5R_type_t);
+ switch (reftype) {
+ case H5R_BADTYPE:
+ fprintf(out, "H5R_BADTYPE");
+ break;
+ case H5R_OBJECT:
+ fprintf(out, "H5R_OBJECT");
+ break;
+ case H5R_DATASET_REGION:
+ fprintf(out, "H5R_DATASET_REGION");
+ break;
+ case H5R_INTERNAL:
+ fprintf(out, "H5R_INTERNAL");
+ break;
+ case H5R_MAXTYPE:
+ fprintf(out, "H5R_MAXTYPE");
+ break;
+ default:
+ fprintf(out, "BADTYPE(%ld)", (long)reftype);
+ break;
+ }
+ }
+ break;
+
+ default:
+ fprintf(out, "BADTYPE(S%c)", type[1]);
+ goto error;
+ }
+ break;
+
case 'S':
switch (type[1]) {
case 'c':