InnoDB Plugin
1.0
|
#include "que0types.h"
#include "ut0byte.h"
#include "fut0fut.h"
#include "ut0rbt.h"
#include "fts0fts.h"
#include "fts0types.ic"
#include "fts0vlc.ic"
Go to the source code of this file.
Data Structures | |
struct | fts_doc_stats_t |
struct | fts_get_doc_t |
struct | fts_index_cache_t |
struct | fts_update_t |
struct | fts_stopword_t |
struct | fts_sync_t |
struct | fts_cache_t |
struct | fts_node_t |
struct | fts_tokenizer_word_t |
struct | fts_word_t |
struct | fts_fetch_t |
struct | fts_index_selector_t |
struct | fts_doc_t |
struct | fts_token_t |
Typedefs | |
typedef pars_user_func_cb_t | fts_sql_callback |
typedef void(* | fts_filter )(void *, fts_node_t *, void *, ulint len) |
Functions | |
UNIV_INLINE int | fts_utf8_string_cmp (const void *p1, const void *p2) |
UNIV_INLINE int | fts_utf8_string_cmp_prefix (const void *p1, const void *p2) |
UNIV_INLINE int | fts_trx_row_doc_id_cmp (const void *p1, const void *p2) |
UNIV_INLINE int | fts_ranking_doc_id_cmp (const void *p1, const void *p2) |
UNIV_INLINE int | fts_update_doc_id_cmp (const void *p1, const void *p2) |
UNIV_INLINE ulint | fts_decode_vlc (byte **ptr) |
UNIV_INLINE void | fts_utf8_string_dup (fts_string_t *dst, const fts_string_t *src, mem_heap_t *heap) |
UNIV_INLINE ulint | fts_get_encoded_len (ulint val) |
UNIV_INLINE ulint | fts_encode_int (ulint val, byte *buf) |
UNIV_INLINE ulint | fts_utf8_decode (const byte **ptr) |
UNIV_INLINE void | fts_utf8_tolower (fts_string_t *str) |
UNIV_INLINE const char * | fts_get_suffix (ulint selected) |
UNIV_INLINE ulint | fts_get_n_selectors (void) |
UNIV_INLINE ulint | fts_select_index (const CHARSET_INFO *cs, const byte *str, ulint len) |
UNIV_INLINE ulint | fts_select_next_index (const CHARSET_INFO *cs, const byte *str, ulint len) |
Variables | |
const fts_index_selector_t | fts_index_selector [] |
Full text search types file
Created 2007-03-27 Sunny Bains
typedef pars_user_func_cb_t fts_sql_callback |
Callbacks used within FTS.
UNIV_INLINE ulint fts_decode_vlc | ( | byte ** | ptr | ) |
Decode and return the integer that was encoded using our VLC scheme. in: ptr to decode from, this ptr is incremented by the number of bytes decoded
Decode and return the integer that was encoded using our VLC scheme.
ptr | out: value decoded |
UNIV_INLINE ulint fts_encode_int | ( | ulint | val, |
byte * | buf | ||
) |
Encode an integer using our VLC scheme and return the length in bytes. in: buffer, must have enough space
Encode an integer using our VLC scheme and return the length in bytes.
val | out: length of value encoded, in bytes in: value to encode |
UNIV_INLINE ulint fts_get_encoded_len | ( | ulint | val | ) |
Return length of val if it were encoded using our VLC scheme. in: value to encode
Return length of val if it were encoded using our VLC scheme. FIXME: We will need to be able encode 8 bytes value
val | out: length of value encoded, in bytes |
UNIV_INLINE ulint fts_get_n_selectors | ( | void | ) |
Get the number of index selectors.
UNIV_INLINE const char* fts_get_suffix | ( | ulint | selected | ) |
Get the selected FTS aux INDEX suffix. in: selected index
Return the selected FTS aux index suffix.
selected | in: selected index |
UNIV_INLINE int fts_ranking_doc_id_cmp | ( | const void * | p1, |
const void * | p2 | ||
) |
Compare two fts_ranking_t instances doc_ids. in: id2
Compare two fts_ranking_t doc_ids.
p1 | in: id1 |
p2 | in: id2 |
UNIV_INLINE ulint fts_select_index | ( | const CHARSET_INFO * | cs, |
const byte * | str, | ||
ulint | len | ||
) |
Select the FTS auxiliary index for the given string.
Select the FTS auxiliary index for the given character.
cs | in: Charset |
str | in: string |
len | in: string length |
UNIV_INLINE ulint fts_select_next_index | ( | const CHARSET_INFO * | cs, |
const byte * | str, | ||
ulint | len | ||
) |
in: string length
Select the next FTS auxiliary index for the given character.
cs | in: Charset |
str | in: string |
len | in: string length |
UNIV_INLINE int fts_trx_row_doc_id_cmp | ( | const void * | p1, |
const void * | p2 | ||
) |
Compare two fts_trx_row_t instances doc_ids. in: id2
Compare two fts_trx_row_t doc_ids.
p1 | in: id1 |
p2 | in: id2 |
UNIV_INLINE int fts_update_doc_id_cmp | ( | const void * | p1, |
const void * | p2 | ||
) |
Compare two fts_update_t instances doc_ids. in: id2
Compare two fts_update_t doc_ids.
p1 | in: id1 |
p2 | in: id2 |
UNIV_INLINE ulint fts_utf8_decode | ( | const byte ** | ptr | ) |
Decode a UTF-8 character.
http://www.unicode.org/versions/Unicode4.0.0/ch03.pdf:
Scalar Value 1st Byte 2nd Byte 3rd Byte 4th Byte 00000000 0xxxxxxx 0xxxxxxx 00000yyy yyxxxxxx 110yyyyy 10xxxxxx zzzzyyyy yyxxxxxx 1110zzzz 10yyyyyy 10xxxxxx 000uuuzz zzzzyyyy yyxxxxxx 11110uuu 10zzzzzz 10yyyyyy 10xxxxxx
This function decodes UTF-8 sequences up to 6 bytes (31 bits).
On error *ptr will point to the first byte that was not correctly decoded. This will hopefully help in resyncing the input. in/out: pointer to UTF-8 string. The pointer is advanced to the start of the next character.
Decode a UTF-8 character.
http://www.unicode.org/versions/Unicode4.0.0/ch03.pdf:
Scalar Value 1st Byte 2nd Byte 3rd Byte 4th Byte 00000000 0xxxxxxx 0xxxxxxx 00000yyy yyxxxxxx 110yyyyy 10xxxxxx zzzzyyyy yyxxxxxx 1110zzzz 10yyyyyy 10xxxxxx 000uuuzz zzzzyyyy yyxxxxxx 11110uuu 10zzzzzz 10yyyyyy 10xxxxxx
This function decodes UTF-8 sequences up to 6 bytes (31 bits).
On error *ptr will point to the first byte that was not correctly decoded. This will hopefully help in resyncing the input.
ptr | in/out: pointer to UTF-8 string. The pointer is advanced to the start of the next character. |
UNIV_INLINE int fts_utf8_string_cmp | ( | const void * | p1, |
const void * | p2 | ||
) |
Compare two UTF-8 strings. in: node
Compare two UTF-8 strings.
p1 | in: key |
p2 | in: node |
UNIV_INLINE int fts_utf8_string_cmp_prefix | ( | const void * | p1, |
const void * | p2 | ||
) |
Compare two UTF-8 strings, and return match (0) if passed in "key" value equals or is the prefix of the "node" value. in: node
Compare two UTF-8 strings, and return match (0) if passed in "key" value equals or is the prefix of the "node" value.
p1 | in: key |
p2 | in: node |
UNIV_INLINE void fts_utf8_string_dup | ( | fts_string_t * | dst, |
const fts_string_t * | src, | ||
mem_heap_t * | heap | ||
) |
Duplicate an UTF-8 string. in: heap to use
Duplicate an UTF-8 string.
dst | in: dup to here |
src | in: src string |
heap | in: heap to use |
UNIV_INLINE void fts_utf8_tolower | ( | fts_string_t * | str | ) |
Lowercase an UTF-8 string. in: string
Lowercase an UTF-8 string.
str | in: string |
const fts_index_selector_t fts_index_selector[] |
It's defined in fts/fts0fts.c