|
jaulib v1.5.0
Jau Support Library (C++, Java, ..)
|
#include <cstdlib>#include <cstdint>#include <cstring>#include <string>#include <cstdio>#include <cstdarg>#include <string_view>#include <jau/cpp_lang_util.hpp>#include <jau/environment.hpp>#include <jau/string_util.hpp>#include <jau/string_cfmt.hpp>Go to the source code of this file.
Namespaces | |
| namespace | jau |
| __pack(...): Produces MSVC, clang and gcc compatible lead-in and -out macros. | |
Macros | |
| #define | jau_ABORT(...) |
| Use for unconditional ::abort() call with given messages, prefix '[elapsed_time] ABORT @ file:line func: '. | |
| #define | jau_COND_PRINT(C, ...) |
| Use for conditional plain messages, prefix '[elapsed_time] '. | |
| #define | jau_DBG_ERR_PRINT(...) |
| Use for environment-variable environment::DEBUG conditional error messages, prefix '[elapsed_time] Debug @ FILE:LINE FUNC: '. | |
| #define | jau_DBG_JNI_PRINT(...) |
| Use for environment-variable environment::DEBUG_JNI conditional debug messages, prefix '[elapsed_time] Debug: '. | |
| #define | jau_DBG_PRINT(fmt, ...) |
| Use for environment-variable environment::DEBUG conditional debug messages, prefix '[elapsed_time] Debug: '. | |
| #define | jau_DBG_PRINT_LINE(fmt, ...) |
| #define | jau_DBG_WARN_PRINT(...) |
| Use for environment-variable environment::DEBUG conditional warning messages, prefix '[elapsed_time] Warning @ FILE:LINE FUNC: '. | |
| #define | jau_dbgPrint1(out, printPrefix, msg, fmt, ...) |
| #define | jau_dbgPrint1Line(out, printPrefix, msg, fmt, ...) |
| #define | jau_dbgPrint2(out, msg, addErrno, addBacktrace, func, file, line, fmt, ...) |
| #define | jau_dbgPrint2Line(out, msg, addErrno, addBacktrace, func, file, line, fmt, ...) |
| #define | jau_ERR_PRINT(...) |
| Use for unconditional error messages, prefix '[elapsed_time] Error @ FILE:LINE FUNC: '. | |
| #define | jau_ERR_PRINT2(...) |
| Use for unconditional error messages, prefix '[elapsed_time] Error @ FILE:LINE FUNC: '. | |
| #define | jau_ERR_PRINT3(...) |
| Use for unconditional error messages, prefix '[elapsed_time] Error @ FILE:LINE FUNC: '. | |
| #define | jau_fprintf_td(stream, fmt, ...) |
| #define | jau_fprintf_td2(elapsed_ms, stream, fmt, ...) |
| #define | jau_INFO_PRINT(fmt, ...) |
| Use for unconditional informal messages, prefix '[elapsed_time] Info: '. | |
| #define | jau_INFO_PRINT_LINE(fmt, ...) |
| #define | jau_IRQ_PRINT(...) |
| Use for unconditional interruption messages, prefix '[elapsed_time] Interrupted @ FILE:LINE FUNC: '. | |
| #define | jau_PERF2_TS_T0() |
| #define | jau_PERF2_TS_TD(m) |
| #define | jau_PERF3_TS_T0() |
| #define | jau_PERF3_TS_TD(m) |
| #define | jau_PERF_TS_T0() |
| #define | jau_PERF_TS_T0_BASE() |
| #define | jau_PERF_TS_TD(m) |
| #define | jau_PERF_TS_TD_BASE(m) |
| #define | jau_PLAIN_PRINT(printPrefix, fmt, ...) |
| Use for unconditional plain messages, prefix '[elapsed_time] ' if printPrefix == true. | |
| #define | jau_WARN_PRINT(...) |
| Use for unconditional warning messages, prefix '[elapsed_time] Warning @ FILE:LINE FUNC: '. | |
| #define | jau_WORDY_PRINT(...) |
| Use for environment-variable environment::VERBOSE conditional verbose messages, prefix '[elapsed_time] Wordy: '. | |
Functions | |
| template<typename... Args> | |
| int | jau::fprintf_td (const uint64_t elapsed_ms, FILE *stream, std::string_view format, const Args &...args) noexcept |
| Convenient fprintf() invocation, prepending the given elapsed_ms timestamp. | |
| template<typename... Args> | |
| int | jau::fprintf_td (FILE *stream, std::string_view format, const Args &...args) noexcept |
| Convenient fprintf() invocation, prepending the environment::getElapsedMillisecond() timestamp. | |
| template<class List> | |
| void | jau::printSharedPtrList (const std::string &prefix, List &list) noexcept |
| #define jau_dbgPrint1 | ( | out, | |
| printPrefix, | |||
| msg, | |||
| fmt, | |||
| ... ) |
| #define jau_dbgPrint1Line | ( | out, | |
| printPrefix, | |||
| msg, | |||
| fmt, | |||
| ... ) |
| #define jau_dbgPrint2 | ( | out, | |
| msg, | |||
| addErrno, | |||
| addBacktrace, | |||
| func, | |||
| file, | |||
| line, | |||
| fmt, | |||
| ... ) |
| #define jau_dbgPrint2Line | ( | out, | |
| msg, | |||
| addErrno, | |||
| addBacktrace, | |||
| func, | |||
| file, | |||
| line, | |||
| fmt, | |||
| ... ) |
| #define jau_DBG_PRINT | ( | fmt, | |
| ... ) |
Use for environment-variable environment::DEBUG conditional debug messages, prefix '[elapsed_time] Debug: '.
| #define jau_DBG_PRINT_LINE | ( | fmt, | |
| ... ) |
| #define jau_DBG_JNI_PRINT | ( | ... | ) |
Use for environment-variable environment::DEBUG_JNI conditional debug messages, prefix '[elapsed_time] Debug: '.
| #define jau_DBG_WARN_PRINT | ( | ... | ) |
Use for environment-variable environment::DEBUG conditional warning messages, prefix '[elapsed_time] Warning @ FILE:LINE FUNC: '.
| #define jau_DBG_ERR_PRINT | ( | ... | ) |
Use for environment-variable environment::DEBUG conditional error messages, prefix '[elapsed_time] Debug @ FILE:LINE FUNC: '.
Function also appends last errno, strerror(errno) and full backtrace
| #define jau_WORDY_PRINT | ( | ... | ) |
Use for environment-variable environment::VERBOSE conditional verbose messages, prefix '[elapsed_time] Wordy: '.
'Wordy' is the shorter English form of the Latin word 'verbosus', from which the word 'verbosity' is sourced.
| #define jau_PERF_TS_T0_BASE | ( | ) |
| #define jau_PERF_TS_TD_BASE | ( | m | ) |
| #define jau_ABORT | ( | ... | ) |
Use for unconditional ::abort() call with given messages, prefix '[elapsed_time] ABORT @ file:line func: '.
Function also appends last errno and strerror(errno).
| #define jau_ERR_PRINT | ( | ... | ) |
Use for unconditional error messages, prefix '[elapsed_time] Error @ FILE:LINE FUNC: '.
Function also appends last errno, strerror(errno) and full backtrace
| #define jau_ERR_PRINT2 | ( | ... | ) |
Use for unconditional error messages, prefix '[elapsed_time] Error @ FILE:LINE FUNC: '.
Function also appends last errno and strerror(errno). No backtrace.
| #define jau_ERR_PRINT3 | ( | ... | ) |
Use for unconditional error messages, prefix '[elapsed_time] Error @ FILE:LINE FUNC: '.
Function also appends last errno and strerror(errno). Full backtrace.
| #define jau_IRQ_PRINT | ( | ... | ) |
Use for unconditional interruption messages, prefix '[elapsed_time] Interrupted @ FILE:LINE FUNC: '.
Function also appends last errno and strerror(errno).
| #define jau_WARN_PRINT | ( | ... | ) |
Use for unconditional warning messages, prefix '[elapsed_time] Warning @ FILE:LINE FUNC: '.
| #define jau_INFO_PRINT | ( | fmt, | |
| ... ) |
Use for unconditional informal messages, prefix '[elapsed_time] Info: '.
| #define jau_INFO_PRINT_LINE | ( | fmt, | |
| ... ) |
| #define jau_PLAIN_PRINT | ( | printPrefix, | |
| fmt, | |||
| ... ) |
Use for unconditional plain messages, prefix '[elapsed_time] ' if printPrefix == true.
| #define jau_COND_PRINT | ( | C, | |
| ... ) |
| #define jau_fprintf_td2 | ( | elapsed_ms, | |
| stream, | |||
| fmt, | |||
| ... ) |
| #define jau_fprintf_td | ( | stream, | |
| fmt, | |||
| ... ) |