diff options
author | Binh-Minh Ribler <bmribler@hdfgroup.org> | 2001-03-10 03:59:46 (GMT) |
---|---|---|
committer | Binh-Minh Ribler <bmribler@hdfgroup.org> | 2001-03-10 03:59:46 (GMT) |
commit | 9cd9f7f5216fbc30b10426f5bd11e26d81668eac (patch) | |
tree | be3e4f25e5a870f8e98c7b1cfce3917a5dd19269 /c++/src/H5Library.cpp | |
parent | cd29e12e0252ccfc969281c5dabd991b46203f05 (diff) | |
download | hdf5-9cd9f7f5216fbc30b10426f5bd11e26d81668eac.zip hdf5-9cd9f7f5216fbc30b10426f5bd11e26d81668eac.tar.gz hdf5-9cd9f7f5216fbc30b10426f5bd11e26d81668eac.tar.bz2 |
[svn-r3602]
Purpose: Usability enhancement
Description:
- Added more information about the failure to all the throw's,
i.e, member function name and more detail about the failure, where
appropriate. Also, added exception throws for private functions,
such as p_close to provide more specific details.
- Added two api functions: Exception::getFuncName() and
Exception::getCFuncName() to provide the name of the member
function where failure occurs.
- Fixed some typos, one of which caused segn. fault in some
situations (resetIdComponent was accidentally called twice
in a couple of places :)
Platforms:
arabica (sparc-sun-solaris 2.7)
Diffstat (limited to 'c++/src/H5Library.cpp')
-rw-r--r-- | c++/src/H5Library.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/c++/src/H5Library.cpp b/c++/src/H5Library.cpp index ffce037..44f94b4 100644 --- a/c++/src/H5Library.cpp +++ b/c++/src/H5Library.cpp @@ -17,7 +17,7 @@ void H5Library::open() herr_t ret_value = H5open(); if( ret_value < 0 ) { - throw LibraryIException(); + throw LibraryIException("H5Library::open", "H5open failed"); } } @@ -27,7 +27,7 @@ void H5Library::close() herr_t ret_value = H5close(); if( ret_value < 0 ) { - throw LibraryIException(); + throw LibraryIException("H5Library::close", "H5close failed"); } } @@ -37,7 +37,7 @@ void H5Library::dontAtExit() herr_t ret_value = H5dont_atexit(); if( ret_value < 0 ) { - throw LibraryIException(); + throw LibraryIException("H5Library::dontAtExit", "H5dont_atexit failed"); } } @@ -47,7 +47,7 @@ void H5Library::getLibVersion( unsigned& majnum, unsigned& minnum, unsigned& rel herr_t ret_value = H5get_libversion( &majnum, &minnum, &relnum ); if( ret_value < 0 ) { - throw LibraryIException(); + throw LibraryIException("H5Library::getLibVersion", "H5get_libversion failed"); } } @@ -58,7 +58,7 @@ void H5Library::checkVersion( unsigned majnum, unsigned minnum, unsigned relnum herr_t ret_value = H5check_version( majnum, minnum, relnum ); if( ret_value < 0 ) { - throw LibraryIException(); + throw LibraryIException("H5Library::checkVersion", "H5check_version failed"); } } |