MySQL
9.6.0
Source Code Documentation
sets.h
Go to the documentation of this file.
1
// Copyright (c) 2024, 2025, 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 designed to work 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 either included with
13
// the program or referenced in the documentation.
14
//
15
// This program is distributed in the hope that it will be useful,
16
// but WITHOUT ANY WARRANTY; without even the implied warranty of
17
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18
// GNU General Public License, version 2.0, for more details.
19
//
20
// You should have received a copy of the GNU General Public License
21
// along with this program; if not, write to the Free Software
22
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
23
24
#ifndef MYSQL_SETS_SETS_H
25
#define MYSQL_SETS_SETS_H
26
27
/// @file
28
/// Experimental API header
29
///
30
/// This is a high-level header, intended for users to include in order to
31
/// import all functionality in the sets library.
32
33
// Files are listed in order from more primitive to more complex. A file is not
34
// supposed to include a file appearing after it in the list.
35
36
// ==== Set categories ====
37
38
// Set categories are type tags used by the member type Set_category_t of any
39
// set class. Set categories are used to dispatch to a particular implementation
40
// of an algorithm. For example, each category has its own implementation of
41
// `is_subset`, and the type tags of the operands are used to determine which
42
// implementation to use. Currently we have the categories Boundary sets,
43
// Interval sets, and Nested sets. Users may define their own set categories.
44
45
// Type tags to identify categories of sets.
46
#include "
mysql/sets/set_categories.h
"
47
48
// Set category definitions for boundary sets.
49
#include "
mysql/sets/boundary_set_category.h
"
50
51
// Set category definitions for interval sets.
52
#include "
mysql/sets/interval_set_category.h
"
53
54
// Set category definitions for interval sets.
55
#include "
mysql/sets/nested_set_category.h
"
56
57
// ==== Set traits ====
58
59
// Set traits are classes that bundle compile-time parameters of a set. Each set
60
// has a member type Set_traits_t bound to a set traits class. Algorithms use
61
// set traits to determine how to perform basic operations. For example, for an
62
// interval set, the set traits determine the type of elements, the predicate to
63
// compare two elements, and the minimum and maximum value. Users may define
64
// their own set traits.
65
66
// Traits to characterize the data stored in a set.
67
#include "
mysql/sets/set_traits.h
"
68
69
// Concepts that depend on both category and traits.
70
#include "
mysql/sets/set_categories_and_traits.h
"
71
72
// Other generic metaprogramming functionality.
73
#include "
mysql/sets/meta.h
"
74
75
// CRTP base for ordered Set traits.
76
#include "
mysql/sets/ordered_set_traits_interface.h
"
77
78
// Int_set_traits, the Set traits class template for sets holding integers.
79
#include "
mysql/sets/int_set_traits.h
"
80
81
// Nested_set_traits, the class template for Set traits for Nested sets.
82
#include "
mysql/sets/nested_set_traits.h
"
83
84
// ==== Metaprogramming (concepts) for each specific set type ====
85
86
// Concepts to test set traits for boundary sets.
87
#include "
mysql/sets/boundary_set_meta.h
"
88
89
// Concepts to test set traits for interval sets.
90
#include "
mysql/sets/interval_set_meta.h
"
91
92
// Concepts to test set traits for nested sets.
93
#include "
mysql/sets/nested_set_meta.h
"
94
95
// ==== Upper and lower bounds ====
96
97
// CRTP base for classes with upper_bound/lower_bound member functions.
98
#include "
mysql/sets/upper_lower_bound_interface.h
"
99
100
// ==== Interfaces for Boundary sets and Interval sets ====
101
102
// CRTP base for boundary sets
103
#include "
mysql/sets/boundary_set_interface.h
"
104
105
// Classes representing single intervals.
106
#include "
mysql/sets/interval.h
"
107
108
// CRTP base for interval sets.
109
#include "
mysql/sets/interval_set_interface.h
"
110
111
// ==== Free function predicates ====
112
113
// Free function Boolean set predicates common to most set categories, e.g.,
114
// is_equal.
115
#include "
mysql/sets/common_predicates.h
"
116
117
// Free function Boolean set predicates such as is_subset, for intervals.
118
#include "
mysql/sets/interval_predicates.h
"
119
120
// Free function Boolean set predicates such as is_subset, for boundary sets.
121
#include "
mysql/sets/boundary_set_predicates.h
"
122
123
// Free function Boolean set predicates such as is_subset, for interval sets.
124
#include "
mysql/sets/interval_set_predicates.h
"
125
126
// Free function Boolean set predicates such as is_subset.
127
#include "
mysql/sets/nested_set_predicates.h
"
128
129
// ==== Constant views, e.g., Empty_set_view ====
130
131
// Helpers used when defining views below.
132
#include "
mysql/sets/optional_view_source_set.h
"
133
134
// Primary templates and factory functions.
135
#include "
mysql/sets/base_const_views.h
"
136
137
// Views over empty and full Boundary sets, and views over arbitrary
138
// compile-time-defined boundaries.
139
#include "
mysql/sets/boundary_set_const_views.h
"
140
141
// View over empty and full Interval set.
142
#include "
mysql/sets/interval_const_views.h
"
143
144
// View over empty nested sets.
145
#include "
mysql/sets/nested_set_const_views.h
"
146
147
// ==== Views over binary operations, e.g. Union_view ====
148
149
// enum Binary_operation { op_union, op_intersection, op_subtraction }
150
#include "
libs/mysql/sets/binary_operation.h
"
151
152
// Primary templates and factory functions.
153
#include "
mysql/sets/base_binary_operation_views.h
"
154
155
// ---- Boundary set binary operation binary operations ----
156
157
// Common class template for iterators over binary operations on boundary sets.
158
#include "
mysql/sets/boundary_set_binary_operation_iterator.h
"
159
160
// Base class for views over binary operations on boundary sets.
161
#include "
mysql/sets/boundary_set_binary_operation_view_base.h
"
162
163
// View over union of boundary sets.
164
#include "
mysql/sets/boundary_set_union_view.h
"
165
166
// View over intersection of boundary sets.
167
#include "
mysql/sets/boundary_set_intersection_view.h
"
168
169
// View over subtraction of boundary sets.
170
#include "
mysql/sets/boundary_set_subtraction_view.h
"
171
172
// ---- Interval set binary operations ----
173
174
// Base class for views of binary operations on interval sets.
175
#include "
mysql/sets/interval_set_binary_operation_view_base.h
"
176
177
// View over union of interval sets.
178
#include "
mysql/sets/interval_set_union_view.h
"
179
180
// View over intersection of interval sets.
181
#include "
mysql/sets/interval_set_intersection_view.h
"
182
183
// View over subtraction of interval sets.
184
#include "
mysql/sets/interval_set_subtraction_view.h
"
185
186
// ---- Nested set binary operations ----
187
188
// Common base class for iterators over binary operations on nested sets.
189
#include "
mysql/sets/nested_set_binary_operation_iterator_base.h
"
190
191
// Iterators over union of nested sets.
192
#include "
mysql/sets/nested_set_union_iterator.h
"
193
194
// Iterators over intersection of nested sets.
195
#include "
mysql/sets/nested_set_intersection_iterator.h
"
196
197
// Iterators over subtraction of nested sets.
198
#include "
mysql/sets/nested_set_subtraction_iterator.h
"
199
200
// Base class for views over binary operations on nested sets.
201
#include "
mysql/sets/nested_set_binary_operation_view_interface.h
"
202
203
// View over union of nested sets.
204
#include "
mysql/sets/nested_set_union_view.h
"
205
206
// View over intersection of nested sets.
207
#include "
mysql/sets/nested_set_intersection_view.h
"
208
209
// View over subtraction of nested sets.
210
#include "
mysql/sets/nested_set_subtraction_view.h
"
211
212
// ==== Views over complements: Complement_view ====
213
214
// Primary template and factory function.
215
#include "
mysql/sets/base_complement_view.h
"
216
217
// Complement view over boundary sets.
218
#include "
mysql/sets/boundary_set_complement_view.h
"
219
220
// Complement view over interval sets.
221
#include "
mysql/sets/interval_set_complement_view.h
"
222
223
// ==== Volume ====
224
225
// Generic implementation of volume_difference.
226
#include "
mysql/sets/base_volume.h
"
227
228
// Compute the volume of a single interval.
229
#include "
mysql/sets/interval_volume.h
"
230
231
// Compute the volume of an interval set.
232
#include "
mysql/sets/interval_set_volume.h
"
233
234
// Compute the volume of a boundary set.
235
#include "
mysql/sets/boundary_set_volume.h
"
236
237
// Compute the volume of a nested set.
238
#include "
mysql/sets/nested_set_volume.h
"
239
240
// ==== Boundary containers and storage ====
241
242
// Base class for containers which are wrappers around other containers.
243
#include "
libs/mysql/sets/basic_set_container_wrapper.h
"
244
245
// Helper function used when defining inplace set operations.
246
#include "
libs/mysql/sets/set_container_helpers.h
"
247
248
// Associative boundary storage, based on std::map. May throw bad_alloc.
249
#include "
mysql/sets/throwing/map_boundary_storage.h
"
250
251
// Contiguous boundary storage, based on std::vector. May throw bad_alloc.
252
#include "
mysql/sets/throwing/vector_boundary_storage.h
"
253
254
// Boundary container, based on one of the storage classes. May throw bad_alloc.
255
#include "
mysql/sets/throwing/boundary_container.h
"
256
257
// Adaptor for boundary containers, that "converts" bad_alloc to a return value.
258
#include "
mysql/sets/nonthrowing_boundary_container_adaptor.h
"
259
260
// ==== Interval containers ====
261
262
// Adaptor that provides an interval container from a boundary container.
263
#include "
mysql/sets/interval_container.h
"
264
265
// ==== Nested containers and storage ====
266
267
// Associative nested set storage, based on std::map.
268
#include "
mysql/sets/map_nested_storage.h
"
269
270
// Nested set container.
271
#include "
mysql/sets/nested_container.h
"
272
273
// ==== Type aliases for containers ====
274
275
// Using-definitions for containers based on map/vector storage.
276
#include "
mysql/sets/aliases.h
"
277
278
// ==== String conversion ====
279
280
// String format definition for boundary sets and interval sets.
281
#include "
mysql/sets/strconv/boundary_set_text_format.h
"
282
283
// String format definition for nested sets.
284
#include "
mysql/sets/strconv/nested_set_text_format.h
"
285
286
// Implementation enabling mysql::strconv::encode for interval/boundary
287
// sets.
288
#include "
mysql/sets/strconv/encode.h
"
289
290
// Implementation enabling mysql::strconv::decode for interval/boundary
291
// sets.
292
#include "
mysql/sets/strconv/decode.h
"
293
294
#endif
// ifndef MYSQL_SETS_SETS_H
aliases.h
Experimental API header.
base_binary_operation_views.h
Experimental API header.
base_complement_view.h
Experimental API header.
base_const_views.h
Experimental API header.
base_volume.h
Experimental API header.
basic_set_container_wrapper.h
Experimental API header.
binary_operation.h
Experimental API header.
boundary_container.h
Experimental API header.
boundary_set_binary_operation_iterator.h
Experimental API header.
boundary_set_binary_operation_view_base.h
Experimental API header.
boundary_set_category.h
Experimental API header.
boundary_set_complement_view.h
Experimental API header.
boundary_set_const_views.h
Experimental API header.
boundary_set_interface.h
Experimental API header.
boundary_set_intersection_view.h
Experimental API header.
boundary_set_meta.h
Experimental API header.
boundary_set_predicates.h
Experimental API header.
boundary_set_subtraction_view.h
Experimental API header.
boundary_set_text_format.h
Experimental API header.
boundary_set_union_view.h
Experimental API header.
boundary_set_volume.h
Experimental API header.
common_predicates.h
Experimental API header.
int_set_traits.h
Experimental API header.
interval.h
Experimental API header.
interval_const_views.h
Experimental API header.
interval_container.h
Experimental API header.
interval_predicates.h
Experimental API header.
interval_set_binary_operation_view_base.h
Experimental API header.
interval_set_category.h
Experimental API header.
interval_set_complement_view.h
Experimental API header.
interval_set_interface.h
Experimental API header.
interval_set_intersection_view.h
Experimental API header.
interval_set_meta.h
Experimental API header.
interval_set_predicates.h
Experimental API header.
interval_set_subtraction_view.h
Experimental API header.
interval_set_union_view.h
Experimental API header.
interval_set_volume.h
Experimental API header.
interval_volume.h
Experimental API header.
meta.h
Experimental API header.
map_boundary_storage.h
Experimental API header.
map_nested_storage.h
Experimental API header.
nested_container.h
Experimental API header.
nested_set_binary_operation_iterator_base.h
Experimental API header.
nested_set_binary_operation_view_interface.h
Experimental API header.
nested_set_category.h
Experimental API header.
nested_set_const_views.h
Experimental API header.
nested_set_intersection_iterator.h
Experimental API header.
nested_set_intersection_view.h
Experimental API header.
nested_set_meta.h
Experimental API header.
nested_set_predicates.h
Experimental API header.
nested_set_subtraction_iterator.h
Experimental API header.
nested_set_subtraction_view.h
Experimental API header.
nested_set_text_format.h
Experimental API header.
nested_set_traits.h
Experimental API header.
nested_set_union_iterator.h
Experimental API header.
nested_set_union_view.h
Experimental API header.
nested_set_volume.h
Experimental API header.
nonthrowing_boundary_container_adaptor.h
Experimental API header.
optional_view_source_set.h
Experimental API header.
ordered_set_traits_interface.h
Experimental API header.
set_categories.h
Experimental API header.
set_categories_and_traits.h
Experimental API header.
set_container_helpers.h
Experimental API header.
set_traits.h
Experimental API header.
decode.h
Experimental API header.
encode.h
Experimental API header.
upper_lower_bound_interface.h
Experimental API header.
vector_boundary_storage.h
Experimental API header.
libs
mysql
sets
sets.h
Generated by
1.9.2