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

#include <sql_signal.h>

Inheritance diagram for Sql_cmd_common_signal:
Collaboration diagram for Sql_cmd_common_signal:

Protected Member Functions

 Sql_cmd_common_signal (const sp_condition_value *cond, const Set_signal_information &set)
void eval_defaults (THD *thd, Sql_condition *cond)
int eval_signal_informations (THD *thd, Sql_condition *cond)
bool raise_condition (THD *thd, Sql_condition *cond)

Static Protected Member Functions

static void assign_defaults (Sql_condition *cond, bool set_level_code, Sql_condition::enum_warning_level level, int sqlcode)

Protected Attributes

const sp_condition_valuem_cond
Set_signal_information m_set_signal_information

Additional Inherited Members

- Public Member Functions inherited from Sql_cmd
virtual enum_sql_command sql_command_code () const =0
 Return the command code for this statement.
virtual bool execute (THD *thd)=0
- 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

Sql_cmd_common_signal represents the common properties of the SIGNAL and RESIGNAL statements.

Definition at line 23 of file sql_signal.h.

Constructor & Destructor Documentation

Sql_cmd_common_signal::Sql_cmd_common_signal ( const sp_condition_value cond,
const Set_signal_information &  set 
)
inlineprotected

Constructor.

Parameters
condthe condition signaled if any, or NULL.
setcollection of signal condition item assignments.

Definition at line 31 of file sql_signal.h.

Member Function Documentation

void Sql_cmd_common_signal::assign_defaults ( Sql_condition cond,
bool  set_level_code,
Sql_condition::enum_warning_level  level,
int  sqlcode 
)
staticprotected

Assign the condition items 'MYSQL_ERRNO', 'level' and 'MESSAGE_TEXT' default values of a condition.

Parameters
condthe condition to update.
set_level_codetrue if 'level' and 'MYSQL_ERRNO' needs to be overwritten
levelthe level to assign
sqlcodethe sql code to assign

Definition at line 90 of file sql_signal.cc.

Here is the call graph for this function:

Here is the caller graph for this function:

void Sql_cmd_common_signal::eval_defaults ( THD *  thd,
Sql_condition cond 
)
protected

Evaluate the condition items 'SQLSTATE', 'MYSQL_ERRNO', 'level' and 'MESSAGE_TEXT' default values for this statement.

Parameters
thdthe current thread.
condthe condition to update.

Definition at line 105 of file sql_signal.cc.

Here is the call graph for this function:

Here is the caller graph for this function:

int Sql_cmd_common_signal::eval_signal_informations ( THD *  thd,
Sql_condition cond 
)
protected

Evaluate each signal condition items for this statement.

Parameters
thdthe current thread.
condthe condition to update.
Returns
0 on success.

Definition at line 259 of file sql_signal.cc.

Here is the caller graph for this function:

bool Sql_cmd_common_signal::raise_condition ( THD *  thd,
Sql_condition cond 
)
protected

Raise a SQL condition.

Parameters
thdthe current thread.
condthe condition to raise.
Returns
false on success.

Definition at line 416 of file sql_signal.cc.

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

const sp_condition_value* Sql_cmd_common_signal::m_cond
protected

The condition to signal or resignal. This member is optional and can be NULL (RESIGNAL).

Definition at line 82 of file sql_signal.h.

Set_signal_information Sql_cmd_common_signal::m_set_signal_information
protected

Collection of 'SET item = value' assignments in the SIGNAL/RESIGNAL statement.

Definition at line 88 of file sql_signal.h.


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