diff options
author | Binh-Minh Ribler <bmribler@hdfgroup.org> | 2005-12-29 11:41:02 (GMT) |
---|---|---|
committer | Binh-Minh Ribler <bmribler@hdfgroup.org> | 2005-12-29 11:41:02 (GMT) |
commit | e25b9b5f7002b7a19000fc8d81cf4a96776cd671 (patch) | |
tree | d856506c45a818f5da6b87455bab9f77fae4dc21 /c++/src/H5File.cpp | |
parent | d073ddf81ee053f9219ffaf789998a6f619a7584 (diff) | |
download | hdf5-e25b9b5f7002b7a19000fc8d81cf4a96776cd671.zip hdf5-e25b9b5f7002b7a19000fc8d81cf4a96776cd671.tar.gz hdf5-e25b9b5f7002b7a19000fc8d81cf4a96776cd671.tar.bz2 |
[svn-r11845] Purpose: Adding another wrapper/Fixing typos
Description:
Added missing member function H5File::flush
Fixed parameters passed to H5Awrite
Other typos
Platforms tested:
Linux 2.4 (heping)
SunOS 5.8 64-bit (sol)
Diffstat (limited to 'c++/src/H5File.cpp')
-rw-r--r-- | c++/src/H5File.cpp | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/c++/src/H5File.cpp b/c++/src/H5File.cpp index abcbc6b..b3f1c35 100644 --- a/c++/src/H5File.cpp +++ b/c++/src/H5File.cpp @@ -148,6 +148,25 @@ void H5File::p_get_file(const char* name, unsigned int flags, const FileCreatPro H5File::H5File( const H5File& original ) : IdComponent( original ) {} //-------------------------------------------------------------------------- +// Function: H5File::flush +///\brief Flushes all buffers associated with a file to disk. +///\param scope - IN: Specifies the scope of the flushing action, +/// which can be either of these values: +/// \li \c H5F_SCOPE_GLOBAL - Flushes the entire virtual file +/// \li \c H5F_SCOPE_LOCAL - Flushes only the specified file +///\exception H5::FileIException +// Programmer Binh-Minh Ribler - Dec. 2005 +//-------------------------------------------------------------------------- +void H5File::flush(H5F_scope_t scope) const +{ + herr_t ret_value = H5Fflush( id, scope ); + if( ret_value < 0 ) + { + throw FileIException("H5File::flush", "H5Fflush failed"); + } +} + +//-------------------------------------------------------------------------- // Function: H5File::isHdf5 ///\brief Determines whether a file in HDF5 format. ///\param name - IN: Name of the file @@ -155,7 +174,7 @@ H5File::H5File( const H5File& original ) : IdComponent( original ) {} ///\exception H5::FileIException // Programmer Binh-Minh Ribler - 2000 //-------------------------------------------------------------------------- -bool H5File::isHdf5(const char* name ) +bool H5File::isHdf5(const char* name) { // Calls C routine H5Fis_hdf5 to determine whether the file is in // HDF5 format. It returns positive value, 0, or negative value |