MySQL 8.0.40
Source Code Documentation
fts0tokenize.h File Reference

Full Text Search plugin tokenizer refer to MyISAM. More...

#include "ft_global.h"
#include "m_ctype.h"
#include "mysql/plugin_ftparser.h"

Go to the source code of this file.

Classes

struct  FT_WORD
 FTS query token. More...
 

Macros

#define true_word_char(c, ch)   ((c) & (_MY_U | _MY_L | _MY_NMR) || (ch) == '_')
 Check a char is true word. More...
 
#define FTB_YES   (fts_boolean_syntax[0])
 
#define FTB_EGAL   (fts_boolean_syntax[1])
 
#define FTB_NO   (fts_boolean_syntax[2])
 
#define FTB_INC   (fts_boolean_syntax[3])
 
#define FTB_DEC   (fts_boolean_syntax[4])
 
#define FTB_LBR   (fts_boolean_syntax[5])
 
#define FTB_RBR   (fts_boolean_syntax[6])
 
#define FTB_NEG   (fts_boolean_syntax[7])
 
#define FTB_TRUNC   (fts_boolean_syntax[8])
 
#define FTB_LQUOT   (fts_boolean_syntax[10])
 
#define FTB_RQUOT   (fts_boolean_syntax[11])
 

Functions

uchar fts_get_word (const CHARSET_INFO *cs, uchar **start, uchar *end, FT_WORD *word, MYSQL_FTPARSER_BOOLEAN_INFO *info)
 Tokenizer for ngram referring to ft_get_word(ft_parser.c) in MyISAM. More...
 

Variables

static const char * fts_boolean_syntax = DEFAULT_FTB_SYNTAX
 Boolean search syntax. More...
 

Detailed Description

Full Text Search plugin tokenizer refer to MyISAM.

Created 2014/11/17 Shaohua Wang

Macro Definition Documentation

◆ FTB_DEC

#define FTB_DEC   (fts_boolean_syntax[4])

◆ FTB_EGAL

#define FTB_EGAL   (fts_boolean_syntax[1])

◆ FTB_INC

#define FTB_INC   (fts_boolean_syntax[3])

◆ FTB_LBR

#define FTB_LBR   (fts_boolean_syntax[5])

◆ FTB_LQUOT

#define FTB_LQUOT   (fts_boolean_syntax[10])

◆ FTB_NEG

#define FTB_NEG   (fts_boolean_syntax[7])

◆ FTB_NO

#define FTB_NO   (fts_boolean_syntax[2])

◆ FTB_RBR

#define FTB_RBR   (fts_boolean_syntax[6])

◆ FTB_RQUOT

#define FTB_RQUOT   (fts_boolean_syntax[11])

◆ FTB_TRUNC

#define FTB_TRUNC   (fts_boolean_syntax[8])

◆ FTB_YES

#define FTB_YES   (fts_boolean_syntax[0])

◆ true_word_char

#define true_word_char (   c,
  ch 
)    ((c) & (_MY_U | _MY_L | _MY_NMR) || (ch) == '_')

Check a char is true word.

Function Documentation

◆ fts_get_word()

uchar fts_get_word ( const CHARSET_INFO cs,
uchar **  start,
uchar end,
FT_WORD word,
MYSQL_FTPARSER_BOOLEAN_INFO info 
)
inline

Tokenizer for ngram referring to ft_get_word(ft_parser.c) in MyISAM.

Differences: a. code format changed; b. stopword processing removed.

Parameters
[in]cscharset
[in,out]startdoc start pointer
[in,out]enddoc end pointer
[in,out]wordtoken
[in,out]infotoken info
Return values
0eof
1word found
2left bracket
3right bracket
4stopword found

Variable Documentation

◆ fts_boolean_syntax

const char* fts_boolean_syntax = DEFAULT_FTB_SYNTAX
static

Boolean search syntax.