Added first write routines to C++ API of H5FED.

This commit is contained in:
Benedikt Oswald
2007-12-19 08:55:51 +00:00
parent 3a350f975d
commit 16a481c4fa
2 changed files with 117 additions and 1 deletions
+42
View File
@@ -44,6 +44,7 @@
//}
/** activate namespaces */
using namespace std;
@@ -140,12 +141,53 @@ H5FED_RETURN_CODE H5Fed::closeFile()
return(OKCODE);
}
/****** STORE routines*****************************************************/
/*!
\ingroup h5fed_c_api
Stores the the coordinates of a specific vertex at level \c level
with id \c vertex_id of the tetrahedral mesh.
\return value \c >=0 on success
\return \c -1 on error
*/
H5FED_RETURN_CODE H5Fed::storeVertexCoordinate(
unsigned int level, /*!< mesh level */
unsigned int vertex_id, /*!< global vertex id */
std::vector<double> /*!< 3-tuple of coordinates */
)
{
;
}
/*!
\ingroup h5fed_c_api
Stores the 4-tuple, that contains the specific indices describing
a tetrahedron with id \c tet_id at level \c level of the tetrahedral
mesh.
\return value \c >=0 on success
\return \c -1 on error
*/
H5FED_RETURN_CODE H5Fed::H5FedStoreTetrahedron (
const unsigned int level, /*!< mesh level */
const unsigned int tet_id, /*!< global tetrahedron id */
const unsigned int parent_id, /*!< parent id if level \c >0 else \x -1 */
const std::vector<unsigned int> tet /*!< 4-tuple with vertex id's */
)
{
return(OKCODE);
}
}
+75 -1
View File
@@ -42,6 +42,9 @@
#include <string>
#include <complex>
/** include fundamental HDF5 header files */
#include <hdf5.h>
#ifndef H5FED_HH
#define H5FED_HH
@@ -49,7 +52,7 @@
namespace H5Fed
{
/** \brief Define return codes */
enum H5FED_RETURN_CODE{OKCODE,ERROR};
enum H5FED_RETURN_CODE{OKCODE=0,ERROR=-1};
@@ -72,7 +75,78 @@ namespace H5Fed
/****** INQUIRY routines *****************************************************/
/****** STORE routines*****************************************************/
/*!
\ingroup h5fed_c_api
Stores the the coordinates of a specific vertex at level \c level
with id \c vertex_id of the tetrahedral mesh.
\return value \c >=0 on success
\return \c -1 on error
*/
H5FED_RETURN_CODE storeVertexCoordinate(
unsigned int level, /*!< mesh level */
unsigned int vertex_id, /*!< global vertex id */
std::vector<double> /*!< 3-tuple of coordinates */
);
/*!
\ingroup h5fed_c_api
Stores the 4-tuple, that contains the specific indices describing
a tetrahedron with id \c tet_id at level \c level of the tetrahedral
mesh.
\return value \c >=0 on success
\return \c -1 on error
*/
H5FED_RETURN_CODE H5FedStoreTetrahedron (
const unsigned int level, /*!< mesh level */
const unsigned int tet_id, /*!< global tetrahedron id */
const unsigned int parent_id, /*!< parent id if level \c >0 else \x -1 */
const std::vector<unsigned int> tet /*!< 4-tuple with vertex id's */
);
/****** UPWARD ADJACENCY routines *********************************************/
/****** DOWNWARD ADJACENCY routines *********************************************/
/****** routines for accessing degrees of freedom DoF *************************/
protected: