CppCommon
1.0.4.1
C++ Common Library
|
Stack trace snapshot provider. More...
#include <stack_trace.h>
Classes | |
struct | Frame |
Stack trace frame. More... | |
Public Member Functions | |
StackTrace (int skip=0) | |
Capture the current stack trace snapshot. More... | |
StackTrace (const StackTrace &)=default | |
StackTrace (StackTrace &&) noexcept=default | |
~StackTrace ()=default | |
StackTrace & | operator= (const StackTrace &)=default |
StackTrace & | operator= (StackTrace &&) noexcept=default |
const std::vector< Frame > & | frames () const noexcept |
Get stack trace frames. More... | |
std::string | string () const |
Get string from the current stack trace snapshot. More... | |
Friends | |
std::ostream & | operator<< (std::ostream &os, const StackTrace &stack_trace) |
Output stack trace into the given output stream. More... | |
Stack trace snapshot provider.
Capture the current stack trace snapshot with easy-to-use interface.
Thread-safe.
Definition at line 32 of file stack_trace.h.
|
explicit |
Capture the current stack trace snapshot.
skip | - Skip frames count (default is 0) |
Definition at line 63 of file stack_trace.cpp.
|
default |
|
defaultnoexcept |
|
default |
|
inlinenoexcept |
Get stack trace frames.
Definition at line 66 of file stack_trace.h.
|
default |
|
defaultnoexcept |
|
inline |
Get string from the current stack trace snapshot.
Definition at line 69 of file stack_trace.h.
|
friend |
Output stack trace into the given output stream.
Definition at line 262 of file stack_trace.cpp.