My Project
|
#include <handler.h>
Public Member Functions | |
double | total_cost () const |
Returns sum of time-consuming costs, i.e., not counting memory cost. | |
double | get_io_cost () const |
double | get_cpu_cost () const |
double | get_import_cost () const |
double | get_mem_cost () const |
bool | is_zero () const |
void | reset () |
Reset all costs to zero. | |
void | multiply (double m) |
Multiply io, cpu and import costs by parameter. | |
Cost_estimate & | operator+= (const Cost_estimate &other) |
Cost_estimate | operator+ (const Cost_estimate &other) |
void | add_io (double add_io_cost) |
Add to IO cost. | |
void | add_cpu (double add_cpu_cost) |
Add to CPU cost. | |
void | add_import (double add_import_cost) |
Add to import cost. | |
void | add_mem (double add_mem_cost) |
Add to memory cost. | |
Static Public Member Functions | |
static double | IO_BLOCK_READ_COST () |
The cost of one I/O operation. |
Used to store optimizer cost estimates.
The class consists of PODs only: default operator=, copy constructor and destructor are used.
bool Cost_estimate::is_zero | ( | ) | const [inline] |
Whether or not all costs in the object are zero