Go to the source code of this file.
Classes | |
struct | porter_tokenizer |
struct | porter_tokenizer_cursor |
Defines | |
#define | idChar(C) (((ch=C)&0x80)!=0 || (ch>0x2f && isIdChar[ch-0x30])) |
#define | isDelim(C) (((ch=C)&0x80)==0 && (ch<0x30 || !isIdChar[ch-0x30])) |
Functions | |
static int | porterCreate (int argc, const char *const *argv, sqlite3_tokenizer **ppTokenizer) |
static int | porterDestroy (sqlite3_tokenizer *pTokenizer) |
static int | porterOpen (sqlite3_tokenizer *pTokenizer, const char *zInput, int nInput, sqlite3_tokenizer_cursor **ppCursor) |
static int | porterClose (sqlite3_tokenizer_cursor *pCursor) |
static int | isVowel (const char *) |
static int | isConsonant (const char *z) |
static int | m_gt_0 (const char *z) |
static int | m_eq_1 (const char *z) |
static int | m_gt_1 (const char *z) |
static int | hasVowel (const char *z) |
static int | doubleConsonant (const char *z) |
static int | star_oh (const char *z) |
static int | stem (char **pz, const char *zFrom, const char *zTo, int(*xCond)(const char *)) |
static void | copy_stemmer (const char *zIn, int nIn, char *zOut, int *pnOut) |
static void | porter_stemmer (const char *zIn, int nIn, char *zOut, int *pnOut) |
static int | porterNext (sqlite3_tokenizer_cursor *pCursor, const char **pzToken, int *pnBytes, int *piStartOffset, int *piEndOffset, int *piPosition) |
void | sqlite3Fts1PorterTokenizerModule (sqlite3_tokenizer_module const **ppModule) |
Variables | |
static const sqlite3_tokenizer_module | porterTokenizerModule |
static const char | cType [] |
static const char | isIdChar [] |
#define idChar | ( | C | ) | (((ch=C)&0x80)!=0 || (ch>0x2f && isIdChar[ch-0x30])) |
Definition at line 571 of file fts1_porter.c.
#define isDelim | ( | C | ) | (((ch=C)&0x80)==0 && (ch<0x30 || !isIdChar[ch-0x30])) |
Definition at line 572 of file fts1_porter.c.
Referenced by porterNext(), and simpleNext().
static void copy_stemmer | ( | const char * | zIn, | |
int | nIn, | |||
char * | zOut, | |||
int * | pnOut | |||
) | [static] |
Definition at line 293 of file fts1_porter.c.
Referenced by porter_stemmer().
static int doubleConsonant | ( | const char * | z | ) | [static] |
Definition at line 236 of file fts1_porter.c.
References isConsonant().
Referenced by porter_stemmer().
static int hasVowel | ( | const char * | z | ) | [static] |
Definition at line 225 of file fts1_porter.c.
References isConsonant().
Referenced by porter_stemmer().
static int isConsonant | ( | const char * | z | ) | [static] |
Definition at line 149 of file fts1_porter.c.
References cType, and isVowel().
Referenced by doubleConsonant(), hasVowel(), isVowel(), m_eq_1(), m_gt_0(), m_gt_1(), and star_oh().
static int isVowel | ( | const char * | z | ) | [static] |
Definition at line 158 of file fts1_porter.c.
References cType, and isConsonant().
Referenced by isConsonant(), m_eq_1(), m_gt_0(), m_gt_1(), and star_oh().
static int m_eq_1 | ( | const char * | z | ) | [static] |
Definition at line 197 of file fts1_porter.c.
References isConsonant(), and isVowel().
Referenced by porter_stemmer().
static int m_gt_0 | ( | const char * | z | ) | [static] |
Definition at line 187 of file fts1_porter.c.
References isConsonant(), and isVowel().
Referenced by porter_stemmer().
static int m_gt_1 | ( | const char * | z | ) | [static] |
Definition at line 211 of file fts1_porter.c.
References isConsonant(), and isVowel().
Referenced by porter_stemmer().
static void porter_stemmer | ( | const char * | zIn, | |
int | nIn, | |||
char * | zOut, | |||
int * | pnOut | |||
) | [static] |
Definition at line 340 of file fts1_porter.c.
References copy_stemmer(), doubleConsonant(), hasVowel(), m_eq_1(), m_gt_0(), m_gt_1(), star_oh(), and stem().
Referenced by porterNext().
static int porterClose | ( | sqlite3_tokenizer_cursor * | pCursor | ) | [static] |
Definition at line 121 of file fts1_porter.c.
References SQLITE_OK, and porter_tokenizer_cursor::zToken.
static int porterCreate | ( | int | argc, | |
const char *const * | argv, | |||
sqlite3_tokenizer ** | ppTokenizer | |||
) | [static] |
Definition at line 64 of file fts1_porter.c.
References porter_tokenizer::base, SQLITE_NOMEM, and SQLITE_OK.
static int porterDestroy | ( | sqlite3_tokenizer * | pTokenizer | ) | [static] |
Definition at line 79 of file fts1_porter.c.
References SQLITE_OK.
static int porterNext | ( | sqlite3_tokenizer_cursor * | pCursor, | |
const char ** | pzToken, | |||
int * | pnBytes, | |||
int * | piStartOffset, | |||
int * | piEndOffset, | |||
int * | piPosition | |||
) | [static] |
Definition at line 578 of file fts1_porter.c.
References porter_tokenizer_cursor::iOffset, isDelim, porter_tokenizer_cursor::iToken, porter_tokenizer_cursor::nAllocated, porter_tokenizer_cursor::nInput, porter_stemmer(), SQLITE_DONE, SQLITE_NOMEM, SQLITE_OK, porter_tokenizer_cursor::zInput, and porter_tokenizer_cursor::zToken.
static int porterOpen | ( | sqlite3_tokenizer * | pTokenizer, | |
const char * | zInput, | |||
int | nInput, | |||
sqlite3_tokenizer_cursor ** | ppCursor | |||
) | [static] |
Definition at line 90 of file fts1_porter.c.
References porter_tokenizer_cursor::base, porter_tokenizer_cursor::iOffset, porter_tokenizer_cursor::iToken, porter_tokenizer_cursor::nAllocated, porter_tokenizer_cursor::nInput, SQLITE_NOMEM, SQLITE_OK, porter_tokenizer_cursor::zInput, and porter_tokenizer_cursor::zToken.
void sqlite3Fts1PorterTokenizerModule | ( | sqlite3_tokenizer_module const ** | ppModule | ) |
Definition at line 637 of file fts1_porter.c.
Referenced by constructVtab().
static int star_oh | ( | const char * | z | ) | [static] |
Definition at line 248 of file fts1_porter.c.
References isConsonant(), and isVowel().
Referenced by porter_stemmer().
static int stem | ( | char ** | pz, | |
const char * | zFrom, | |||
const char * | zTo, | |||
int(*)(const char *) | xCond | |||
) | [static] |
Definition at line 268 of file fts1_porter.c.
Referenced by porter_stemmer().
const char cType[] [static] |
{ 0, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 2, 1 }
Definition at line 130 of file fts1_porter.c.
Referenced by isConsonant(), and isVowel().
const char isIdChar[] [static] |
{ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, }
Definition at line 563 of file fts1_porter.c.
static const sqlite3_tokenizer_module porterTokenizerModule [static] |
{ 0, porterCreate, porterDestroy, porterOpen, porterClose, porterNext, }
Definition at line 58 of file fts1_porter.c.
ContextLogger2—ContextLogger2 Logger Daemon Internals—Generated on Mon May 2 13:49:58 2011 by Doxygen 1.6.1