24#ifndef DD__OBJECT_TABLE_DEFINITION_IMPL_INCLUDED
25#define DD__OBJECT_TABLE_DEFINITION_IMPL_INCLUDED
69 return "foreign_keys";
111 assert(element_numbers !=
nullptr && element_definitions !=
nullptr &&
112 element_numbers->find(element_name) == element_numbers->end() &&
114 element_definitions->end());
122 assert(element_numbers.find(element_name) != element_numbers.end());
123 return element_numbers.find(element_name)->second;
198 const char *tmp_name = src.c_str();
233 add_element(foreign_key_number, foreign_key_name, foreign_key_definition,
261 const std::vector<String_type> &
get_dml()
const override {
Definition: object_table_definition_impl.h:42
const String_type & get_table_name() const
Definition: object_table_definition_impl.h:210
std::map< String_type, int > Element_numbers
Definition: object_table_definition_impl.h:44
static bool is_dd_tablespace_encrypted()
Definition: object_table_definition_impl.h:150
void store_into_properties(Properties *table_def_properties) const override
Store the elements of the object table definition into a property object.
Definition: object_table_definition_impl.cc:141
virtual int index_number(const String_type &index_name) const
Definition: object_table_definition_impl.h:251
Element_definitions m_field_definitions
Definition: object_table_definition_impl.h:94
virtual bool restore_from_string(const String_type &ddl_statement)
Definition: object_table_definition_impl.h:267
Label
Definition: object_table_definition_impl.h:48
String_type get_ddl() const override
Get the SQL DDL statement for creating the dictionary table.
Definition: object_table_definition_impl.cc:100
void add_field(int field_number, const String_type &field_name, const String_type field_definition) override
Add a field to the object table definition.
Definition: object_table_definition_impl.h:216
static const char * key(Label label)
Definition: object_table_definition_impl.h:60
std::map< int, String_type > Element_definitions
Definition: object_table_definition_impl.h:45
Element_definitions m_foreign_key_definitions
Definition: object_table_definition_impl.h:100
int element_number(const String_type &element_name, const Element_numbers &element_numbers) const
Definition: object_table_definition_impl.h:120
Element_numbers m_option_numbers
Definition: object_table_definition_impl.h:102
bool set_element_properties(const String_type &prop_str, Element_numbers *element_numbers, Element_definitions *element_defs)
Definition: object_table_definition_impl.cc:59
Element_definitions m_option_definitions
Definition: object_table_definition_impl.h:103
virtual void add_option(int option_number, const String_type &option_name, const String_type &option_definition)
Definition: object_table_definition_impl.h:237
void set_table_name(const String_type &name) override
Set the name of the table.
Definition: object_table_definition_impl.h:212
virtual void add_populate_statement(const String_type &statement)
Definition: object_table_definition_impl.h:243
void set_schema_name(const String_type &name)
Definition: object_table_definition_impl.h:214
static const CHARSET_INFO * fs_name_collation()
Get the collation which is used for names related to the file system (e.g.
Definition: object_table_definition_impl.h:161
virtual int option_number(const String_type &option_name) const
Definition: object_table_definition_impl.h:255
void get_element_properties(dd::Properties *properties, const Element_numbers &element_numbers, const Element_definitions &element_defs) const
Definition: object_table_definition_impl.cc:38
void add_index(int index_number, const String_type &index_name, const String_type &index_definition) override
Add an index to the object table definition.
Definition: object_table_definition_impl.h:224
void add_sql_mode_field(int field_number, const String_type &field_name)
Definition: object_table_definition_impl.cc:88
String_type m_table_name
Definition: object_table_definition_impl.h:89
virtual void add_foreign_key(int foreign_key_number, const String_type &foreign_key_name, const String_type &foreign_key_definition)
Definition: object_table_definition_impl.h:230
static const char * fs_name_case(const String_type &src, char *buf)
Convert to lowercase if lower_case_table_names == 2.
Definition: object_table_definition_impl.h:197
Object_table_definition_impl()=default
Object_table_definition_impl(const String_type &schema_name, const String_type &table_name, const String_type &ddl_statement)
Definition: object_table_definition_impl.h:137
const std::vector< String_type > & get_dml() const override
Get the SQL DML statements for populating the table.
Definition: object_table_definition_impl.h:261
void add_element(int element_number, const String_type &element_name, const String_type &element_definition, Element_numbers *element_numbers, Element_definitions *element_definitions)
Definition: object_table_definition_impl.h:107
Element_numbers m_index_numbers
Definition: object_table_definition_impl.h:96
std::vector< String_type > m_dml_statements
Definition: object_table_definition_impl.h:105
~Object_table_definition_impl() override=default
static bool s_dd_tablespace_encrypted
Definition: object_table_definition_impl.h:86
bool restore_from_properties(const Properties &table_def_properties) override
Restore the elements of the object table definition from a property object.
Definition: object_table_definition_impl.cc:168
String_type m_ddl_statement
Definition: object_table_definition_impl.h:91
Element_definitions m_index_definitions
Definition: object_table_definition_impl.h:97
Element_numbers m_field_numbers
Definition: object_table_definition_impl.h:93
Element_numbers m_foreign_key_numbers
Definition: object_table_definition_impl.h:99
static const CHARSET_INFO * name_collation()
Get the collation which is used for the name field in the table.
Definition: object_table_definition_impl.h:179
virtual int field_number(const String_type &field_name) const
Definition: object_table_definition_impl.h:247
static void set_dd_tablespace_encrypted(bool is_encrypted)
Definition: object_table_definition_impl.h:146
String_type m_schema_name
Definition: object_table_definition_impl.h:88
The purpose of this interface is to enable retrieving the SQL statements necessary to create and popu...
Definition: object_table_definition.h:48
The Properties class defines an interface for storing key=value pairs, where both key and value may b...
Definition: properties.h:74
CHARSET_INFO my_charset_utf8mb3_bin
Definition: ctype-utf8.cc:5883
CHARSET_INFO my_charset_utf8mb3_tolower_ci
Definition: ctype-utf8.cc:5813
#define my_casedn_str(s, a)
Definition: m_ctype.h:770
static char * my_stpcpy(char *dst, const char *src)
Copy a string from src to dst until (and including) terminating null byte.
Definition: m_string.h:165
uint lower_case_table_names
Definition: mysqld.cc:1327
Definition: buf0block_hint.cc:30
The version of the current data dictionary table definitions.
Definition: dictionary_client.h:43
bool is_encrypted(const String_type &type)
Definition: dd_table.h:421
Char_string_template< String_type_allocator > String_type
Definition: string_type.h:51
const char * table_name
Definition: rules_table_service.cc:56
case opt name
Definition: sslopt-case.h:33
Definition: m_ctype.h:385
Definition: mysqlslap.cc:217