Commit 219d6ec7 authored by Ben Boeckel's avatar Ben Boeckel
Browse files

moab: export error handling functions

Upstream commit fa6c669718056da9677c148e8fdffa67098ff421.
parent 3302e724
......@@ -5,6 +5,8 @@
#define __func__ __FUNCTION__
#endif
#include "moab_export.h"
#include "moab/Types.hpp"
#include <sstream>
......@@ -17,18 +19,23 @@ namespace moab {
enum ErrorType {MB_ERROR_TYPE_NEW_GLOBAL = 0, MB_ERROR_TYPE_NEW_LOCAL = 1, MB_ERROR_TYPE_EXISTING = 2};
//! Initialize MOAB error handler (e.g. create a utility object for printing error output)
MOAB_EXPORT
void MBErrorHandler_Init();
//! Finalize MOAB error handler (e.g. delete the utility object for printing error output)
MOAB_EXPORT
void MBErrorHandler_Finalize();
//! Indicates whether MBErrorHandler_Init has been called
MOAB_EXPORT
bool MBErrorHandler_Initialized();
//! Get information about the last error
MOAB_EXPORT
void MBErrorHandler_GetLastError(std::string& error);
//! Routine that is called to create a new error or handle an existing one
MOAB_EXPORT
ErrorCode MBError(int line, const char* func, const char* file, const char* dir,
ErrorCode err_code, const char* err_msg, ErrorType err_type);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment