My Project
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Public Attributes | Protected Attributes
opt_explain_json_namespace::context Class Reference
Inheritance diagram for opt_explain_json_namespace::context:
Explain_context Sql_alloc opt_explain_json_namespace::joinable_ctx opt_explain_json_namespace::subquery_ctx opt_explain_json_namespace::table_base_ctx opt_explain_json_namespace::unit_ctx opt_explain_json_namespace::duplication_weedout_ctx opt_explain_json_namespace::join_tab_ctx opt_explain_json_namespace::materialize_ctx opt_explain_json_namespace::message_ctx opt_explain_json_namespace::simple_sort_ctx opt_explain_json_namespace::materialize_ctx opt_explain_json_namespace::table_with_where_and_derived opt_explain_json_namespace::union_result_ctx opt_explain_json_namespace::join_ctx opt_explain_json_namespace::union_ctx opt_explain_json_namespace::union_result_ctx

List of all members.

Public Member Functions

 context (Explain_context_enum type_arg, const char *name_arg, context *parent_arg)
virtual bool format (Opt_trace_context *json)
bool is_query_block () const
virtual size_t id (bool hide=false)=0
virtual bool cacheable ()
virtual bool dependent ()
virtual class qep_rowentry ()
virtual void set_child (context *child)
virtual void set_union_result (union_result_ctx *ctx)
 associate CTX_UNION_RESULT node with CTX_UNION node
virtual bool add_subquery (subquery_list_enum subquery_type, subquery_ctx *ctx)
virtual bool format_nested_loop (Opt_trace_context *json)
virtual bool add_join_tab (joinable_ctx *ctx)
virtual void set_sort (sort_ctx *ctx)
virtual bool add_query_spec (context *ctx)
virtual bool find_and_set_derived (context *subquery)
virtual bool add_where_subquery (subquery_ctx *ctx, SELECT_LEX_UNIT *subquery)
virtual bool format_derived (Opt_trace_context *json)
 Helper function to format output for derived subquery if any.
virtual bool format_where (Opt_trace_context *json)
 Helper function to format output for associated WHERE subqueries if any.
virtual bool format_unit (Opt_trace_context *json)
 Helper function to format output for HAVING, ORDER/GROUP BY subqueries.

Public Attributes

contextparent
 link to parent node or NULL

Protected Attributes

const char * name

Detailed Description

Base class for all intermediate tree nodes


Member Function Documentation

virtual bool opt_explain_json_namespace::context::add_join_tab ( joinable_ctx ctx) [inline, virtual]

Add a CTX_JOIN_TAB node to a CTX_JOIN node

Parameters:
ctxCTX_JOIN_TAB node
Return values:
falseOk
trueError

Reimplemented in opt_explain_json_namespace::duplication_weedout_ctx, opt_explain_json_namespace::materialize_ctx, opt_explain_json_namespace::join_ctx, and opt_explain_json_namespace::simple_sort_ctx.

virtual bool opt_explain_json_namespace::context::add_query_spec ( context ctx) [inline, virtual]

Add a query specification node to the CTX_UNION node

Parameters:
ctxquery specification node
Return values:
falseOk
trueError

Reimplemented in opt_explain_json_namespace::union_ctx.

virtual bool opt_explain_json_namespace::context::add_subquery ( subquery_list_enum  subquery_type,
subquery_ctx ctx 
) [inline, virtual]

Append a subquery node to the specified list of the unit node

Parameters:
subquery_typeDescribes the Item tree where the subquery exists
ctxSubquery node
Return values:
falseOk
trueError

Reimplemented in opt_explain_json_namespace::duplication_weedout_ctx, opt_explain_json_namespace::materialize_ctx, opt_explain_json_namespace::sort_with_subqueries_ctx, opt_explain_json_namespace::join_ctx, opt_explain_json_namespace::simple_sort_with_subqueries_ctx, opt_explain_json_namespace::union_result_ctx, and opt_explain_json_namespace::unit_ctx.

virtual bool opt_explain_json_namespace::context::add_where_subquery ( subquery_ctx ctx,
SELECT_LEX_UNIT *  subquery 
) [inline, virtual]

Associate WHERE subqueries of given context and unit with this object

Parameters:
ctxContext of WHERE subquery
subqueryFor CTX_JOIN_TAB: match given unit with a previously collected by the register_where_subquery function.

Reimplemented in opt_explain_json_namespace::duplication_weedout_ctx, opt_explain_json_namespace::materialize_ctx, opt_explain_json_namespace::join_ctx, opt_explain_json_namespace::simple_sort_ctx, opt_explain_json_namespace::join_tab_ctx, and opt_explain_json_namespace::message_ctx.

virtual bool opt_explain_json_namespace::context::find_and_set_derived ( context subquery) [inline, virtual]

Try to associate a derived subquery node with this or underlying node

Parameters:
subqueryDerived subquery node
Return values:
trueSuccess
falseCan't associate: this node or its child nodes are not derived from the subquery

Reimplemented in opt_explain_json_namespace::duplication_weedout_ctx, opt_explain_json_namespace::materialize_ctx, opt_explain_json_namespace::join_ctx, opt_explain_json_namespace::simple_sort_ctx, opt_explain_json_namespace::join_tab_ctx, and opt_explain_json_namespace::message_ctx.

virtual bool opt_explain_json_namespace::context::format ( Opt_trace_context json) [inline, virtual]

Pass the node with its child nodes to a JSON formatter

Parameters:
jsonFormatter
Return values:
falseOk
trueError
Note:
The join_ctx class overloads this function.

Reimplemented in opt_explain_json_namespace::union_result_ctx, and opt_explain_json_namespace::subquery_ctx.

Format nested loop join subtree (if any) to JSON formatter

Parameters:
jsonFormatter
Return values:
falseOk
trueError

Reimplemented in opt_explain_json_namespace::duplication_weedout_ctx, opt_explain_json_namespace::materialize_ctx, and opt_explain_json_namespace::join_ctx.

virtual size_t opt_explain_json_namespace::context::id ( bool  hide = false) [pure virtual]
virtual void opt_explain_json_namespace::context::set_child ( context child) [inline, virtual]

Associate a child node with this node

This function is to be overloaded by subquery_ctx.

Reimplemented in opt_explain_json_namespace::subquery_ctx.

virtual void opt_explain_json_namespace::context::set_sort ( sort_ctx ctx) [inline, virtual]

Set nested ORDER BY/GROUP BY/DISTINCT node to ctx

Parameters:
jsonFormatter
Return values:
falseOk
trueError

Reimplemented in opt_explain_json_namespace::duplication_weedout_ctx, opt_explain_json_namespace::materialize_ctx, and opt_explain_json_namespace::join_ctx.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines