MySQL 5.6.14 Source Code Document
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
QEP_operation Class Reference

#include <sql_executor.h>

Inheritance diagram for QEP_operation:
Collaboration diagram for QEP_operation:

Public Types

enum  enum_op_type { OT_CACHE, OT_TMP_TABLE }

Public Member Functions

 QEP_operation (JOIN_TAB *tab)
virtual enum_op_type type ()=0
virtual int init ()
virtual enum_nested_loop_state put_record ()=0
virtual enum_nested_loop_state end_send ()=0
virtual void free ()

Public Attributes

JOIN_TABjoin_tab

Additional Inherited Members

- Static Public Member Functions inherited from Sql_alloc
static void * operator new (size_t size) throw ()
static void * operator new[] (size_t size) throw ()
static void * operator new[] (size_t size, MEM_ROOT *mem_root) throw ()
static void * operator new (size_t size, MEM_ROOT *mem_root) throw ()
static void operator delete (void *ptr, size_t size)
static void operator delete (void *ptr, MEM_ROOT *mem_root)
static void operator delete[] (void *ptr, MEM_ROOT *mem_root)
static void operator delete[] (void *ptr, size_t size)

Detailed Description

QEP_operation is an interface class for operations in query execution plan.

Currently following operations are implemented: JOIN_CACHE - caches partial join result and joins with attached table QEP_tmp_table - materializes join result in attached table

An operation's life cycle is as follows: .) it is initialized on the init() call .) accumulates records one by one when put_record() is called. .) finalize record sending when end_send() is called. .) free all internal buffers on the free() call.

Each operation is attached to a join_tab, to which exactly depends on the operation type: JOIN_CACHE is attached to the table following the table being cached, QEP_tmp_buffer is attached to a tmp table.

Definition at line 176 of file sql_executor.h.

Member Function Documentation

virtual enum_nested_loop_state QEP_operation::end_send ( )
pure virtual

Finalize records sending.

Implemented in JOIN_CACHE, and QEP_tmp_table.

Here is the caller graph for this function:

virtual void QEP_operation::free ( void  )
inlinevirtual

Internal state cleanup.

Reimplemented in JOIN_CACHE.

Definition at line 209 of file sql_executor.h.

Here is the caller graph for this function:

virtual int QEP_operation::init ( void  )
inlinevirtual

Initialize operation's internal state. Called once per query execution.

Reimplemented in JOIN_CACHE_BKA_UNIQUE, JOIN_CACHE_BKA, JOIN_CACHE_BNL, and JOIN_CACHE.

Definition at line 195 of file sql_executor.h.

virtual enum_nested_loop_state QEP_operation::put_record ( )
pure virtual

Put a new record into the operation's buffer

Returns
return one of enum_nested_loop_state values.

Implemented in JOIN_CACHE, and QEP_tmp_table.

Here is the caller graph for this function:

Member Data Documentation

JOIN_TAB* QEP_operation::join_tab

For JOIN_CACHE : Table to be joined with the partial join records from the cache For JOIN_TMP_BUFFER : join_tab of tmp table

Definition at line 186 of file sql_executor.h.


The documentation for this class was generated from the following file: