Drizzled Public API Documentation

row0row.h
Go to the documentation of this file.
1 /*****************************************************************************
2 
3 Copyright (C) 1996, 2010, Innobase Oy. 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., 51 Franklin
15 St, Fifth Floor, Boston, MA 02110-1301 USA
16 
17 *****************************************************************************/
18 
19 /**************************************************/
26 #pragma once
27 #ifndef row0row_h
28 #define row0row_h
29 
30 #include "univ.i"
31 #include "data0data.h"
32 #include "dict0types.h"
33 #include "trx0types.h"
34 #include "que0types.h"
35 #include "mtr0mtr.h"
36 #include "rem0types.h"
37 #include "read0types.h"
38 #include "row0types.h"
39 #include "btr0types.h"
40 
41 /*********************************************************************/
45 UNIV_INTERN
46 ulint
48 /*==================*/
49  const rec_t* rec,
50  dict_index_t* index,
51  const ulint* offsets);
52 /*********************************************************************/
55 UNIV_INLINE
58 /*===============*/
59  const rec_t* rec,
60  dict_index_t* index,
61  const ulint* offsets);
62 /*********************************************************************/
65 UNIV_INLINE
68 /*=================*/
69  const rec_t* rec,
70  dict_index_t* index,
71  const ulint* offsets);
72 /*****************************************************************/
78 UNIV_INTERN
79 dtuple_t*
81 /*==================*/
82  const dtuple_t* row,
84  row_ext_t* ext,
86  dict_index_t* index,
87  mem_heap_t* heap);
89 /*******************************************************************/
93 UNIV_INTERN
94 dtuple_t*
95 row_build(
96 /*======*/
97  ulint type,
104  const dict_index_t* index,
105  const rec_t* rec,
114  const ulint* offsets,
117  const dict_table_t* col_table,
126  row_ext_t** ext,
129  mem_heap_t* heap);
131 /*******************************************************************/
135 UNIV_INTERN
136 dtuple_t*
138 /*=======================*/
139  const rec_t* rec,
140  const dict_index_t* index,
141  const ulint* offsets,
142  ulint* n_ext,
144  mem_heap_t* heap);
146 /*******************************************************************/
150 UNIV_INTERN
151 dtuple_t*
153 /*===================*/
154  ulint type,
160  const rec_t* rec,
169  const dict_index_t* index,
170  ulint* offsets,
171  ulint* n_ext,
173  mem_heap_t* heap);
175 /*******************************************************************/
179 UNIV_INTERN
180 dtuple_t*
182 /*==============*/
183  ulint type,
187  dict_index_t* index,
188  const rec_t* rec,
195  mem_heap_t* heap);
197 /*******************************************************************/
200 UNIV_INTERN
201 void
203 /*=======================*/
204  dtuple_t* ref,
206  const rec_t* rec,
214  const dict_index_t* index,
215  ulint* offsets,
217  trx_t* trx);
218 /*******************************************************************/
221 UNIV_INLINE
222 void
224 /*===================*/
225  dtuple_t* ref,
227  const ulint* map,
230  const rec_t* rec,
233  const ulint* offsets);
234 /***************************************************************/
238 UNIV_INTERN
239 ibool
241 /*==================*/
242  btr_pcur_t* pcur,
244  ulint mode,
245  const dict_table_t* table,
246  const dtuple_t* ref,
247  mtr_t* mtr);
248 /*********************************************************************/
252 UNIV_INTERN
253 rec_t*
255 /*==============*/
256  ulint mode,
257  const rec_t* rec,
258  dict_index_t* index,
259  dict_index_t** clust_index,
260  mtr_t* mtr);
264  ROW_FOUND = 0,
273 };
274 
275 /***************************************************************/
278 UNIV_INTERN
281 /*===================*/
282  dict_index_t* index,
283  const dtuple_t* entry,
284  ulint mode,
285  btr_pcur_t* pcur,
287  mtr_t* mtr);
290 #define ROW_COPY_DATA 1
291 #define ROW_COPY_POINTERS 2
292 
293 /* The allowed latching order of index records is the following:
294 (1) a secondary index record ->
295 (2) the clustered index record ->
296 (3) rollback segment data for the clustered index record.
297 
298 No new latches may be obtained while the kernel mutex is reserved.
299 However, the kernel mutex can be reserved while latches are owned. */
300 
301 /*******************************************************************/
309 UNIV_INTERN
310 ulint
312 /*===========*/
313  const char* data,
314  ulint data_len,
316  const dict_field_t* dict_field,
317  char* buf,
318  ulint buf_size);
321 #ifndef UNIV_NONINL
322 #include "row0row.ic"
323 #endif
324 
325 #endif