MySQL 8.0.33
Source Code Documentation
entity_object_table_impl.h
Go to the documentation of this file.
1/* Copyright (c) 2014, 2023, Oracle and/or its affiliates.
2
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License, version 2.0,
5 as published by the Free Software Foundation.
6
7 This program is also distributed with certain software (including
8 but not limited to OpenSSL) that is licensed under separate terms,
9 as designated in a particular file or component or in included license
10 documentation. The authors of MySQL hereby grant you an additional
11 permission to link the program and your derivative works with the
12 separately licensed software that they have included with MySQL.
13
14 This program is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU General Public License, version 2.0, for more details.
18
19 You should have received a copy of the GNU General Public License
20 along with this program; if not, write to the Free Software
21 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
22
23#ifndef DD__ENTITY_OBJECT_TABLE_IMPL_INCLUDED
24#define DD__ENTITY_OBJECT_TABLE_IMPL_INCLUDED
25
26#include <sys/types.h>
27
28#include "my_compiler.h"
29#include "sql/dd/impl/types/object_table_impl.h" // Object_table_impl
30#include "sql/dd/types/entity_object_table.h" // dd::Entity_object_table
31
32class THD;
33
34namespace dd {
35
36///////////////////////////////////////////////////////////////////////////
37
38class Entity_object;
39class Object_table_definition;
40class Open_dictionary_tables_ctx;
41class Properties;
42class Raw_record;
43
45 public Entity_object_table {
46 public:
47 ~Entity_object_table_impl() override = default;
48
50 const Raw_record &record,
51 Entity_object **o) const override;
52
53 // Fix "inherits ... via dominance" warnings
54
55 const String_type &name() const override { return Object_table_impl::name(); }
56
59 }
60
63 }
64
65 void set_abandoned(uint last_dd_version) const override {
66 return Object_table_impl::set_abandoned(last_dd_version);
67 }
68
69 bool is_abandoned() const override {
71 }
72
75 }
76
78 const Properties &table_def_properties) const override {
79 return Object_table_impl::set_actual_table_definition(table_def_properties);
80 }
81
82 int field_number(int target_field_number,
83 const String_type &field_label) const override {
84 return Object_table_impl::field_number(target_field_number, field_label);
85 }
86
87 int field_number(const String_type &field_label) const override {
88 return Object_table_impl::field_number(field_label);
89 }
90
91 bool populate(THD *thd) const override {
93 }
94
95 bool is_hidden() const override { return Object_table_impl::is_hidden(); }
96
97 void set_hidden(bool hidden) override {
98 return Object_table_impl::set_hidden(hidden);
99 }
100};
101
102///////////////////////////////////////////////////////////////////////////
103
104} // namespace dd
105
106#endif // DD__ENTITY_OBJECT_TABLE_IMPL_INCLUDED
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:33
Definition: entity_object_table_impl.h:45
Object_table_definition_impl * target_table_definition() override
Get the target definition for the dictionary table.
Definition: entity_object_table_impl.h:57
bool restore_object_from_record(Open_dictionary_tables_ctx *otx, const Raw_record &record, Entity_object **o) const override
Prepare a DD object by given raw record.
Definition: entity_object_table_impl.cc:50
~Entity_object_table_impl() override=default
const Object_table_definition_impl * target_table_definition() const override
Definition: entity_object_table_impl.h:61
bool is_abandoned() const override
Check if the dictionary table is abandoned.
Definition: entity_object_table_impl.h:69
int field_number(const String_type &field_label) const override
Get the field ordinal position in the object table.
Definition: entity_object_table_impl.h:87
const Object_table_definition_impl * actual_table_definition() const override
Get the actual definition for the dictionary table.
Definition: entity_object_table_impl.h:73
bool populate(THD *thd) const override
Execute low level code for populating the table.
Definition: entity_object_table_impl.h:91
bool set_actual_table_definition(const Properties &table_def_properties) const override
Set the actual definition for the dictionary table.
Definition: entity_object_table_impl.h:77
const String_type & name() const override
Get the table name used by the target definition for the dictionary table.
Definition: entity_object_table_impl.h:55
bool is_hidden() const override
Check if the table should be hidden.
Definition: entity_object_table_impl.h:95
int field_number(int target_field_number, const String_type &field_label) const override
Definition: entity_object_table_impl.h:82
void set_hidden(bool hidden) override
Mark the dictionary table as hidden or visible.
Definition: entity_object_table_impl.h:97
void set_abandoned(uint last_dd_version) const override
Mark the target definition for the dictionary table as abandoned.
Definition: entity_object_table_impl.h:65
This class represents DD table like mysql.schemata, mysql.tables, mysql.tablespaces and more.
Definition: entity_object_table.h:48
Base class for dictionary objects which has single column integer primary key.
Definition: entity_object.h:47
Definition: object_table_definition_impl.h:41
Definition: object_table_impl.h:35
Object_table_definition_impl * target_table_definition() override
Get the target definition for the dictionary table.
Definition: object_table_impl.h:93
void set_hidden(bool hidden) override
Mark the dictionary table as hidden or visible.
Definition: object_table_impl.h:123
void set_abandoned(uint last_dd_version) const override
Mark the target definition for the dictionary table as abandoned.
Definition: object_table_impl.h:101
bool populate(THD *) const override
Execute low level code for populating the table.
Definition: object_table_impl.h:119
bool is_abandoned() const override
Check if the dictionary table is abandoned.
Definition: object_table_impl.h:105
const Object_table_definition_impl * actual_table_definition() const override
Get the actual definition for the dictionary table.
Definition: object_table_impl.h:107
bool set_actual_table_definition(const Properties &table_def_properties) const override
Set the actual definition for the dictionary table.
Definition: object_table_impl.cc:54
virtual int field_number(int target_field_number, const String_type &field_label) const
Definition: object_table_impl.cc:60
const String_type & name() const override
Get the table name used by the target definition for the dictionary table.
Definition: object_table_impl.h:89
bool is_hidden() const override
Check if the table should be hidden.
Definition: object_table_impl.h:121
Auxiliary class for opening dictionary tables.
Definition: transaction_impl.h:75
The Properties class defines an interface for storing key=value pairs, where both key and value may b...
Definition: properties.h:73
Definition: raw_record.h:45
Header for compiler-dependent features.
static int record
Definition: mysqltest.cc:187
The version of the current data dictionary table definitions.
Definition: dictionary_client.h:42
Char_string_template< String_type_allocator > String_type
Definition: string_type.h:50
unsigned int uint
Definition: uca9-dump.cc:74