![]() |
mutable
A Database System for Research and Fast Prototyping
|
#include <PlanTable.hpp>
Public Types | |
| using | size_type = std::size_t |
| using | Subproblem = QueryGraph::Subproblem |
| using | cost_type = decltype(PlanTableEntry::cost) |
| using | actual_type = Actual |
Public Member Functions | |
| PlanTableBase (const PlanTableBase &)=delete | |
| PlanTableBase (PlanTableBase &&other) | |
| PlanTableBase & | operator= (PlanTableBase other) |
| bool | operator== (const PlanTableBase &other) const |
| Returns true if two tables contain the exact same entries. | |
| bool | operator!= (const PlanTableBase &other) const |
| Returns true if two tables differ in at least one entry. | |
| size_type | num_sources () const |
| Returns the number of data sources. | |
| PlanTableEntry & | at (Subproblem s) |
Returns a reference to the entry of s. | |
| const PlanTableEntry & | at (Subproblem s) const |
Returns a reference to the entry of s. | |
| PlanTableEntry & | operator[] (Subproblem s) |
Returns a reference to the entry of s. | |
| const PlanTableEntry & | operator[] (Subproblem s) const |
Returns a reference to the entry of s. | |
| PlanTableEntry & | get_final () |
| Returns the entry for the final plan, i.e. | |
| const PlanTableEntry & | get_final () const |
| Returns the entry for the final plan, i.e. | |
| cost_type | c (Subproblem s) const |
Returns the cost of the best plan to compute s. | |
| bool | has_plan (Subproblem s) const |
Returns true iff the plan table has a plan for s. | |
| void | update (const QueryGraph &G, const CardinalityEstimator &CE, const CostFunction &CF, Subproblem left, Subproblem right, const cnf::CNF &condition) |
Update the entry for left joined with right (left|right) by considering plan left join right. | |
| void | reset_costs () |
| Resets the costs for all entries in the table. | |
| void | dump (std::ostream &out) const |
| void | dump () const |
| actual_type & | actual () |
| const actual_type & | actual () const |
Protected Member Functions | |
| PlanTableBase ()=default | |
Private Attributes | |
| friend | CRTPBaseType< actual_type, TParams... > |
Friends | |
| void | swap (PlanTableBase &first, PlanTableBase &second) |
| std::ostream &M_EXPORT | operator<< (std::ostream &out, const PlanTableBase &PT) |
| std::string | to_string (const PlanTableBase &PT) |
Definition at line 70 of file PlanTable.hpp.
|
inherited |
| using m::PlanTableBase< Actual >::cost_type = decltype(PlanTableEntry::cost) |
Definition at line 75 of file PlanTable.hpp.
| using m::PlanTableBase< Actual >::size_type = std::size_t |
Definition at line 73 of file PlanTable.hpp.
| using m::PlanTableBase< Actual >::Subproblem = QueryGraph::Subproblem |
Definition at line 74 of file PlanTable.hpp.
|
protecteddefault |
|
delete |
|
inline |
Definition at line 84 of file PlanTable.hpp.
References m::swap().
|
inlineinherited |
|
inlineinherited |
|
inline |
Returns a reference to the entry of s.
Definition at line 97 of file PlanTable.hpp.
|
inline |
Returns a reference to the entry of s.
Definition at line 99 of file PlanTable.hpp.
|
inline |
Returns the cost of the best plan to compute s.
Definition at line 112 of file PlanTable.hpp.
|
inline |
Definition at line 172 of file PlanTable.hpp.
|
inline |
Definition at line 171 of file PlanTable.hpp.
|
inline |
Returns the entry for the final plan, i.e.
the plan that joins all relations.
Definition at line 107 of file PlanTable.hpp.
References m::SmallBitset::All().
|
inline |
Returns the entry for the final plan, i.e.
the plan that joins all relations.
Definition at line 109 of file PlanTable.hpp.
References m::SmallBitset::All().
|
inline |
Returns true iff the plan table has a plan for s.
Definition at line 115 of file PlanTable.hpp.
|
inline |
Returns the number of data sources.
Definition at line 94 of file PlanTable.hpp.
|
inline |
Returns true if two tables differ in at least one entry.
Definition at line 91 of file PlanTable.hpp.
|
inline |
Definition at line 86 of file PlanTable.hpp.
References m::swap().
|
inline |
Returns true if two tables contain the exact same entries.
Definition at line 89 of file PlanTable.hpp.
References m::crtp< ConcreteType, CRTPBaseType, TParams >::actual().
|
inline |
Returns a reference to the entry of s.
Definition at line 102 of file PlanTable.hpp.
|
inline |
Returns a reference to the entry of s.
Definition at line 104 of file PlanTable.hpp.
|
inline |
Resets the costs for all entries in the table.
Definition at line 159 of file PlanTable.hpp.
|
inline |
Update the entry for left joined with right (left|right) by considering plan left join right.
The entry's plan and cost is changed only if the plan's cost is less than the cost of the currently best plan.
Definition at line 119 of file PlanTable.hpp.
References m::CostFunction::calculate_join_cost(), m::SmallBitset::empty(), m::CardinalityEstimator::estimate_join(), M_insist, and m::swap().
|
friend |
Definition at line 401 of file PlanTable.hpp.
|
friend |
Definition at line 394 of file PlanTable.hpp.
|
friend |
Definition at line 165 of file PlanTable.hpp.
|
privateinherited |