libdballe
9.11
|
One operation being traced. More...
#include <trace.h>
Public Member Functions | |
Step (const std::string &name) | |
Step (const std::string &name, const std::string &detail) | |
void | done () |
unsigned | elapsed_usec () const |
void | to_json (core::JSONWriter &writer) const |
void | clear () |
Aggregate | aggregate (const std::string &name) |
Step * | first_child (const std::string &name) |
Step * | last_child (const std::string &name) |
void | add_row (unsigned amount=1) |
template<typename T > | |
T * | add_child (T *step) |
Step * | trace_select (const std::string &query, unsigned rows=0) |
Step * | trace_insert (const std::string &query, unsigned rows=0) |
Step * | trace_update (const std::string &query, unsigned rows=0) |
Step * | trace_delete (const std::string &query, unsigned rows=0) |
Protected Member Functions | |
template<typename T > | |
void | add_sibling (T *step) |
Step * | first_sibling (const std::string &name) |
Step * | last_sibling (const std::string &name, Step *last=nullptr) |
void | _aggregate (const std::string &name, Aggregate &agg) |
Protected Attributes | |
Step * | parent = nullptr |
Parent operation in the operation stack. | |
Step * | child = nullptr |
First child operation in the operation stack. | |
Step * | sibling = nullptr |
Next sibling operation in the operation stack. | |
std::string | name |
Operation name. | |
std::string | detail |
Optional details about the operation. | |
unsigned | rows = 0 |
Number of database rows affected. | |
clock_t | start = 0 |
Timing start. | |
clock_t | end = 0 |
Timing end. | |
One operation being traced.