CppCMS
|
the class that records the stack trace when it is created, More...
#include <booster/booster/backtrace.h>
Public Member Functions | |
backtrace (size_t frames_no=default_stack_size) | |
size_t | stack_size () const |
void * | return_address (unsigned frame_no) const |
void | trace_line (unsigned frame_no, std::ostream &out) const |
std::string | trace_line (unsigned frame_no) const |
std::string | trace () const |
void | trace (std::ostream &out) const |
Static Public Attributes | |
static size_t const | default_stack_size = 32 |
the class that records the stack trace when it is created,
It is a base class for all exceptions that record stack trace
booster::backtrace::backtrace | ( | size_t | frames_no = default_stack_size | ) | [inline] |
Create stack trace recording at most frames_no stack frames
References trace().
void* booster::backtrace::return_address | ( | unsigned | frame_no | ) | const [inline] |
Get the returned address for the stack frame number frame_no
References stack_size().
size_t booster::backtrace::stack_size | ( | ) | const [inline] |
Get the actual number of recorded stack frames
Referenced by return_address().
std::string booster::backtrace::trace | ( | ) | const [inline] |
Get full stack trace as a string
References booster::stack_trace::get_symbols().
Referenced by backtrace().
void booster::backtrace::trace | ( | std::ostream & | out | ) | const [inline] |
Print full stack trace to a stream out
References booster::stack_trace::write_symbols().
void booster::backtrace::trace_line | ( | unsigned | frame_no, |
std::ostream & | out | ||
) | const [inline] |
Print the stack trace frame for the frame frame_no to the stream out
References booster::stack_trace::write_symbols().
std::string booster::backtrace::trace_line | ( | unsigned | frame_no | ) | const [inline] |
Get a readable stack trace frame for the frame frame_no
References booster::stack_trace::get_symbol().
size_t const booster::backtrace::default_stack_size = 32 [static] |
The default number of recorded frames