summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--c++/src/H5DcreatProp.cpp2
-rw-r--r--c++/src/H5DxferProp.cpp4
-rw-r--r--c++/src/H5FaccProp.cpp2
-rw-r--r--c++/src/H5FcreatProp.cpp2
-rw-r--r--c++/src/H5IdComponent.cpp2
-rw-r--r--c++/src/H5PropList.cpp42
-rw-r--r--c++/src/H5PropList.h11
-rw-r--r--fortran/src/H5Pf.c26
-rw-r--r--fortran/src/H5_f.c2
-rw-r--r--perform/overhead.c10
-rw-r--r--release_docs/RELEASE.txt5
-rw-r--r--src/H5.c567
-rw-r--r--src/H5D.c12
-rw-r--r--src/H5Distore.c4
-rw-r--r--src/H5Dseq.c4
-rw-r--r--src/H5FD.c12
-rw-r--r--src/H5Farray.c4
-rw-r--r--src/H5Fistore.c4
-rw-r--r--src/H5Fseq.c4
-rw-r--r--src/H5P.c186
-rw-r--r--src/H5Pprivate.h8
-rw-r--r--src/H5Ppublic.h39
-rw-r--r--test/cmpd_dset.c4
-rw-r--r--test/dsets.c8
-rw-r--r--test/tarray.c8
-rw-r--r--test/tselect.c10
-rw-r--r--test/tvlstr.c4
-rw-r--r--test/tvltypes.c16
-rw-r--r--tools/lib/talign.c4
29 files changed, 525 insertions, 481 deletions
diff --git a/c++/src/H5DcreatProp.cpp b/c++/src/H5DcreatProp.cpp
index 4f3d2e4..ec5a10a 100644
--- a/c++/src/H5DcreatProp.cpp
+++ b/c++/src/H5DcreatProp.cpp
@@ -13,7 +13,7 @@
namespace H5 {
#endif
-const DSetCreatPropList DSetCreatPropList::DEFAULT( H5P_DEFAULT );
+const DSetCreatPropList DSetCreatPropList::DEFAULT( H5P_NO_CLASS );
// Copy constructor: makes a copy of the original DSetCreatPropList object;
DSetCreatPropList::DSetCreatPropList( const DSetCreatPropList& orig ) : PropList( orig ) {}
diff --git a/c++/src/H5DxferProp.cpp b/c++/src/H5DxferProp.cpp
index 389db89..96444aa 100644
--- a/c++/src/H5DxferProp.cpp
+++ b/c++/src/H5DxferProp.cpp
@@ -11,10 +11,10 @@
namespace H5 {
#endif
-const DSetMemXferPropList DSetMemXferPropList::DEFAULT( H5P_DEFAULT );
+const DSetMemXferPropList DSetMemXferPropList::DEFAULT( H5P_NO_CLASS );
// Creates a dataset memory and transfer property list
-DSetMemXferPropList::DSetMemXferPropList() : PropList( H5P_DATASET_XFER_NEW ) {}
+DSetMemXferPropList::DSetMemXferPropList() : PropList( H5P_DATASET_XFER) {}
// Copy constructor: makes a copy of the original DSetMemXferPropList object;
DSetMemXferPropList::DSetMemXferPropList( const DSetMemXferPropList& orig ) : PropList( orig ) {}
diff --git a/c++/src/H5FaccProp.cpp b/c++/src/H5FaccProp.cpp
index 4eae889..3ade17e 100644
--- a/c++/src/H5FaccProp.cpp
+++ b/c++/src/H5FaccProp.cpp
@@ -11,7 +11,7 @@
namespace H5 {
#endif
-const FileAccPropList FileAccPropList::DEFAULT( H5P_DEFAULT );
+const FileAccPropList FileAccPropList::DEFAULT( H5P_NO_CLASS );
// Creates a file access property list
FileAccPropList::FileAccPropList() : PropList( H5P_FILE_ACCESS ) {}
diff --git a/c++/src/H5FcreatProp.cpp b/c++/src/H5FcreatProp.cpp
index d511595..3d4b21f 100644
--- a/c++/src/H5FcreatProp.cpp
+++ b/c++/src/H5FcreatProp.cpp
@@ -11,7 +11,7 @@
namespace H5 {
#endif
-const FileCreatPropList FileCreatPropList::DEFAULT( H5P_DEFAULT );
+const FileCreatPropList FileCreatPropList::DEFAULT( H5P_NO_CLASS );
// Creates a file create property list
FileCreatPropList::FileCreatPropList() : PropList( H5P_FILE_CREATE ) {}
diff --git a/c++/src/H5IdComponent.cpp b/c++/src/H5IdComponent.cpp
index d7ba7c4..1275ee5 100644
--- a/c++/src/H5IdComponent.cpp
+++ b/c++/src/H5IdComponent.cpp
@@ -12,7 +12,7 @@ namespace H5 {
#endif
// Default constructor - private
-IdComponent::IdComponent() : id( 0 )
+IdComponent::IdComponent() : id( -1 )
{
// starts counting object references
ref_count = new RefCounter;
diff --git a/c++/src/H5PropList.cpp b/c++/src/H5PropList.cpp
index 985d895..3982288 100644
--- a/c++/src/H5PropList.cpp
+++ b/c++/src/H5PropList.cpp
@@ -11,23 +11,12 @@
namespace H5 {
#endif
-const PropList PropList::DEFAULT( H5P_DEFAULT );
+const PropList PropList::DEFAULT( H5P_NO_CLASS );
// Default constructor - set id to 0 by default here but may be set
// to a valid one, if any, by a subclass constructor.
PropList::PropList() : IdComponent( 0 ) {}
-// Creates a new property of specified type
-PropList::PropList( H5P_class_t type ) : IdComponent( 0 )
-{
- // call C routine to create the new property
- id = H5Pcreate(type );
- if( id <= 0 )
- {
- throw PropListIException("PropList constructor", "H5Pcreate failed");
- }
-}
-
// Copy constructor: makes a copy of the original object
PropList::PropList( const PropList& original ) : IdComponent( original ) {}
@@ -39,18 +28,25 @@ Description:
the identifier still has reference counter; the p_close function
will take care of not to call H5Pclose on the default id.
*/
-PropList::PropList( const hid_t plist_id ) : IdComponent()
+PropList::PropList( const hid_t plist_id ) : IdComponent(0)
{
- if (H5I_GENPROP_CLS == H5Iget_type(plist_id)) {
+ if (H5I_GENPROP_CLS == H5Iget_type(plist_id)
+ || plist_id==H5P_FILE_CREATE
+ || plist_id==H5P_FILE_ACCESS
+ || plist_id==H5P_DATASET_CREATE
+ || plist_id==H5P_MOUNT) {
// call C routine to create the new property
- id = H5Pcreate_list(plist_id);
+ id = H5Pcreate(plist_id);
if( id <= 0 )
{
- throw PropListIException("PropList constructor", "H5Pcreate_list failed");
+ throw PropListIException("PropList constructor", "H5Pcreate failed");
}
}
else {
- id=plist_id;
+ if(plist_id==H5P_NO_CLASS)
+ id=H5P_DEFAULT;
+ else
+ id=plist_id;
}
}
@@ -88,15 +84,11 @@ PropList& PropList::operator=( const PropList& rhs )
// Closes the property list if it is not a default one
void PropList::p_close() const
{
- if( id != H5P_DEFAULT ) // not a constant, should call H5Pclose
+ if( id != H5P_NO_CLASS ) // not a constant, should call H5Pclose
{
herr_t ret_value;
- if (H5I_GENPROP_LST == H5Iget_type(id)) {
- ret_value = H5Pclose_list( id );
- } else {
- ret_value = H5Pclose( id );
- }
+ ret_value = H5Pclose( id );
if( ret_value < 0 )
{
@@ -106,9 +98,9 @@ void PropList::p_close() const
}
// Returns the class of this property list, i.e. H5P_FILE_CREATE...
-H5P_class_t PropList::getClass() const
+hid_t PropList::getClass() const
{
- H5P_class_t plist_class = H5Pget_class( id );
+ hid_t plist_class = H5Pget_class( id );
if( plist_class == H5P_NO_CLASS )
{
throw PropListIException("PropList::getClass",
diff --git a/c++/src/H5PropList.h b/c++/src/H5PropList.h
index 037b0d8..c800ace 100644
--- a/c++/src/H5PropList.h
+++ b/c++/src/H5PropList.h
@@ -11,8 +11,9 @@ class PropList : public IdComponent {
// Default property list
static const PropList DEFAULT;
- // Creates a property list given the property list type.
- PropList( H5P_class_t type );
+ // Creates a property list of a given type or creates a copy of an
+ // existing property list giving the property list id
+ PropList( const hid_t plist_id );
// Default constructor: creates a PropList object - this object
// does not represent any property list yet.
@@ -29,11 +30,7 @@ class PropList : public IdComponent {
// Gets the class of this property list, i.e. H5P_FILE_CREATE,
// H5P_FILE_ACCESS, ...
- H5P_class_t getClass() const;
-
- // Creates a default property list or creates a copy of an
- // existing property list giving the property list id
- PropList( const hid_t plist_id );
+ hid_t getClass() const;
// Used by the API to close the property list
void p_close() const;
diff --git a/fortran/src/H5Pf.c b/fortran/src/H5Pf.c
index fed1249..bac381c 100644
--- a/fortran/src/H5Pf.c
+++ b/fortran/src/H5Pf.c
@@ -15,12 +15,12 @@
int_f
nh5pcreate_c ( int_f *classtype, hid_t_f *prp_id )
{
- H5P_class_t c_classtype;
+ hid_t c_classtype;
int CASE;
int ret_value = 0;
hid_t c_prp_id;
/*CASE = (int)*classtype; */
- c_classtype = (H5P_class_t)*classtype;
+ c_classtype = (hid_t)*classtype;
/*
switch (CASE) {
@@ -50,10 +50,7 @@ nh5pcreate_c ( int_f *classtype, hid_t_f *prp_id )
return ret_value;
}
*/
- if (H5I_GENPROP_CLS == H5Iget_type((hid_t)*classtype))
- c_prp_id = H5Pcreate_list((hid_t)*classtype);
- else
- c_prp_id = H5Pcreate(c_classtype);
+ c_prp_id = H5Pcreate(c_classtype);
if ( c_prp_id < 0 ) ret_value = -1;
*prp_id = (hid_t_f)c_prp_id;
@@ -76,11 +73,7 @@ nh5pclose_c ( hid_t_f *prp_id )
int ret_value = 0;
hid_t c_prp_id=(*prp_id);
- if (H5I_GENPROP_LST == H5Iget_type(c_prp_id)) {
- if ( H5Pclose_list(c_prp_id) < 0 ) ret_value = -1;
- } else {
- if ( H5Pclose(c_prp_id) < 0 ) ret_value = -1;
- }
+ if ( H5Pclose(c_prp_id) < 0 ) ret_value = -1;
return ret_value;
}
@@ -133,24 +126,17 @@ nh5pget_class_c ( hid_t_f *prp_id , int_f *classtype)
{
int ret_value = 0;
hid_t c_prp_id;
- H5P_class_t c_classtype;
+ hid_t c_classtype;
c_prp_id = *prp_id;
c_classtype = H5Pget_class(c_prp_id);
if (c_classtype == H5P_NO_CLASS ) {
- /* *classtype = H5P_NO_CLASS_F; */
*classtype = H5P_NO_CLASS;
ret_value = -1;
return ret_value;
}
*classtype = (int_f)c_classtype;
-/*
- if (c_classtype == H5P_FILE_CREATE) *classtype = H5P_FILE_CREATE_F;
- if (c_classtype == H5P_FILE_ACCESS) *classtype = H5P_FILE_ACCESS_F;
- if (c_classtype == H5P_DATASET_CREATE) *classtype = H5P_DATASET_CREATE_F;
- if (c_classtype == H5P_DATASET_XFER) *classtype = H5P_DATASET_XFER_F;
- if (c_classtype == H5P_MOUNT_F) *classtype = H5P_MOUNT_F;
-*/
+
return ret_value;
}
diff --git a/fortran/src/H5_f.c b/fortran/src/H5_f.c
index b3f1a6c..83eb113 100644
--- a/fortran/src/H5_f.c
+++ b/fortran/src/H5_f.c
@@ -248,7 +248,7 @@ nh5init_flags_c( int_f *h5d_flags, int_f *h5e_flags, int_f *h5f_flags,
h5p_flags[0] = H5P_FILE_CREATE;
h5p_flags[1] = H5P_FILE_ACCESS;
h5p_flags[2] = H5P_DATASET_CREATE;
- h5p_flags[3] = H5P_DATASET_XFER_NEW;
+ h5p_flags[3] = H5P_DATASET_XFER;
h5p_flags[4] = H5P_MOUNT;
h5p_flags[5] = H5P_DEFAULT;
diff --git a/perform/overhead.c b/perform/overhead.c
index 8be9ae2..cea8dac 100644
--- a/perform/overhead.c
+++ b/perform/overhead.c
@@ -199,7 +199,7 @@ test(fill_t fill_style, const double splits[],
}
if ((dcpl=H5Pcreate(H5P_DATASET_CREATE))<0) goto error;
if (H5Pset_chunk(dcpl, 1, ch_size)<0) goto error;
- if ((xfer=H5Pcreate_list(H5P_DATASET_XFER_NEW))<0) goto error;
+ if ((xfer=H5Pcreate(H5P_DATASET_XFER))<0) goto error;
if (H5Pset_btree_ratios(xfer, splits[0], splits[1], splits[2])<0) {
goto error;
}
@@ -275,7 +275,7 @@ test(fill_t fill_style, const double splits[],
H5Sclose(mspace);
H5Sclose(fspace);
H5Pclose(dcpl);
- H5Pclose_list(xfer);
+ H5Pclose(xfer);
H5Fclose(file);
if (!verbose) {
@@ -321,7 +321,7 @@ test(fill_t fill_style, const double splits[],
H5Sclose(mspace);
H5Sclose(fspace);
H5Pclose(dcpl);
- H5Pclose_list(xfer);
+ H5Pclose(xfer);
H5Fclose(file);
free(had);
close(fd);
@@ -356,11 +356,11 @@ main(int argc, char *argv[])
/* Default split ratios */
H5Eset_auto(display_error_cb, NULL);
- if ((xfer=H5Pcreate_list(H5P_DATASET_XFER_NEW))<0) goto error;
+ if ((xfer=H5Pcreate(H5P_DATASET_XFER))<0) goto error;
if (H5Pget_btree_ratios(xfer, splits+0, splits+1, splits+2)<0) {
goto error;
}
- if (H5Pclose_list(xfer)<0) goto error;
+ if (H5Pclose(xfer)<0) goto error;
/* Parse command-line options */
for (i=1, j=0; i<argc; i++) {
diff --git a/release_docs/RELEASE.txt b/release_docs/RELEASE.txt
index 2ee065b..cfd2647 100644
--- a/release_docs/RELEASE.txt
+++ b/release_docs/RELEASE.txt
@@ -154,6 +154,11 @@ New Features
syntax of H5Pset_fapl_multi() in addition to what it used to accept.
* Added a new test to verify the information provided by the configure
command.
+ * As part of the transition to using generic properties everywhere, the
+ parameter of H5Pcreate changed from H5P_class_t to hid_t, as well
+ the return type of H5Pget_class changed from H5P_class_t to hid_t.
+ Further changes are still necessary and will be documented here as they
+ are made.
Platforms Tested
================
diff --git a/src/H5.c b/src/H5.c
index b69d118..8b95d0a 100644
--- a/src/H5.c
+++ b/src/H5.c
@@ -1970,26 +1970,26 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
case H5I_TEMPLATE_5:
case H5I_TEMPLATE_6:
case H5I_TEMPLATE_7:
+ /* These will eventually go away when the old-style */
+ /* property lists are converted to generic property */
+ /* lists -QAK */
switch (H5P_get_class(id_type)) {
- case H5P_FILE_CREATE:
- fprintf(out, "H5P_FILE_CREATE");
- break;
- case H5P_FILE_ACCESS:
- fprintf(out, "H5P_FILE_ACCESS");
- break;
- case H5P_DATASET_CREATE:
- fprintf(out, "H5P_DATASET_CREATE");
- break;
- case H5P_DATASET_XFER:
- fprintf(out, "H5P_DATASET_XFER");
- break;
- case H5P_MOUNT:
- fprintf(out, "H5P_MOUNT");
- break;
- default:
- fprintf (out, "H5I_TEMPLATE_%d",
- (int)(id_type-H5I_TEMPLATE_0));
- break;
+ case H5P_FILE_CREATE_OLD:
+ fprintf(out, "H5P_FILE_CREATE");
+ break;
+ case H5P_FILE_ACCESS_OLD:
+ fprintf(out, "H5P_FILE_ACCESS");
+ break;
+ case H5P_DATASET_CREATE_OLD:
+ fprintf(out, "H5P_DATASET_CREATE");
+ break;
+ case H5P_MOUNT_OLD:
+ fprintf(out, "H5P_MOUNT");
+ break;
+ default:
+ fprintf (out, "H5I_TEMPLATE_%d",
+ (int)(id_type-H5I_TEMPLATE_0));
+ break;
}
break;
case H5I_GROUP:
@@ -2013,6 +2013,15 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
case H5I_REFERENCE:
fprintf (out, "H5I_REFERENCE");
break;
+ case H5I_VFL:
+ fprintf (out, "H5I_VFL");
+ break;
+ case H5I_GENPROP_CLS:
+ fprintf (out, "H5I_GENPROP_CLS");
+ break;
+ case H5I_GENPROP_LST:
+ fprintf (out, "H5I_GENPROP_LST");
+ break;
case H5I_NGROUPS:
fprintf (out, "H5I_NGROUPS");
break;
@@ -2126,80 +2135,83 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
fprintf(out, "NULL");
}
} else {
- H5P_class_t plist_class = va_arg (ap, H5P_class_t);
+ /* Before deleting the last of these old-style lists, convert */
+ /* this chunk of code to print the class of the property list */
+ /* using the generic property list classes - QAK */
+ H5P_class_t_old plist_class = va_arg (ap, H5P_class_t_old);
switch (plist_class) {
- case H5P_NO_CLASS:
- fprintf (out, "H5P_NO_CLASS");
- break;
- case H5P_FILE_CREATE:
- fprintf (out, "H5P_FILE_CREATE");
- break;
- case H5P_FILE_ACCESS:
- fprintf (out, "H5P_FILE_ACCESS");
- break;
- case H5P_DATASET_CREATE:
- fprintf (out, "H5P_DATASET_CREATE");
- break;
- case H5P_DATASET_XFER:
- fprintf (out, "H5P_DATASET_XFER");
- break;
- default:
- fprintf (out, "%ld", (long)plist_class);
- break;
+ case H5P_NO_CLASS_OLD:
+ fprintf (out, "H5P_NO_CLASS");
+ break;
+ case H5P_FILE_CREATE_OLD:
+ fprintf (out, "H5P_FILE_CREATE");
+ break;
+ case H5P_FILE_ACCESS_OLD:
+ fprintf (out, "H5P_FILE_ACCESS");
+ break;
+ case H5P_DATASET_CREATE_OLD:
+ fprintf (out, "H5P_DATASET_CREATE");
+ break;
+ case H5P_MOUNT_OLD:
+ fprintf (out, "H5P_MOUNT");
+ break;
+ default:
+ fprintf (out, "%ld", (long)plist_class);
+ break;
}
}
break;
case 'r':
if (ptr) {
- if (vp) {
- fprintf (out, "0x%lx", (unsigned long)vp);
- } else {
- fprintf(out, "NULL");
- }
+ if (vp) {
+ fprintf (out, "0x%lx", (unsigned long)vp);
+ } else {
+ fprintf(out, "NULL");
+ }
} else {
- hobj_ref_t ref = va_arg (ap, hobj_ref_t);
- fprintf (out, "Reference Object=%p", &ref);
+ hobj_ref_t ref = va_arg (ap, hobj_ref_t);
+ fprintf (out, "Reference Object=%p", &ref);
}
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;
+ 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;
@@ -2215,21 +2227,21 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5S_class_t cls = va_arg(ap, H5S_class_t);
switch (cls) {
- case H5S_NO_CLASS:
- fprintf(out, "H5S_NO_CLASS");
- break;
- case H5S_SCALAR:
- fprintf(out, "H5S_SCALAR");
- break;
- case H5S_SIMPLE:
- fprintf(out, "H5S_SIMPLE");
- break;
- case H5S_COMPLEX:
- fprintf(out, "H5S_COMPLEX");
- break;
- default:
- fprintf(out, "%ld", (long)cls);
- break;
+ case H5S_NO_CLASS:
+ fprintf(out, "H5S_NO_CLASS");
+ break;
+ case H5S_SCALAR:
+ fprintf(out, "H5S_SCALAR");
+ break;
+ case H5S_SIMPLE:
+ fprintf(out, "H5S_SIMPLE");
+ break;
+ case H5S_COMPLEX:
+ fprintf(out, "H5S_COMPLEX");
+ break;
+ default:
+ fprintf(out, "%ld", (long)cls);
+ break;
}
}
break;
@@ -2244,18 +2256,18 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5S_seloper_t so = va_arg(ap, H5S_seloper_t);
switch (so) {
- case H5S_SELECT_NOOP:
- fprintf(out, "H5S_NOOP");
- break;
- case H5S_SELECT_SET:
- fprintf(out, "H5S_SELECT_SET");
- break;
- case H5S_SELECT_OR:
- fprintf(out, "H5S_SELECT_OR");
- break;
- default:
- fprintf(out, "%ld", (long)so);
- break;
+ case H5S_SELECT_NOOP:
+ fprintf(out, "H5S_NOOP");
+ break;
+ case H5S_SELECT_SET:
+ fprintf(out, "H5S_SELECT_SET");
+ break;
+ case H5S_SELECT_OR:
+ fprintf(out, "H5S_SELECT_OR");
+ break;
+ default:
+ fprintf(out, "%ld", (long)so);
+ break;
}
}
break;
@@ -2291,15 +2303,15 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5T_cset_t cset = va_arg (ap, H5T_cset_t);
switch (cset) {
- case H5T_CSET_ERROR:
- fprintf (out, "H5T_CSET_ERROR");
- break;
- case H5T_CSET_ASCII:
- fprintf (out, "H5T_CSET_ASCII");
- break;
- default:
- fprintf (out, "%ld", (long)cset);
- break;
+ case H5T_CSET_ERROR:
+ fprintf (out, "H5T_CSET_ERROR");
+ break;
+ case H5T_CSET_ASCII:
+ fprintf (out, "H5T_CSET_ASCII");
+ break;
+ default:
+ fprintf (out, "%ld", (long)cset);
+ break;
}
}
break;
@@ -2314,18 +2326,18 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5T_pers_t pers = va_arg(ap, H5T_pers_t);
switch (pers) {
- case H5T_PERS_DONTCARE:
- fprintf(out, "H5T_PERS_DONTCARE");
- break;
- case H5T_PERS_SOFT:
- fprintf(out, "H5T_PERS_SOFT");
- break;
- case H5T_PERS_HARD:
- fprintf(out, "H5T_PERS_HARD");
- break;
- default:
- fprintf(out, "%ld", (long)pers);
- break;
+ case H5T_PERS_DONTCARE:
+ fprintf(out, "H5T_PERS_DONTCARE");
+ break;
+ case H5T_PERS_SOFT:
+ fprintf(out, "H5T_PERS_SOFT");
+ break;
+ case H5T_PERS_HARD:
+ fprintf(out, "H5T_PERS_HARD");
+ break;
+ default:
+ fprintf(out, "%ld", (long)pers);
+ break;
}
}
break;
@@ -2340,21 +2352,21 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5T_norm_t norm = va_arg (ap, H5T_norm_t);
switch (norm) {
- case H5T_NORM_ERROR:
- fprintf (out, "H5T_NORM_ERROR");
- break;
- case H5T_NORM_IMPLIED:
- fprintf (out, "H5T_NORM_IMPLIED");
- break;
- case H5T_NORM_MSBSET:
- fprintf (out, "H5T_NORM_MSBSET");
- break;
- case H5T_NORM_NONE:
- fprintf (out, "H5T_NORM_NONE");
- break;
- default:
- fprintf (out, "%ld", (long)norm);
- break;
+ case H5T_NORM_ERROR:
+ fprintf (out, "H5T_NORM_ERROR");
+ break;
+ case H5T_NORM_IMPLIED:
+ fprintf (out, "H5T_NORM_IMPLIED");
+ break;
+ case H5T_NORM_MSBSET:
+ fprintf (out, "H5T_NORM_MSBSET");
+ break;
+ case H5T_NORM_NONE:
+ fprintf (out, "H5T_NORM_NONE");
+ break;
+ default:
+ fprintf (out, "%ld", (long)norm);
+ break;
}
}
break;
@@ -2369,24 +2381,24 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5T_order_t order = va_arg (ap, H5T_order_t);
switch (order) {
- case H5T_ORDER_ERROR:
- fprintf (out, "H5T_ORDER_ERROR");
- break;
- case H5T_ORDER_LE:
- fprintf (out, "H5T_ORDER_LE");
- break;
- case H5T_ORDER_BE:
- fprintf (out, "H5T_ORDER_BE");
- break;
- case H5T_ORDER_VAX:
- fprintf (out, "H5T_ORDER_VAX");
- break;
- case H5T_ORDER_NONE:
- fprintf (out, "H5T_ORDER_NONE");
- break;
- default:
- fprintf (out, "%ld", (long)order);
- break;
+ case H5T_ORDER_ERROR:
+ fprintf (out, "H5T_ORDER_ERROR");
+ break;
+ case H5T_ORDER_LE:
+ fprintf (out, "H5T_ORDER_LE");
+ break;
+ case H5T_ORDER_BE:
+ fprintf (out, "H5T_ORDER_BE");
+ break;
+ case H5T_ORDER_VAX:
+ fprintf (out, "H5T_ORDER_VAX");
+ break;
+ case H5T_ORDER_NONE:
+ fprintf (out, "H5T_ORDER_NONE");
+ break;
+ default:
+ fprintf (out, "%ld", (long)order);
+ break;
}
}
break;
@@ -2401,21 +2413,21 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5T_pad_t pad = va_arg (ap, H5T_pad_t);
switch (pad) {
- case H5T_PAD_ERROR:
- fprintf (out, "H5T_PAD_ERROR");
- break;
- case H5T_PAD_ZERO:
- fprintf (out, "H5T_PAD_ZERO");
- break;
- case H5T_PAD_ONE:
- fprintf (out, "H5T_PAD_ONE");
- break;
- case H5T_PAD_BACKGROUND:
- fprintf (out, "H5T_PAD_BACKGROUND");
- break;
- default:
- fprintf (out, "%ld", (long)pad);
- break;
+ case H5T_PAD_ERROR:
+ fprintf (out, "H5T_PAD_ERROR");
+ break;
+ case H5T_PAD_ZERO:
+ fprintf (out, "H5T_PAD_ZERO");
+ break;
+ case H5T_PAD_ONE:
+ fprintf (out, "H5T_PAD_ONE");
+ break;
+ case H5T_PAD_BACKGROUND:
+ fprintf (out, "H5T_PAD_BACKGROUND");
+ break;
+ default:
+ fprintf (out, "%ld", (long)pad);
+ break;
}
}
break;
@@ -2430,18 +2442,18 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5T_sign_t sign = va_arg (ap, H5T_sign_t);
switch (sign) {
- case H5T_SGN_ERROR:
- fprintf (out, "H5T_SGN_ERROR");
- break;
- case H5T_SGN_NONE:
- fprintf (out, "H5T_SGN_NONE");
- break;
- case H5T_SGN_2:
- fprintf (out, "H5T_SGN_2");
- break;
- default:
- fprintf (out, "%ld", (long)sign);
- break;
+ case H5T_SGN_ERROR:
+ fprintf (out, "H5T_SGN_ERROR");
+ break;
+ case H5T_SGN_NONE:
+ fprintf (out, "H5T_SGN_NONE");
+ break;
+ case H5T_SGN_2:
+ fprintf (out, "H5T_SGN_2");
+ break;
+ default:
+ fprintf (out, "%ld", (long)sign);
+ break;
}
}
break;
@@ -2456,36 +2468,36 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5T_class_t type_class = va_arg(ap, H5T_class_t);
switch (type_class) {
- case H5T_NO_CLASS:
- fprintf(out, "H5T_NO_CLASS");
- break;
- case H5T_INTEGER:
- fprintf(out, "H5T_INTEGER");
- break;
- case H5T_FLOAT:
- fprintf(out, "H5T_FLOAT");
- break;
- case H5T_TIME:
- fprintf(out, "H5T_TIME");
- break;
- case H5T_STRING:
- fprintf(out, "H5T_STRING");
- break;
- case H5T_BITFIELD:
- fprintf(out, "H5T_BITFIELD");
- break;
- case H5T_OPAQUE:
- fprintf(out, "H5T_OPAQUE");
- break;
- case H5T_COMPOUND:
- fprintf(out, "H5T_COMPOUND");
- break;
- case H5T_ENUM:
- fprintf(out, "H5T_ENUM");
- break;
- default:
- fprintf(out, "%ld", (long)type_class);
- break;
+ case H5T_NO_CLASS:
+ fprintf(out, "H5T_NO_CLASS");
+ break;
+ case H5T_INTEGER:
+ fprintf(out, "H5T_INTEGER");
+ break;
+ case H5T_FLOAT:
+ fprintf(out, "H5T_FLOAT");
+ break;
+ case H5T_TIME:
+ fprintf(out, "H5T_TIME");
+ break;
+ case H5T_STRING:
+ fprintf(out, "H5T_STRING");
+ break;
+ case H5T_BITFIELD:
+ fprintf(out, "H5T_BITFIELD");
+ break;
+ case H5T_OPAQUE:
+ fprintf(out, "H5T_OPAQUE");
+ break;
+ case H5T_COMPOUND:
+ fprintf(out, "H5T_COMPOUND");
+ break;
+ case H5T_ENUM:
+ fprintf(out, "H5T_ENUM");
+ break;
+ default:
+ fprintf(out, "%ld", (long)type_class);
+ break;
}
}
break;
@@ -2500,21 +2512,21 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
} else {
H5T_str_t str = va_arg(ap, H5T_str_t);
switch (str) {
- case H5T_STR_ERROR:
- fprintf(out, "H5T_STR_ERROR");
- break;
- case H5T_STR_NULLTERM:
- fprintf(out, "H5T_STR_NULLTERM");
- break;
- case H5T_STR_NULLPAD:
- fprintf(out, "H5T_STR_NULLPAD");
- break;
- case H5T_STR_SPACEPAD:
- fprintf(out, "H5T_STR_SPACEPAD");
- break;
- default:
- fprintf(out, "%ld", (long)str);
- break;
+ case H5T_STR_ERROR:
+ fprintf(out, "H5T_STR_ERROR");
+ break;
+ case H5T_STR_NULLTERM:
+ fprintf(out, "H5T_STR_NULLTERM");
+ break;
+ case H5T_STR_NULLPAD:
+ fprintf(out, "H5T_STR_NULLPAD");
+ break;
+ case H5T_STR_SPACEPAD:
+ fprintf(out, "H5T_STR_SPACEPAD");
+ break;
+ default:
+ fprintf(out, "%ld", (long)str);
+ break;
}
}
break;
@@ -2572,6 +2584,7 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
}
} else {
size_t size = va_arg (ap, size_t);
+
HDfprintf (out, "%Zu", size);
asize[argno] = (hssize_t)size;
}
@@ -2579,48 +2592,50 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
case 'Z':
switch (type[1]) {
- case 'f':
- if (ptr) {
- if (vp) {
- fprintf (out, "0x%lx", (unsigned long)vp);
- } else {
- fprintf(out, "NULL");
- }
- } else {
- H5Z_filter_t id = va_arg (ap, H5Z_filter_t);
- if (H5Z_FILTER_DEFLATE==id) {
- fprintf (out, "H5Z_FILTER_DEFLATE");
- } else {
- fprintf (out, "%ld", (long)id);
- }
- }
- break;
-
- case 's':
- if (ptr) {
- if (vp) {
- fprintf (out, "0x%lx", (unsigned long)vp);
- if (vp && asize_idx>=0 && asize[asize_idx]>=0) {
- ssize_t *p = (ssize_t*)vp;
- fprintf(out, " {");
- for (i=0; i<asize[asize_idx]; i++) {
- HDfprintf(out, "%s%Zd", i?", ":"", p[i]);
- }
- fprintf(out, "}");
- }
- } else {
- fprintf(out, "NULL");
- }
- } else {
- ssize_t ssize = va_arg (ap, ssize_t);
- HDfprintf (out, "%Zd", ssize);
- asize[argno] = (hssize_t)ssize;
- }
- break;
-
- default:
- fprintf (out, "BADTYPE(Z%c)", type[1]);
- goto error;
+ case 'f':
+ if (ptr) {
+ if (vp) {
+ fprintf (out, "0x%lx", (unsigned long)vp);
+ } else {
+ fprintf(out, "NULL");
+ }
+ } else {
+ H5Z_filter_t id = va_arg (ap, H5Z_filter_t);
+
+ if (H5Z_FILTER_DEFLATE==id) {
+ fprintf (out, "H5Z_FILTER_DEFLATE");
+ } else {
+ fprintf (out, "%ld", (long)id);
+ }
+ }
+ break;
+
+ case 's':
+ if (ptr) {
+ if (vp) {
+ fprintf (out, "0x%lx", (unsigned long)vp);
+ if (vp && asize_idx>=0 && asize[asize_idx]>=0) {
+ ssize_t *p = (ssize_t*)vp;
+ fprintf(out, " {");
+ for (i=0; i<asize[asize_idx]; i++) {
+ HDfprintf(out, "%s%Zd", i?", ":"", p[i]);
+ }
+ fprintf(out, "}");
+ }
+ } else {
+ fprintf(out, "NULL");
+ }
+ } else {
+ ssize_t ssize = va_arg (ap, ssize_t);
+
+ HDfprintf (out, "%Zd", ssize);
+ asize[argno] = (hssize_t)ssize;
+ }
+ break;
+
+ default:
+ fprintf (out, "BADTYPE(Z%c)", type[1]);
+ goto error;
}
break;
@@ -2634,7 +2649,7 @@ H5_trace (hbool_t returning, const char *func, const char *type, ...)
}
}
- error:
+error:
va_end (ap);
if (returning) {
fprintf (out, ";\n");
diff --git a/src/H5D.c b/src/H5D.c
index b6d869a..633387f 100644
--- a/src/H5D.c
+++ b/src/H5D.c
@@ -875,7 +875,7 @@ H5Dread(hid_t dset_id, hid_t mem_type_id, hid_t mem_space_id,
plist_id= H5P_DATASET_XFER_DEFAULT;
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not xfer parms");
if (!buf)
HRETURN_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no output buffer");
@@ -973,7 +973,7 @@ H5Dwrite(hid_t dset_id, hid_t mem_type_id, hid_t mem_space_id,
plist_id= H5P_DATASET_XFER_DEFAULT;
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not xfer parms");
if (!buf)
HRETURN_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no output buffer");
@@ -1783,7 +1783,7 @@ H5D_read(H5D_t *dataset, const H5T_t *mem_type, const H5S_t *mem_space,
assert(mem_type);
assert(buf);
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
/* Initialize these before any errors can occur */
HDmemset(&mem_iter,0,sizeof(H5S_sel_iter_t));
@@ -2230,7 +2230,7 @@ H5D_write(H5D_t *dataset, const H5T_t *mem_type, const H5S_t *mem_space,
assert(mem_type);
assert(buf);
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
#ifdef H5_HAVE_PARALLEL
/* If MPIO is used, no VL datatype support yet. */
@@ -3133,7 +3133,7 @@ H5Dvlen_reclaim(hid_t type_id, hid_t space_id, hid_t plist_id, void *buf)
plist_id= H5P_DATASET_XFER_DEFAULT;
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not xfer parms");
/* Call H5Diterate with args, etc. */
@@ -3299,7 +3299,7 @@ H5Dvlen_get_buf_size(hid_t dataset_id, hid_t type_id, hid_t space_id,
HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "no temporary buffers available");
/* Change to the custom memory allocation routines for reading VL data */
- if((vlen_bufsize.xfer_pid=H5Pcreate_list(H5P_DATASET_XFER_NEW))<0)
+ if((vlen_bufsize.xfer_pid=H5Pcreate_list(H5P_DATASET_XFER))<0)
HGOTO_ERROR(H5E_PLIST, H5E_CANTCREATE, FAIL, "no dataset xfer plists available");
if(H5Pset_vlen_mem_manager(vlen_bufsize.xfer_pid,H5D_vlen_get_buf_size_alloc,&vlen_bufsize,NULL,NULL)<0)
diff --git a/src/H5Distore.c b/src/H5Distore.c
index c5f12a3..4ddb4d4 100644
--- a/src/H5Distore.c
+++ b/src/H5Distore.c
@@ -1501,7 +1501,7 @@ H5F_istore_lock(H5F_t *f, hid_t dxpl_id, const H5O_layout_t *layout,
ent->chunk = chunk;
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
H5Pget(dxpl_id,H5D_XFER_BTREE_SPLIT_RATIO_NAME,&(ent->split_ratios));
/* Add it to the cache */
@@ -1644,7 +1644,7 @@ H5F_istore_unlock(H5F_t *f, hid_t dxpl_id, const H5O_layout_t *layout,
x.chunk = chunk;
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
H5Pget(dxpl_id,H5D_XFER_BTREE_SPLIT_RATIO_NAME,&(x.split_ratios));
H5F_istore_flush_entry (f, &x, TRUE);
diff --git a/src/H5Dseq.c b/src/H5Dseq.c
index b1c7c3b..45a6815 100644
--- a/src/H5Dseq.c
+++ b/src/H5Dseq.c
@@ -174,7 +174,7 @@ H5F_seq_readv(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout,
assert(real_buf);
/* Make certain we have the correct type of property list */
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
#ifdef H5_HAVE_PARALLEL
{
@@ -548,7 +548,7 @@ H5F_seq_writev(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout,
assert(real_buf);
/* Make certain we have the correct type of property list */
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
#ifdef H5_HAVE_PARALLEL
{
diff --git a/src/H5FD.c b/src/H5FD.c
index fb7d77b..62a866f 100644
--- a/src/H5FD.c
+++ b/src/H5FD.c
@@ -292,11 +292,11 @@ H5FD_get_class(hid_t id)
} else if (H5I_VFL==H5I_get_type(id)) {
ret_value = H5I_object(id);
} else if (H5I_GENPROP_LST == H5I_get_type(id) &&
- TRUE==H5Pisa_class(id,H5P_DATASET_XFER_NEW)) {
+ TRUE==H5Pisa_class(id,H5P_DATASET_XFER)) {
ret_value = H5FD_get_class(H5P_peek_hid_t(id,H5D_XFER_VFL_ID_NAME));
} else {
switch (H5P_get_class(id)) {
- case H5P_FILE_ACCESS:
+ case H5P_FILE_ACCESS_OLD:
if (NULL==(fapl=H5I_object(id))) {
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, NULL,
"not a file access property list");
@@ -1968,7 +1968,7 @@ H5FDread(H5FD_t *file, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr, size_t size
if (H5P_DEFAULT == dxpl_id)
dxpl_id= H5P_DATASET_XFER_DEFAULT;
if (H5I_GENPROP_LST != H5I_get_type(dxpl_id) ||
- TRUE!=H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(dxpl_id,H5P_DATASET_XFER))
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a data transfer property list");
if (!buf)
HRETURN_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "null result buffer");
@@ -2008,7 +2008,7 @@ H5FD_read(H5FD_t *file, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr, size_t siz
FUNC_ENTER(H5FD_read, FAIL);
assert(file && file->cls);
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
assert(buf);
#ifndef H5_HAVE_PARALLEL
@@ -2121,7 +2121,7 @@ H5FDwrite(H5FD_t *file, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr, size_t siz
if (H5P_DEFAULT == dxpl_id)
dxpl_id= H5P_DATASET_XFER_DEFAULT;
if (H5I_GENPROP_LST != H5I_get_type(dxpl_id) ||
- TRUE!=H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(dxpl_id,H5P_DATASET_XFER))
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a data transfer property list");
if (!buf)
HRETURN_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "null buffer");
@@ -2164,7 +2164,7 @@ H5FD_write(H5FD_t *file, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr, size_t si
FUNC_ENTER(H5FD_write, FAIL);
assert(file && file->cls);
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
assert(buf);
#ifndef H5_HAVE_PARALLEL
diff --git a/src/H5Farray.c b/src/H5Farray.c
index ff69cfa..54dd376 100644
--- a/src/H5Farray.c
+++ b/src/H5Farray.c
@@ -167,7 +167,7 @@ H5F_arr_read(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout,
assert(buf);
/* Make certain we have the correct type of property list */
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
/* Make a local copy of size so we can modify it */
H5V_vector_cpy(layout->ndims, hslab_size, _hslab_size);
@@ -454,7 +454,7 @@ H5F_arr_write(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout,
assert(buf);
/* Make certain we have the correct type of property list */
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
/* Make a local copy of _size so we can modify it */
H5V_vector_cpy(layout->ndims, hslab_size, _hslab_size);
diff --git a/src/H5Fistore.c b/src/H5Fistore.c
index c5f12a3..4ddb4d4 100644
--- a/src/H5Fistore.c
+++ b/src/H5Fistore.c
@@ -1501,7 +1501,7 @@ H5F_istore_lock(H5F_t *f, hid_t dxpl_id, const H5O_layout_t *layout,
ent->chunk = chunk;
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
H5Pget(dxpl_id,H5D_XFER_BTREE_SPLIT_RATIO_NAME,&(ent->split_ratios));
/* Add it to the cache */
@@ -1644,7 +1644,7 @@ H5F_istore_unlock(H5F_t *f, hid_t dxpl_id, const H5O_layout_t *layout,
x.chunk = chunk;
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
H5Pget(dxpl_id,H5D_XFER_BTREE_SPLIT_RATIO_NAME,&(x.split_ratios));
H5F_istore_flush_entry (f, &x, TRUE);
diff --git a/src/H5Fseq.c b/src/H5Fseq.c
index b1c7c3b..45a6815 100644
--- a/src/H5Fseq.c
+++ b/src/H5Fseq.c
@@ -174,7 +174,7 @@ H5F_seq_readv(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout,
assert(real_buf);
/* Make certain we have the correct type of property list */
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
#ifdef H5_HAVE_PARALLEL
{
@@ -548,7 +548,7 @@ H5F_seq_writev(H5F_t *f, hid_t dxpl_id, const struct H5O_layout_t *layout,
assert(real_buf);
/* Make certain we have the correct type of property list */
assert(H5I_GENPROP_LST==H5I_get_type(dxpl_id));
- assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER_NEW));
+ assert(TRUE==H5Pisa_class(dxpl_id,H5P_DATASET_XFER));
#ifdef H5_HAVE_PARALLEL
{
diff --git a/src/H5P.c b/src/H5P.c
index 0e8da7b..e1edc1b 100644
--- a/src/H5P.c
+++ b/src/H5P.c
@@ -34,6 +34,15 @@ static int interface_initialize_g = 0;
#define INTERFACE_INIT H5P_init_interface
static herr_t H5P_init_interface(void);
+/* hid_t aliases for old H5P_class_t enum values */
+/* These go away as each old-style property list is converted to a generic */
+/* property list -QAK */
+hid_t H5P_NO_CLASS=(hid_t)H5P_NO_CLASS_OLD;
+hid_t H5P_FILE_CREATE=(hid_t)H5P_FILE_CREATE_OLD;
+hid_t H5P_FILE_ACCESS=(hid_t)H5P_FILE_ACCESS_OLD;
+hid_t H5P_DATASET_CREATE=(hid_t)H5P_DATASET_CREATE_OLD;
+hid_t H5P_MOUNT=(hid_t)H5P_MOUNT_OLD;
+
/*
* Predefined property list classes. These are initialized at runtime by
* H5P_init_interface() in this source file.
@@ -167,14 +176,14 @@ H5P_init_interface(void)
FUNC_ENTER(H5P_init_interface, FAIL);
- assert(H5P_NCLASSES <= H5I_TEMPLATE_MAX - H5I_TEMPLATE_0);
+ assert(H5P_NCLASSES_OLD <= H5I_TEMPLATE_MAX - H5I_TEMPLATE_0);
/*
* Initialize the mappings between property list classes and atom
* groups. We keep the two separate because property list classes are
* publicly visible but atom groups aren't.
*/
- for (i = 0; i < H5P_NCLASSES; i++) {
+ for (i = 0; i < H5P_NCLASSES_OLD; i++) {
status = H5I_init_group((H5I_type_t)(H5I_TEMPLATE_0 +i),
H5I_TEMPID_HASHSIZE, 0, (H5I_free_t)H5P_close);
if (status < 0)
@@ -269,20 +278,20 @@ H5P_term_interface(void)
/* Destroy HDF5 library property classes & lists */
/* Check if there are any open property list classes or lists */
- for (i=0; i<H5P_NCLASSES; i++)
+ for (i=0; i<H5P_NCLASSES_OLD; i++)
n += H5I_nmembers((H5I_type_t)(H5I_TEMPLATE_0+i));
n += H5I_nmembers(H5I_GENPROP_CLS);
n += H5I_nmembers(H5I_GENPROP_LST);
/* If there are any open classes or groups, attempt to get rid of them. */
if (n) {
- for (i=0; i<H5P_NCLASSES; i++)
+ for (i=0; i<H5P_NCLASSES_OLD; i++)
H5I_clear_group((H5I_type_t)(H5I_TEMPLATE_0+i), FALSE);
H5I_clear_group(H5I_GENPROP_CLS, FALSE);
H5I_clear_group(H5I_GENPROP_LST, FALSE);
} else {
/* Close the ID groups which hold the property list classes & lists */
- for (i=0; i<H5P_NCLASSES; i++) {
+ for (i=0; i<H5P_NCLASSES_OLD; i++) {
H5I_destroy_group((H5I_type_t)(H5I_TEMPLATE_0 + i));
n++; /*H5I*/
}
@@ -317,45 +326,61 @@ H5P_term_interface(void)
*-------------------------------------------------------------------------
*/
hid_t
-H5Pcreate(H5P_class_t type)
+H5Pcreate(hid_t type)
{
hid_t ret_value = FAIL;
const void *src = NULL;
H5P_t *new_plist = NULL;
+ H5P_class_t_old old_type;
FUNC_ENTER(H5Pcreate, FAIL);
H5TRACE1("i","p",type);
- /* Allocate a new property list and initialize it with default values */
- switch (type) {
- case H5P_FILE_CREATE:
- src = &H5F_create_dflt;
- break;
- case H5P_FILE_ACCESS:
- src = &H5F_access_dflt;
- break;
- case H5P_DATASET_CREATE:
- src = &H5D_create_dflt;
- break;
- case H5P_MOUNT:
- src = &H5F_mount_dflt;
- break;
- default:
- HRETURN_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL,
- "unknown property list class");
- }
-
- /* Copy the property list */
- if (NULL==(new_plist=H5P_copy(type, src))) {
- HRETURN_ERROR(H5E_PLIST, H5E_CANTINIT, FAIL,
- "unable to copy default property list");
- }
-
- /* Atomize the new property list */
- if ((ret_value = H5P_create(type, new_plist)) < 0) {
- HRETURN_ERROR(H5E_ATOM, H5E_CANTINIT, FAIL,
- "unable to register property list");
- }
+ /* Kludge to detect generic property creations and divert them to the */
+ /* generic property list creation routine - QAK */
+ if (H5I_GENPROP_CLS == H5I_get_type(type)) {
+ if((ret_value=H5Pcreate_list(type))<0)
+ HRETURN_ERROR(H5E_PLIST, H5E_CANTCREATE, FAIL, "unable to create property list");
+ } /* end if */
+ else {
+ /* Set the type of the property list to create for older property lists */
+ old_type=(H5P_class_t_old)type;
+assert( old_type==H5P_FILE_CREATE_OLD ||
+ old_type==H5P_FILE_ACCESS_OLD ||
+ old_type==H5P_DATASET_CREATE_OLD ||
+ old_type==H5P_MOUNT_OLD);
+
+ /* Allocate a new property list and initialize it with default values */
+ switch (old_type) {
+ case H5P_FILE_CREATE_OLD:
+ src = &H5F_create_dflt;
+ break;
+ case H5P_FILE_ACCESS_OLD:
+ src = &H5F_access_dflt;
+ break;
+ case H5P_DATASET_CREATE_OLD:
+ src = &H5D_create_dflt;
+ break;
+ case H5P_MOUNT_OLD:
+ src = &H5F_mount_dflt;
+ break;
+ default:
+ HRETURN_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL,
+ "unknown property list class");
+ } /* end switch */
+
+ /* Copy the property list */
+ if (NULL==(new_plist=H5P_copy(old_type, src))) {
+ HRETURN_ERROR(H5E_PLIST, H5E_CANTINIT, FAIL,
+ "unable to copy default property list");
+ } /* end if */
+
+ /* Atomize the new property list */
+ if ((ret_value = H5P_create(old_type, new_plist)) < 0) {
+ HRETURN_ERROR(H5E_ATOM, H5E_CANTINIT, FAIL,
+ "unable to register property list");
+ } /* end if */
+ } /* end else */
FUNC_LEAVE(ret_value);
}
@@ -381,14 +406,14 @@ H5Pcreate(H5P_class_t type)
*-------------------------------------------------------------------------
*/
hid_t
-H5P_create(H5P_class_t type, H5P_t *plist)
+H5P_create(H5P_class_t_old type, H5P_t *plist)
{
hid_t ret_value = FAIL;
FUNC_ENTER(H5P_create, FAIL);
/* check args */
- assert(type >= 0 && type < H5P_NCLASSES);
+ assert(type >= 0 && type < H5P_NCLASSES_OLD);
assert(plist);
/* Atomize the new property list */
@@ -427,13 +452,22 @@ H5Pclose(hid_t plist_id)
/* Check arguments */
if (plist_id==H5P_DEFAULT)
HRETURN(SUCCEED);
- if (H5P_get_class (plist_id)<0) {
- HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a property list");
- }
-
- /* When the reference count reaches zero the resources are freed */
- if (H5I_dec_ref(plist_id) < 0)
- HRETURN_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "problem freeing property list");
+
+ /* Kludge to detect generic property creations and divert them to the */
+ /* generic property list creation routine - QAK */
+ if (H5I_GENPROP_LST == H5I_get_type(plist_id)) {
+ if(H5Pclose_list(plist_id)<0)
+ HRETURN_ERROR(H5E_PLIST, H5E_CANTDELETE, FAIL, "unable to close property list");
+ } /* end if */
+ else {
+ if (H5P_get_class (plist_id)<0) {
+ HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a property list");
+ }
+
+ /* When the reference count reaches zero the resources are freed */
+ if (H5I_dec_ref(plist_id) < 0)
+ HRETURN_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "problem freeing property list");
+ } /* end else */
FUNC_LEAVE (SUCCEED);
}
@@ -470,7 +504,7 @@ H5P_close(void *_plist)
/* Some property lists may need to do special things */
switch (plist->cls) {
- case H5P_FILE_ACCESS:
+ case H5P_FILE_ACCESS_OLD:
if (fa_list->driver_id>=0) {
H5FD_fapl_free(fa_list->driver_id, fa_list->driver_info);
H5I_dec_ref(fa_list->driver_id);
@@ -479,16 +513,16 @@ H5P_close(void *_plist)
}
break;
- case H5P_FILE_CREATE:
+ case H5P_FILE_CREATE_OLD:
break;
- case H5P_DATASET_CREATE:
+ case H5P_DATASET_CREATE_OLD:
H5O_reset(H5O_FILL, &(dc_list->fill));
H5O_reset(H5O_EFL, &(dc_list->efl));
H5O_reset(H5O_PLINE, &(dc_list->pline));
break;
- case H5P_MOUNT:
+ case H5P_MOUNT_OLD:
break;
default:
@@ -519,10 +553,10 @@ H5P_close(void *_plist)
*
*-------------------------------------------------------------------------
*/
-H5P_class_t
+hid_t
H5Pget_class(hid_t plist_id)
{
- H5P_class_t ret_value = H5P_NO_CLASS;
+ hid_t ret_value = H5P_NO_CLASS;
FUNC_ENTER(H5Pget_class, H5P_NO_CLASS);
H5TRACE1("p","i",plist_id);
@@ -548,13 +582,13 @@ H5Pget_class(hid_t plist_id)
*
*-------------------------------------------------------------------------
*/
-H5P_class_t
+H5P_class_t_old
H5P_get_class(hid_t plist_id)
{
H5I_type_t group;
- H5P_class_t ret_value = H5P_NO_CLASS;
+ H5P_class_t_old ret_value = H5P_NO_CLASS;
- FUNC_ENTER(H5P_get_class, H5P_NO_CLASS);
+ FUNC_ENTER(H5P_get_class, H5P_NO_CLASS_OLD);
if ((group = H5I_get_type(plist_id)) < 0 ||
group >= H5I_TEMPLATE_MAX ||
@@ -563,7 +597,7 @@ H5P_get_class(hid_t plist_id)
"not a property list");
}
- ret_value = (H5P_class_t)(group - H5I_TEMPLATE_0);
+ ret_value = (H5P_class_t_old)(group - H5I_TEMPLATE_0);
FUNC_LEAVE(ret_value);
}
@@ -833,7 +867,7 @@ H5Pcopy(hid_t plist_id)
{
const void *plist = NULL;
void *new_plist = NULL;
- H5P_class_t type;
+ H5P_class_t_old type;
hid_t ret_value = FAIL;
H5I_type_t group;
@@ -900,7 +934,7 @@ H5Pcopy(hid_t plist_id)
*-------------------------------------------------------------------------
*/
void *
-H5P_copy (H5P_class_t type, const void *src)
+H5P_copy (H5P_class_t_old type, const void *src)
{
size_t size;
H5P_t *dst = NULL;
@@ -912,19 +946,19 @@ H5P_copy (H5P_class_t type, const void *src)
/* How big is the property list */
switch (type) {
- case H5P_FILE_CREATE:
+ case H5P_FILE_CREATE_OLD:
size = sizeof(H5F_create_t);
break;
- case H5P_FILE_ACCESS:
+ case H5P_FILE_ACCESS_OLD:
size = sizeof(H5F_access_t);
break;
- case H5P_DATASET_CREATE:
+ case H5P_DATASET_CREATE_OLD:
size = sizeof(H5D_create_t);
break;
- case H5P_MOUNT:
+ case H5P_MOUNT_OLD:
size = sizeof(H5F_mprop_t);
break;
@@ -947,10 +981,10 @@ H5P_copy (H5P_class_t type, const void *src)
/* Deep-copy pointers */
switch (type) {
- case H5P_FILE_CREATE:
+ case H5P_FILE_CREATE_OLD:
break;
- case H5P_FILE_ACCESS:
+ case H5P_FILE_ACCESS_OLD:
fa_dst = (H5F_access_t*)dst;
if (fa_dst->driver_id>=0) {
@@ -960,7 +994,7 @@ H5P_copy (H5P_class_t type, const void *src)
}
break;
- case H5P_DATASET_CREATE:
+ case H5P_DATASET_CREATE_OLD:
dc_src = (const H5D_create_t*)src;
dc_dst = (H5D_create_t*)dst;
@@ -984,7 +1018,7 @@ H5P_copy (H5P_class_t type, const void *src)
}
break;
- case H5P_MOUNT:
+ case H5P_MOUNT_OLD:
/* Nothing to do */
break;
@@ -2290,7 +2324,7 @@ H5Pget_buffer(hid_t plist_id, void **tconv/*out*/, void **bkg/*out*/)
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HGOTO_ERROR (H5E_ARGS, H5E_BADTYPE, 0, "not a dataset transfer property list");
/* Return values */
@@ -2348,7 +2382,7 @@ H5Pset_hyper_cache(hid_t plist_id, unsigned cache, unsigned limit)
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a property list");
/* Update property list */
@@ -2386,7 +2420,7 @@ H5Pget_hyper_cache(hid_t plist_id, unsigned *cache/*out*/,
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR (H5E_ARGS, H5E_BADTYPE, FAIL, "not a dataset transfer property list");
/* Return values */
@@ -2431,7 +2465,7 @@ H5Pset_preserve(hid_t plist_id, hbool_t status)
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR (H5E_ARGS, H5E_BADTYPE, FAIL, "not a dataset transfer property list");
/* Update property list */
@@ -2469,7 +2503,7 @@ H5Pget_preserve(hid_t plist_id)
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR (H5E_ARGS, H5E_BADTYPE, FAIL,
"not a dataset transfer property list");
@@ -2790,7 +2824,7 @@ H5Pget_btree_ratios(hid_t plist_id, double *left/*out*/, double *middle/*out*/,
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a dataset transfer property list");
/* Get the split ratios */
@@ -2842,7 +2876,7 @@ H5Pset_btree_ratios(hid_t plist_id, double left, double middle,
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a dataset transfer property list");
if (left<0.0 || left>1.0 || middle<0.0 || middle>1.0 ||
right<0.0 || right>1.0)
@@ -3147,7 +3181,7 @@ H5Pset_vlen_mem_manager(hid_t plist_id, H5MM_allocate_t alloc_func,
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a dataset transfer property list");
/* Update property list */
@@ -3189,7 +3223,7 @@ H5Pget_vlen_mem_manager(hid_t plist_id, H5MM_allocate_t *alloc_func/*out*/,
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a dataset transfer property list");
if(alloc_func!=NULL) {
@@ -3412,7 +3446,7 @@ H5Pset_hyper_vector_size(hid_t plist_id, size_t vector_size)
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR (H5E_ARGS, H5E_BADTYPE, FAIL, "not a dataset transfer property list");
if (vector_size<1)
@@ -3448,7 +3482,7 @@ H5Pget_hyper_vector_size(hid_t plist_id, size_t *vector_size/*out*/)
/* Check arguments */
if (H5I_GENPROP_LST != H5I_get_type(plist_id) ||
- TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER_NEW))
+ TRUE!=H5Pisa_class(plist_id,H5P_DATASET_XFER))
HRETURN_ERROR (H5E_ARGS, H5E_BADTYPE, FAIL, "not a dataset transfer property list");
/* Return values */
diff --git a/src/H5Pprivate.h b/src/H5Pprivate.h
index fa67af4..61916f1 100644
--- a/src/H5Pprivate.h
+++ b/src/H5Pprivate.h
@@ -98,13 +98,13 @@ typedef struct {
H5D_create_t dcreate; /* Dataset creation properties */
H5F_mprop_t mount; /* Mounting properties */
} u;
- H5P_class_t cls; /* Property list class */
+ H5P_class_t_old cls; /* Property list class */
} H5P_t;
/* Private functions, not part of the publicly documented API */
__DLL__ herr_t H5P_init(void);
-__DLL__ hid_t H5P_create(H5P_class_t type, H5P_t *plist);
-__DLL__ void *H5P_copy(H5P_class_t type, const void *src);
+__DLL__ hid_t H5P_create(H5P_class_t_old type, H5P_t *plist);
+__DLL__ void *H5P_copy(H5P_class_t_old type, const void *src);
__DLL__ herr_t H5P_close(void *plist);
__DLL__ herr_t H5P_register(H5P_genclass_t *pclass, const char *name, size_t size,
void *def_value, H5P_prp_create_func_t prp_create, H5P_prp_set_func_t prp_set,
@@ -112,7 +112,7 @@ __DLL__ herr_t H5P_register(H5P_genclass_t *pclass, const char *name, size_t siz
H5P_prp_copy_func_t prp_copy, H5P_prp_close_func_t prp_close);
__DLL__ herr_t H5P_get(hid_t plist_id, const char *name, void *value);
__DLL__ herr_t H5P_set(hid_t plist_id, const char *name, void *value);
-__DLL__ H5P_class_t H5P_get_class(hid_t tid);
+__DLL__ H5P_class_t_old H5P_get_class(hid_t tid);
__DLL__ hid_t H5P_get_driver(hid_t plist_id);
/* Private functions to "peek" at properties of a certain type */
diff --git a/src/H5Ppublic.h b/src/H5Ppublic.h
index a4a6522..fec9801 100644
--- a/src/H5Ppublic.h
+++ b/src/H5Ppublic.h
@@ -37,15 +37,30 @@ typedef long off_t;
/*__MWERKS__*/
/* Property list classes */
-typedef enum H5P_class_t {
- H5P_NO_CLASS = -1, /*error return value */
- H5P_FILE_CREATE = 0, /*file creation properties */
- H5P_FILE_ACCESS = 1, /*file access properties */
- H5P_DATASET_CREATE = 2, /*dataset creation properties */
- H5P_DATASET_XFER = 3, /*data transfer properties */
- H5P_MOUNT = 4, /*file mounting properties */
- H5P_NCLASSES /*this must be last! */
-} H5P_class_t;
+typedef enum H5P_class_t_old {
+ H5P_NO_CLASS_OLD = -1, /*error return value */
+ H5P_FILE_CREATE_OLD = 0, /*file creation properties */
+ H5P_FILE_ACCESS_OLD = 1, /*file access properties */
+ H5P_DATASET_CREATE_OLD= 2, /*dataset creation properties */
+ H5P_MOUNT_OLD = 3, /*file mounting properties */
+ H5P_NCLASSES_OLD /*this must be last! */
+} H5P_class_t_old;
+
+/* This typedef should go in the v1.4 compat section when all the internal */
+/* property lists are switched to generic property lists - QAK */
+typedef hid_t H5P_class_t; /* Alias H5P_class_t to hid_t */
+/* hid_t aliases for old H5P_class_t enum values */
+/* These go away as each old-style property list is converted to a generic */
+/* property list -QAK */
+/* Also - merge/delete H5Pcreate and H5Pcreate_list */
+/* - merge/delete H5Pget_class and H5Pget_class_new */
+/* - merge/delete H5Pcopy and H5Pcopy_new */
+/* - merge/delete H5Pclose and H5Pclose_list */
+__DLLVAR__ hid_t H5P_NO_CLASS;
+__DLLVAR__ hid_t H5P_FILE_CREATE;
+__DLLVAR__ hid_t H5P_FILE_ACCESS;
+__DLLVAR__ hid_t H5P_DATASET_CREATE;
+__DLLVAR__ hid_t H5P_MOUNT;
/* H5P_DATASET_XFER was the name from the beginning through 1.2. It was
* changed to H5P_DATA_XFER on v1.3.0. Then it was changed back to
@@ -86,7 +101,7 @@ extern "C" {
#define H5P_FILE_ACCESS_HASH_SIZE 17
#define H5P_DATASET_CREATE_NEW (H5open(), H5P_CLS_DATASET_CREATE_g)
#define H5P_DATASET_CREATE_HASH_SIZE 17
-#define H5P_DATASET_XFER_NEW (H5open(), H5P_CLS_DATASET_XFER_g)
+#define H5P_DATASET_XFER (H5open(), H5P_CLS_DATASET_XFER_g)
#define H5P_DATASET_XFER_HASH_SIZE 17
#define H5P_MOUNT_NEW (H5open(), H5P_CLS_MOUNT_g)
#define H5P_MOUNT_HASH_SIZE 17
@@ -146,10 +161,10 @@ __DLL__ herr_t H5Premove(hid_t plist_id, const char *name);
__DLL__ herr_t H5Punregister(hid_t pclass_id, const char *name);
__DLL__ herr_t H5Pclose_list(hid_t plist_id);
__DLL__ herr_t H5Pclose_class(hid_t plist_id);
-__DLL__ hid_t H5Pcreate(H5P_class_t type);
+__DLL__ hid_t H5Pcreate(hid_t type);
__DLL__ herr_t H5Pclose(hid_t plist_id);
__DLL__ hid_t H5Pcopy(hid_t plist_id);
-__DLL__ H5P_class_t H5Pget_class(hid_t plist_id);
+__DLL__ hid_t H5Pget_class(hid_t plist_id);
__DLL__ herr_t H5Pget_version(hid_t plist_id, int *boot/*out*/,
int *freelist/*out*/, int *stab/*out*/,
int *shhdr/*out*/);
diff --git a/test/cmpd_dset.c b/test/cmpd_dset.c
index ee00e50..0fbb346 100644
--- a/test/cmpd_dset.c
+++ b/test/cmpd_dset.c
@@ -157,7 +157,7 @@ main (int argc, char *argv[])
if ((space = H5Screate_simple (2, dim, NULL))<0) goto error;
/* Create xfer properties to preserve initialized data */
- if ((PRESERVE = H5Pcreate_list (H5P_DATASET_XFER_NEW))<0) goto error;
+ if ((PRESERVE = H5Pcreate (H5P_DATASET_XFER))<0) goto error;
if (H5Pset_preserve (PRESERVE, 1)<0) goto error;
/*
@@ -703,7 +703,7 @@ main (int argc, char *argv[])
/*
* Release resources.
*/
- H5Pclose_list (PRESERVE);
+ H5Pclose (PRESERVE);
H5Dclose (dataset);
H5Fclose (file);
diff --git a/test/dsets.c b/test/dsets.c
index 40d5f90..6716e02 100644
--- a/test/dsets.c
+++ b/test/dsets.c
@@ -198,7 +198,7 @@ test_simple_io(hid_t file)
/* Create a small conversion buffer to test strip mining */
tconv_buf = malloc (1000);
- xfer = H5Pcreate_list (H5P_DATASET_XFER_NEW);
+ xfer = H5Pcreate (H5P_DATASET_XFER);
assert (xfer>=0);
if (H5Pset_buffer (xfer, 1000, tconv_buf, NULL)<0) goto error;
@@ -226,7 +226,7 @@ test_simple_io(hid_t file)
}
}
- i=H5Pclose_list (xfer);
+ i=H5Pclose (xfer);
H5Dclose(dataset);
free (tconv_buf);
PASSED();
@@ -383,7 +383,7 @@ test_compression(hid_t file)
* Create a small conversion buffer to test strip mining. We
* might as well test all we can!
*/
- if ((xfer = H5Pcreate_list (H5P_DATASET_XFER_NEW))<0) goto error;
+ if ((xfer = H5Pcreate (H5P_DATASET_XFER))<0) goto error;
tconv_buf = malloc (1000);
if (H5Pset_buffer (xfer, 1000, tconv_buf, NULL)<0) goto error;
@@ -637,7 +637,7 @@ test_compression(hid_t file)
* Cleanup
*----------------------------------------------------------------------
*/
- if (H5Pclose_list (xfer)<0) goto error;
+ if (H5Pclose (xfer)<0) goto error;
if (H5Pclose (dc)<0) goto error;
if (H5Dclose(dataset)<0) goto error;
free (tconv_buf);
diff --git a/test/tarray.c b/test/tarray.c
index fe816d5..4b0943c 100644
--- a/test/tarray.c
+++ b/test/tarray.c
@@ -1141,7 +1141,7 @@ test_array_vlen_atomic(void)
CHECK(ret, FAIL, "H5Tclose");
/* Change to the custom memory allocation routines for reading VL data */
- xfer_pid=H5Pcreate_list(H5P_DATASET_XFER_NEW);
+ xfer_pid=H5Pcreate(H5P_DATASET_XFER);
CHECK(xfer_pid, FAIL, "H5Pcreate");
ret=H5Pset_vlen_mem_manager(xfer_pid,test_array_alloc_custom,&mem_used,test_array_free_custom,&mem_used);
@@ -1196,7 +1196,7 @@ test_array_vlen_atomic(void)
CHECK(ret, FAIL, "H5Dvlen_reclaim");
/* Close dataset transfer property list */
- ret = H5Pclose_list(xfer_pid);
+ ret = H5Pclose(xfer_pid);
CHECK(ret, FAIL, "H5Pclose");
/* Close Datatype */
@@ -1395,7 +1395,7 @@ test_array_vlen_array(void)
CHECK(ret, FAIL, "H5Tclose");
/* Change to the custom memory allocation routines for reading VL data */
- xfer_pid=H5Pcreate_list(H5P_DATASET_XFER_NEW);
+ xfer_pid=H5Pcreate(H5P_DATASET_XFER);
CHECK(xfer_pid, FAIL, "H5Pcreate");
ret=H5Pset_vlen_mem_manager(xfer_pid,test_array_alloc_custom,&mem_used,test_array_free_custom,&mem_used);
@@ -1452,7 +1452,7 @@ test_array_vlen_array(void)
CHECK(ret, FAIL, "H5Dvlen_reclaim");
/* Close dataset transfer property list */
- ret = H5Pclose_list(xfer_pid);
+ ret = H5Pclose(xfer_pid);
CHECK(ret, FAIL, "H5Pclose");
/* Close Datatype */
diff --git a/test/tselect.c b/test/tselect.c
index 22743da..d0d889d 100644
--- a/test/tselect.c
+++ b/test/tselect.c
@@ -2227,8 +2227,8 @@ test_select_hyper_union(void)
dataset=H5Dcreate(fid1,"Dataset4",H5T_NATIVE_UCHAR,sid1,H5P_DEFAULT);
CHECK(dataset, FAIL, "H5Dcreate");
- xfer = H5Pcreate_list (H5P_DATASET_XFER_NEW);
- CHECK(xfer, FAIL, "H5Pcreate_list");
+ xfer = H5Pcreate (H5P_DATASET_XFER);
+ CHECK(xfer, FAIL, "H5Pcreate");
ret = H5Pset_hyper_cache(xfer,0,1);
CHECK(ret, FAIL, "H5Pset_hyper_cache");
@@ -2258,7 +2258,7 @@ test_select_hyper_union(void)
CHECK(ret, FAIL, "H5Dread");
/* Close transfer property list */
- ret = H5Pclose_list(xfer);
+ ret = H5Pclose(xfer);
CHECK(ret, FAIL, "H5Pclose");
/* Compare data read with data written out */
@@ -3170,7 +3170,7 @@ test_select(void)
MESSAGE(5, ("Testing Selections\n"));
/* Create a dataset transfer property list */
- plist_id=H5Pcreate_list(H5P_DATASET_XFER_NEW);
+ plist_id=H5Pcreate(H5P_DATASET_XFER);
CHECK(plist_id, FAIL, "H5Pcreate");
/* test I/O with a very small buffer for reads */
@@ -3231,7 +3231,7 @@ test_select(void)
CHECK(ret, FAIL, "H5Pclose");
/* Close dataset transfer property list */
- ret=H5Pclose_list(plist_id);
+ ret=H5Pclose(plist_id);
CHECK(ret, FAIL, "H5Pclose");
} /* test_select() */
diff --git a/test/tvlstr.c b/test/tvlstr.c
index 40c3880..2a8ecbc 100644
--- a/test/tvlstr.c
+++ b/test/tvlstr.c
@@ -154,7 +154,7 @@ test_vlstrings_basic(void)
CHECK(ret, FAIL, "H5Dwrite");
/* Change to the custom memory allocation routines for reading VL string */
- xfer_pid=H5Pcreate_list(H5P_DATASET_XFER_NEW);
+ xfer_pid=H5Pcreate(H5P_DATASET_XFER);
CHECK(xfer_pid, FAIL, "H5Pcreate");
ret=H5Pset_vlen_mem_manager(xfer_pid,test_vlstr_alloc_custom,&mem_used,test_vlstr_free_custom,&mem_used);
@@ -212,7 +212,7 @@ test_vlstrings_basic(void)
CHECK(ret, FAIL, "H5Sclose");
/* Close dataset transfer property list */
- ret = H5Pclose_list(xfer_pid);
+ ret = H5Pclose(xfer_pid);
CHECK(ret, FAIL, "H5Pclose");
/* Close file */
diff --git a/test/tvltypes.c b/test/tvltypes.c
index 3383818..8e59bd2 100644
--- a/test/tvltypes.c
+++ b/test/tvltypes.c
@@ -149,7 +149,7 @@ test_vltypes_vlen_atomic(void)
CHECK(ret, FAIL, "H5Dwrite");
/* Change to the custom memory allocation routines for reading VL data */
- xfer_pid=H5Pcreate_list(H5P_DATASET_XFER_NEW);
+ xfer_pid=H5Pcreate(H5P_DATASET_XFER);
CHECK(xfer_pid, FAIL, "H5Pcreate");
ret=H5Pset_vlen_mem_manager(xfer_pid,test_vltypes_alloc_custom,&mem_used,test_vltypes_free_custom,&mem_used);
@@ -210,7 +210,7 @@ test_vltypes_vlen_atomic(void)
CHECK(ret, FAIL, "H5Sclose");
/* Close dataset transfer property list */
- ret = H5Pclose_list(xfer_pid);
+ ret = H5Pclose(xfer_pid);
CHECK(ret, FAIL, "H5Pclose");
/* Close file */
@@ -289,7 +289,7 @@ test_vltypes_vlen_compound(void)
CHECK(ret, FAIL, "H5Dwrite");
/* Change to the custom memory allocation routines for reading VL data */
- xfer_pid=H5Pcreate_list(H5P_DATASET_XFER_NEW);
+ xfer_pid=H5Pcreate(H5P_DATASET_XFER);
CHECK(xfer_pid, FAIL, "H5Pcreate");
ret=H5Pset_vlen_mem_manager(xfer_pid,test_vltypes_alloc_custom,&mem_used,test_vltypes_free_custom,&mem_used);
@@ -359,7 +359,7 @@ test_vltypes_vlen_compound(void)
CHECK(ret, FAIL, "H5Sclose");
/* Close dataset transfer property list */
- ret = H5Pclose_list(xfer_pid);
+ ret = H5Pclose(xfer_pid);
CHECK(ret, FAIL, "H5Pclose");
/* Close file */
@@ -441,7 +441,7 @@ test_vltypes_compound_vlen_atomic(void)
CHECK(ret, FAIL, "H5Dwrite");
/* Change to the custom memory allocation routines for reading VL data */
- xfer_pid=H5Pcreate_list(H5P_DATASET_XFER_NEW);
+ xfer_pid=H5Pcreate(H5P_DATASET_XFER);
CHECK(xfer_pid, FAIL, "H5Pcreate");
ret=H5Pset_vlen_mem_manager(xfer_pid,test_vltypes_alloc_custom,&mem_used,test_vltypes_free_custom,&mem_used);
@@ -516,7 +516,7 @@ test_vltypes_compound_vlen_atomic(void)
CHECK(ret, FAIL, "H5Sclose");
/* Close dataset transfer property list */
- ret = H5Pclose_list(xfer_pid);
+ ret = H5Pclose(xfer_pid);
CHECK(ret, FAIL, "H5Pclose");
/* Close file */
@@ -658,7 +658,7 @@ test_vltypes_vlen_vlen_atomic(void)
CHECK(dataset, FAIL, "H5Dopen");
/* Change to the custom memory allocation routines for reading VL data */
- xfer_pid=H5Pcreate_list(H5P_DATASET_XFER_NEW);
+ xfer_pid=H5Pcreate(H5P_DATASET_XFER);
CHECK(xfer_pid, FAIL, "H5Pcreate");
ret=H5Pset_vlen_mem_manager(xfer_pid,test_vltypes_alloc_custom,&mem_used,test_vltypes_free_custom,&mem_used);
@@ -732,7 +732,7 @@ test_vltypes_vlen_vlen_atomic(void)
CHECK(ret, FAIL, "H5Sclose");
/* Close dataset transfer property list */
- ret = H5Pclose_list(xfer_pid);
+ ret = H5Pclose(xfer_pid);
CHECK(ret, FAIL, "H5Pclose");
/* Close file */
diff --git a/tools/lib/talign.c b/tools/lib/talign.c
index 91cec99..5c4f88d 100644
--- a/tools/lib/talign.c
+++ b/tools/lib/talign.c
@@ -91,7 +91,7 @@ int main(void)
H5Tinsert(cmp3, "Not Ok", 0, array_dt);
H5Tclose(array_dt);
- plist = H5Pcreate_list(H5P_DATASET_XFER_NEW);
+ plist = H5Pcreate(H5P_DATASET_XFER);
H5Pset_preserve(plist, 1);
/*
@@ -166,7 +166,7 @@ int main(void)
H5Tclose(cmp1);
H5Tclose(cmp2);
H5Tclose(cmp3);
- H5Pclose_list(plist);
+ H5Pclose(plist);
H5Fclose(fil);
unlink(fname);
fflush(stdout);