InnoDB Plugin  1.0
fts0types.h
Go to the documentation of this file.
1 /*****************************************************************************
2 
3 Copyright (c) 2007, 2011, 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 /******************************************************************/
26 #ifndef INNOBASE_FTS0TYPES_H
27 #define INNOBASE_FTS0TYPES_H
28 
29 #include "que0types.h"
30 #include "ut0byte.h"
31 #include "fut0fut.h"
32 #include "ut0rbt.h"
33 #include "fts0fts.h"
34 
36 struct fts_que_t;
37 struct fts_node_t;
38 struct fts_utf8_str_t;
39 
42 typedef void (*fts_filter)(void*, fts_node_t*, void*, ulint len);
43 
47  ulint word_count;
48 };
49 
52 struct fts_get_doc_t {
57  que_t* get_document_graph;
59 };
60 
79  CHARSET_INFO* charset;
80 };
81 
85 struct fts_update_t {
94 };
95 
98  ulint status;
101  CHARSET_INFO* charset;
102 };
103 
106 struct fts_sync_t {
113  ulint lower_index;
116  ulint upper_index;
126 };
127 
131 struct fts_cache_t {
158  ulint total_size;
182  ulint deleted;
186  ulint added;
192 };
193 
195 struct fts_node_t {
200  byte* ilist;
208  ulint doc_count;
210  ulint ilist_size;
212  ulint ilist_size_alloc;
215 };
216 
223 };
224 
226 struct fts_word_t {
231 };
232 
234 struct fts_fetch_t {
235  void* read_arg;
240  ulint total_memory;
241 };
242 
245  ulint value;
248  const char* suffix;
249 };
250 
252 struct fts_doc_t {
268  CHARSET_INFO* charset;
269 };
270 
272 struct fts_token_t {
278 };
279 
282 
283 /******************************************************************/
285 UNIV_INLINE
286 int
288 /*================*/
293  const void* p1,
294  const void* p2);
296 /******************************************************************/
299 UNIV_INLINE
300 int
302 /*=======================*/
307  const void* p1,
308  const void* p2);
310 /******************************************************************/
312 UNIV_INLINE
313 int
315 /*===================*/
320  const void* p1,
321  const void* p2);
323 /******************************************************************/
325 UNIV_INLINE
326 int
328 /*===================*/
333  const void* p1,
334  const void* p2);
336 /******************************************************************/
338 UNIV_INLINE
339 int
341 /*==================*/
346  const void* p1,
347  const void* p2);
349 /******************************************************************/
351 UNIV_INLINE
352 ulint
354 /*===========*/
356  byte** ptr);
359 /******************************************************************/
361 UNIV_INLINE
362 void
364 /*================*/
369  fts_string_t* dst,
370  const fts_string_t* src,
371  mem_heap_t* heap);
373 /******************************************************************/
375 UNIV_INLINE
376 ulint
378 /*================*/
381  ulint val);
383 /******************************************************************/
385 UNIV_INLINE
386 ulint
388 /*===========*/
391  ulint val,
392  byte* buf);
395 /******************************************************************/
410 UNIV_INLINE
411 ulint
413 /*============*/
418  const byte** ptr);
424 /******************************************************************/
426 UNIV_INLINE
427 void
429 /*=============*/
430  fts_string_t* str);
432 /******************************************************************/
434 UNIV_INLINE
435 const char*
437 /*===========*/
438  ulint selected);
440 /********************************************************************
441 Get the number of index selectors. */
442 UNIV_INLINE
443 ulint
444 fts_get_n_selectors(void);
445 /*=====================*/
446 
447 /******************************************************************/
450 UNIV_INLINE
451 ulint
453 /*=============*/
454  const CHARSET_INFO* cs,
455  const byte* str,
456  ulint len);
458 /********************************************************************
459 Select the next FTS auxiliary index for the given character.
460 @return the next index to use for character */
461 UNIV_INLINE
462 ulint
464 /*==================*/
465  const CHARSET_INFO* cs,
466  const byte* str,
467  ulint len);
469 #ifndef UNIV_NONINL
470 #include "fts0types.ic"
471 #include "fts0vlc.ic"
472 #endif
473 
474 #endif /* INNOBASE_FTS0TYPES_H */