MySQL 8.4.2
Source Code Documentation
|
Some definitions for full-text indices. More...
Go to the source code of this file.
Macros | |
#define | HA_FT_WTYPE HA_KEYTYPE_FLOAT |
#define | HA_FT_WLEN 4 |
#define | FT_SEGS 2 |
#define | ft_sintXkorr(A) mi_sint4korr(A) |
Accessor methods for the weight and the number of subkeys in a buffer. More... | |
#define | ft_intXstore(T, A) mi_int4store(T, A) |
#define | ft_floatXget(M) mi_float4get(M) |
Functions | |
int | _mi_ft_cmp (MI_INFO *, uint, const uchar *, const uchar *) |
int | _mi_ft_add (MI_INFO *, uint, uchar *, const uchar *, my_off_t) |
int | _mi_ft_del (MI_INFO *, uint, uchar *, const uchar *, my_off_t) |
uint | _mi_ft_convert_to_ft2 (MI_INFO *, uint, uchar *) |
Variables | |
const HA_KEYSEG | ft_keysegs [FT_SEGS] |
Some definitions for full-text indices.
#define ft_floatXget | ( | M | ) | mi_float4get(M) |
#define ft_intXstore | ( | T, | |
A | |||
) | mi_int4store(T, A) |
#define FT_SEGS 2 |
#define ft_sintXkorr | ( | A | ) | mi_sint4korr(A) |
Accessor methods for the weight and the number of subkeys in a buffer.
The weight is of float type and subkeys number is of integer type. Both are stored in the same position of the buffer and the stored object is identified by the sign (bit): the weight value is positive whilst the number of subkeys is negative.
In light of C's strict-aliasing rules, which roughly state that an object must not be accessed through incompatible types, these methods are used to avoid any problems arising from the type duality inside the buffer. The values are retrieved using a character type which can access any object.
#define HA_FT_WLEN 4 |
#define HA_FT_WTYPE HA_KEYTYPE_FLOAT |