InnoDB Plugin
1.0
Main Page
Data Structures
Files
File List
Globals
include
dict0load.h
Go to the documentation of this file.
1
/*****************************************************************************
2
3
Copyright (c) 1996, 2013, Oracle and/or its affiliates. All Rights Reserved.
4
5
This program is free software; you can redistribute it and/or modify it under
6
the terms of the GNU General Public License as published by the Free Software
7
Foundation; version 2 of the License.
8
9
This program is distributed in the hope that it will be useful, but WITHOUT
10
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
12
13
You should have received a copy of the GNU General Public License along with
14
this program; if not, write to the Free Software Foundation, Inc.,
15
51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA
16
17
*****************************************************************************/
18
19
/**************************************************/
27
#ifndef dict0load_h
28
#define dict0load_h
29
30
#include "
univ.i
"
31
#include "
dict0types.h
"
32
#include "
trx0types.h
"
33
#include "
ut0byte.h
"
34
#include "
mem0mem.h
"
35
#include "
btr0types.h
"
36
38
enum
dict_system_id_t
{
39
SYS_TABLES = 0,
40
SYS_INDEXES,
41
SYS_COLUMNS,
42
SYS_FIELDS,
43
SYS_FOREIGN,
44
SYS_FOREIGN_COLS,
45
SYS_TABLESPACES,
46
SYS_DATAFILES,
47
48
/* This must be last item. Defines the number of system tables. */
49
SYS_NUM_SYSTEM_TABLES
50
};
51
53
enum
dict_table_info_t
{
54
DICT_TABLE_LOAD_FROM_RECORD
= 0,
57
DICT_TABLE_LOAD_FROM_CACHE
= 1
59
};
60
62
enum
dict_check_t
{
65
DICT_CHECK_NONE_LOADED
= 0,
68
DICT_CHECK_SOME_LOADED
,
70
DICT_CHECK_ALL_LOADED
71
};
72
73
/********************************************************************/
81
UNIV_INTERN
82
void
83
dict_check_tablespaces_and_store_max_id
(
84
/*====================================*/
85
dict_check_t
dict_check);
86
/********************************************************************/
90
UNIV_INTERN
91
char
*
92
dict_get_first_table_name_in_db
(
93
/*============================*/
94
const
char
* name);
96
/********************************************************************/
100
UNIV_INTERN
101
const
char
*
102
dict_load_table_low
(
103
/*================*/
104
const
char
* name,
105
const
rec_t* rec,
106
dict_table_t
** table);
107
/********************************************************************/
111
UNIV_INTERN
112
const
char
*
113
dict_load_column_low
(
114
/*=================*/
115
dict_table_t
* table,
119
mem_heap_t
* heap,
121
dict_col_t
* column,
123
table_id_t* table_id,
124
const
char
** col_name,
125
const
rec_t* rec);
126
/********************************************************************/
132
UNIV_INTERN
133
const
char
*
134
dict_load_index_low
(
135
/*================*/
136
byte* table_id,
139
const
char
* table_name,
140
mem_heap_t
* heap,
141
const
rec_t* rec,
142
ibool
allocate,
145
dict_index_t
** index);
146
/********************************************************************/
150
UNIV_INTERN
151
const
char
*
152
dict_load_field_low
(
153
/*================*/
154
byte* index_id,
157
dict_index_t
* index,
161
dict_field_t
* sys_field,
163
ulint* pos,
164
byte* last_index_id,
165
mem_heap_t
* heap,
167
const
rec_t* rec);
168
/********************************************************************/
173
UNIV_INTERN
174
void
175
dict_save_data_dir_path
(
176
/*====================*/
177
dict_table_t
* table,
178
char
* filepath);
179
/*****************************************************************/
182
UNIV_INTERN
183
void
184
dict_get_and_save_data_dir_path
(
185
/*============================*/
186
dict_table_t
* table,
187
bool
dict_mutex_own);
189
/********************************************************************/
197
UNIV_INTERN
198
dict_table_t
*
199
dict_load_table
(
200
/*============*/
201
const
char
* name,
203
ibool
cached,
204
dict_err_ignore_t
ignore_err);
207
/***********************************************************************/
210
UNIV_INTERN
211
dict_table_t
*
212
dict_load_table_on_id
(
213
/*==================*/
214
table_id_t table_id,
215
dict_err_ignore_t
ignore_err);
217
/********************************************************************/
221
UNIV_INTERN
222
void
223
dict_load_sys_table
(
224
/*================*/
225
dict_table_t
* table);
226
/***********************************************************************/
233
UNIV_INTERN
234
dberr_t
235
dict_load_foreigns
(
236
/*===============*/
237
const
char
* table_name,
238
const
char
** col_names,
240
bool
check_recursive,
243
bool
check_charsets,
245
dict_err_ignore_t
ignore_err)
246
__attribute__((nonnull(1), warn_unused_result));
247
/********************************************************************/
250
UNIV_INTERN
251
void
252
dict_print
(
void
);
253
/*============*/
254
255
/********************************************************************/
258
UNIV_INTERN
259
const
rec_t*
260
dict_startscan_system
(
261
/*==================*/
262
btr_pcur_t
* pcur,
264
mtr_t
* mtr,
265
dict_system_id_t
system_id);
266
/********************************************************************/
269
UNIV_INTERN
270
const
rec_t*
271
dict_getnext_system
(
272
/*================*/
273
btr_pcur_t
* pcur,
275
mtr_t
* mtr);
276
/********************************************************************/
281
UNIV_INTERN
282
const
char
*
283
dict_process_sys_tables_rec_and_mtr_commit
(
284
/*=======================================*/
285
mem_heap_t
* heap,
286
const
rec_t* rec,
287
dict_table_t
** table,
288
dict_table_info_t
status,
292
mtr_t
* mtr);
294
/********************************************************************/
299
UNIV_INTERN
300
const
char
*
301
dict_process_sys_indexes_rec
(
302
/*=========================*/
303
mem_heap_t
* heap,
304
const
rec_t* rec,
305
dict_index_t
* index,
307
table_id_t* table_id);
308
/********************************************************************/
312
UNIV_INTERN
313
const
char
*
314
dict_process_sys_columns_rec
(
315
/*=========================*/
316
mem_heap_t
* heap,
317
const
rec_t* rec,
318
dict_col_t
* column,
319
table_id_t* table_id,
320
const
char
** col_name);
321
/********************************************************************/
325
UNIV_INTERN
326
const
char
*
327
dict_process_sys_fields_rec
(
328
/*========================*/
329
mem_heap_t
* heap,
330
const
rec_t* rec,
331
dict_field_t
* sys_field,
333
ulint* pos,
334
index_id_t* index_id,
335
index_id_t last_id);
336
/********************************************************************/
341
UNIV_INTERN
342
const
char
*
343
dict_process_sys_foreign_rec
(
344
/*=========================*/
345
mem_heap_t
* heap,
346
const
rec_t* rec,
347
dict_foreign_t
* foreign);
349
/********************************************************************/
353
UNIV_INTERN
354
const
char
*
355
dict_process_sys_foreign_col_rec
(
356
/*=============================*/
357
mem_heap_t
* heap,
358
const
rec_t* rec,
359
const
char
** name,
360
const
char
** for_col_name,
361
const
char
** ref_col_name,
363
ulint* pos);
364
/********************************************************************/
368
UNIV_INTERN
369
const
char
*
370
dict_process_sys_tablespaces
(
371
/*=========================*/
372
mem_heap_t
* heap,
373
const
rec_t* rec,
374
ulint* space,
375
const
char
** name,
376
ulint* flags);
377
/********************************************************************/
381
UNIV_INTERN
382
const
char
*
383
dict_process_sys_datafiles
(
384
/*=======================*/
385
mem_heap_t
* heap,
386
const
rec_t* rec,
387
ulint* space,
388
const
char
** path);
389
/********************************************************************/
397
UNIV_INTERN
398
char
*
399
dict_get_first_path
(
400
/*================*/
401
ulint space,
402
const
char
* name);
403
/********************************************************************/
406
UNIV_INTERN
407
dberr_t
408
dict_update_filepath
(
409
/*=================*/
410
ulint space_id,
411
const
char
* filepath);
412
/********************************************************************/
415
UNIV_INTERN
416
dberr_t
417
dict_insert_tablespace_and_filepath
(
418
/*================================*/
419
ulint space,
420
const
char
* name,
421
const
char
* filepath,
422
ulint fsp_flags);
424
#ifndef UNIV_NONINL
425
#include "
dict0load.ic
"
426
#endif
427
428
#endif
Generated on Fri Aug 21 2015 19:14:24 for InnoDB Plugin by
1.8.1.2