Go to the documentation of this file.
52#define OOFEM_EXIT(code) \
53 oofem_logger.printStatistics(); \
54 fprintf(stderr, "oofem exit code %d\n", code); \
63 RuntimeException(
const char* _func,
const char* _file,
int _line,
const char *format, ...)
64 #if defined(__GNUC__) || defined (__clang)
65 __attribute__((format(printf, 5, 6)))
68 const char*
what() const noexcept override;
78#define OOFEM_FATAL(...) { throw RuntimeException(__func__, __FILE__, __LINE__, __VA_ARGS__);}
79#define OOFEM_ERROR(...) { throw RuntimeException(__func__, __FILE__, __LINE__, __VA_ARGS__);}
80#define OOFEM_WARNING(...) { if(warningIsError){ oofem_logger.writeELogMsg(Logger::LOG_LEVEL_WARNING,errorInfo(__func__).c_str(), __FILE__, __LINE__,"Promoting warning to error."); OOFEM_ERROR(__VA_ARGS__); } oofem_logger.writeELogMsg(Logger :: LOG_LEVEL_WARNING, errorInfo(__func__).c_str(), __FILE__, __LINE__, __VA_ARGS__); }
81#define OOFEM_SERROR(...) { oofem_logger.writeELogMsg(Logger :: LOG_LEVEL_ERROR, __func__, __FILE__, __LINE__, __VA_ARGS__); OOFEM_EXIT(1); }
82#define OOFEM_SWARNING(...) oofem_logger.writeELogMsg(Logger :: LOG_LEVEL_WARNING, __func__, __FILE__, __LINE__, __VA_ARGS__)
RuntimeException(const char *_func, const char *_file, int _line, const char *format,...)
const char * what() const noexcept override
This page is part of the
OOFEM-3.0 documentation. Copyright Copyright (C) 1994-2025 Borek Patzak
Bořek Patzák
Project e-mail:
oofem@fsv.cvut.cz
Generated at for OOFEM by
doxygen
1.15.0 written by Dimitri van Heesch,
© 1997-2011