File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,20 @@ typedef uint16 WordEntryPos;
47
47
#define MAXNUMPOS 256
48
48
#define LIMITPOS (x ) ( ( (x) >= MAXENTRYPOS ) ? (MAXENTRYPOS-1) : (x) )
49
49
50
+ /*
51
+ * Structure of tsvector datatype:
52
+ * 1) int4 len - varlena's length
53
+ * 2) int4 size - number of lexemes or WordEntry array, which is the same
54
+ * 3) Array of WordEntry - sorted array, comparison based on word's length
55
+ * and strncmp(). WordEntry->pos points number of
56
+ * bytes from end of WordEntry array to start of
57
+ * corresponding lexeme.
58
+ * 4) Lexeme's storage:
59
+ * SHORTALIGNED(lexeme) and position information if it exists
60
+ * Position information: first int2 - is a number of positions and it
61
+ * follows array of WordEntryPos
62
+ */
63
+
50
64
typedef struct
51
65
{
52
66
int4 len ;
You can’t perform that action at this time.
0 commit comments