MySQL 8.3.0
Source Code Documentation
index_stats.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_TABLES__INDEX_STATS_INCLUDED
24#define DD_TABLES__INDEX_STATS_INCLUDED
25
26#include <new>
27
30#include "sql/dd/string_type.h" // dd::String_type
32
33namespace dd {
34
35class Object_key;
36class Raw_record;
37
38namespace tables {
39
40///////////////////////////////////////////////////////////////////////////
41
42class Index_stats : virtual public Entity_object_table_impl {
43 public:
45
46 static const Index_stats &instance();
47
55 NUMBER_OF_FIELDS // Always keep this entry at the end of the enum
56 };
57
59
61
62 Index_stat *create_entity_object(const Raw_record &) const override {
63 return new (std::nothrow) Index_stat_impl();
64 }
65
67 const String_type &schema_name, const String_type &table_name,
68 const String_type &index_name, const String_type &column_name);
69
71 const String_type &schema_name, const String_type &table_name);
72};
73
74} // namespace tables
75} // namespace dd
76
77#endif // DD_TABLES__INDEX_STATS_INCLUDED
Definition: object_keys.h:322
Definition: entity_object_table_impl.h:45
Definition: index_stat_impl.h:51
Definition: index_stat.h:42
Definition: object_key.h:37
Definition: raw_record.h:45
Definition: index_stats.h:42
static Index_stat::Name_key * create_object_key(const String_type &schema_name, const String_type &table_name, const String_type &index_name, const String_type &column_name)
Definition: index_stats.cc:65
Index_stats()
Definition: index_stats.cc:34
enum_fields
Definition: index_stats.h:48
@ FIELD_TABLE_NAME
Definition: index_stats.h:50
@ FIELD_INDEX_NAME
Definition: index_stats.h:51
@ FIELD_SCHEMA_NAME
Definition: index_stats.h:49
@ FIELD_CACHED_TIME
Definition: index_stats.h:54
@ FIELD_CARDINALITY
Definition: index_stats.h:53
@ FIELD_COLUMN_NAME
Definition: index_stats.h:52
@ NUMBER_OF_FIELDS
Definition: index_stats.h:55
enum_indexes
Definition: index_stats.h:58
@ INDEX_UK_SCHEMA_TABLE_INDEX_COLUMN
Definition: index_stats.h:58
static const Index_stats & instance()
Definition: index_stats.cc:58
Index_stat * create_entity_object(const Raw_record &) const override
Definition: index_stats.h:62
static Object_key * create_range_key_by_table_name(const String_type &schema_name, const String_type &table_name)
Definition: index_stats.cc:76
enum_foreign_keys
Definition: index_stats.h:60
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
const char * table_name
Definition: rules_table_service.cc:55