PostgreSQL Source Code
git master
|
Go to the source code of this file.
Data Structures | |
struct | ltree_level |
struct | ltree |
struct | lquery_variant |
struct | lquery_level |
struct | lquery |
struct | ITEM |
struct | ltxtquery |
struct | ltree_gist |
struct | LtreeGistOptions |
Macros | |
#define | LTREE_LABEL_MAX_CHARS 255 |
#define | LEVEL_HDRSIZE (offsetof(ltree_level,name)) |
#define | LEVEL_NEXT(x) ( (ltree_level*)( ((char*)(x)) + MAXALIGN(((ltree_level*)(x))->len + LEVEL_HDRSIZE) ) ) |
#define | LTREE_HDRSIZE MAXALIGN( offsetof(ltree, data) ) |
#define | LTREE_FIRST(x) ( (ltree_level*)( ((char*)(x))+LTREE_HDRSIZE ) ) |
#define | LTREE_MAX_LEVELS PG_UINT16_MAX /* ltree.numlevel is uint16 */ |
#define | LVAR_HDRSIZE MAXALIGN(offsetof(lquery_variant, name)) |
#define | LVAR_NEXT(x) ( (lquery_variant*)( ((char*)(x)) + MAXALIGN(((lquery_variant*)(x))->len) + LVAR_HDRSIZE ) ) |
#define | LVAR_ANYEND 0x01 /* '*' flag: prefix match */ |
#define | LVAR_INCASE 0x02 /* '@' flag: case-insensitive match */ |
#define | LVAR_SUBLEXEME 0x04 /* '%' flag: word-wise match */ |
#define | LQL_HDRSIZE MAXALIGN( offsetof(lquery_level,variants) ) |
#define | LQL_NEXT(x) ( (lquery_level*)( ((char*)(x)) + MAXALIGN(((lquery_level*)(x))->totallen) ) ) |
#define | LQL_FIRST(x) ( (lquery_variant*)( ((char*)(x))+LQL_HDRSIZE ) ) |
#define | LQL_NOT 0x10 /* level has '!' (NOT) prefix */ |
#define | LQL_COUNT 0x20 /* level is non-'*' and has repeat counts */ |
#define | FLG_CANLOOKSIGN(x) ( ( (x) & ( LQL_NOT | LVAR_ANYEND | LVAR_SUBLEXEME | LVAR_INCASE ) ) == 0 ) |
#define | LQL_CANLOOKSIGN(x) FLG_CANLOOKSIGN( ((lquery_level*)(x))->flag ) |
#define | LQUERY_HDRSIZE MAXALIGN( offsetof(lquery, data) ) |
#define | LQUERY_FIRST(x) ( (lquery_level*)( ((char*)(x))+LQUERY_HDRSIZE ) ) |
#define | LQUERY_MAX_LEVELS PG_UINT16_MAX /* lquery.numlevel is uint16 */ |
#define | LQUERY_HASNOT 0x01 |
#define | ISALNUM(x) ( t_isalpha(x) || t_isdigit(x) || ( pg_mblen(x) == 1 && t_iseq((x), '_') ) ) |
#define | HDRSIZEQT MAXALIGN(VARHDRSZ + sizeof(int32)) |
#define | COMPUTESIZE(size, lenofoperand) ( HDRSIZEQT + (size) * sizeof(ITEM) + (lenofoperand) ) |
#define | LTXTQUERY_TOO_BIG(size, lenofoperand) ((size) > (MaxAllocSize - HDRSIZEQT - (lenofoperand)) / sizeof(ITEM)) |
#define | GETQUERY(x) (ITEM*)( (char*)(x)+HDRSIZEQT ) |
#define | GETOPERAND(x) ( (char*)GETQUERY(x) + ((ltxtquery*)x)->size * sizeof(ITEM) ) |
#define | ISOPERATOR(x) ( (x)=='!' || (x)=='&' || (x)=='|' || (x)=='(' || (x)==')' ) |
#define | END 0 |
#define | ERR 1 |
#define | VAL 2 |
#define | OPR 3 |
#define | OPEN 4 |
#define | CLOSE 5 |
#define | VALTRUE 6 /* for stop words */ |
#define | VALFALSE 7 |
#define | DatumGetLtreeP(X) ((ltree *) PG_DETOAST_DATUM(X)) |
#define | DatumGetLtreePCopy(X) ((ltree *) PG_DETOAST_DATUM_COPY(X)) |
#define | PG_GETARG_LTREE_P(n) DatumGetLtreeP(PG_GETARG_DATUM(n)) |
#define | PG_GETARG_LTREE_P_COPY(n) DatumGetLtreePCopy(PG_GETARG_DATUM(n)) |
#define | DatumGetLqueryP(X) ((lquery *) PG_DETOAST_DATUM(X)) |
#define | DatumGetLqueryPCopy(X) ((lquery *) PG_DETOAST_DATUM_COPY(X)) |
#define | PG_GETARG_LQUERY_P(n) DatumGetLqueryP(PG_GETARG_DATUM(n)) |
#define | PG_GETARG_LQUERY_P_COPY(n) DatumGetLqueryPCopy(PG_GETARG_DATUM(n)) |
#define | DatumGetLtxtqueryP(X) ((ltxtquery *) PG_DETOAST_DATUM(X)) |
#define | DatumGetLtxtqueryPCopy(X) ((ltxtquery *) PG_DETOAST_DATUM_COPY(X)) |
#define | PG_GETARG_LTXTQUERY_P(n) DatumGetLtxtqueryP(PG_GETARG_DATUM(n)) |
#define | PG_GETARG_LTXTQUERY_P_COPY(n) DatumGetLtxtqueryPCopy(PG_GETARG_DATUM(n)) |
#define | SIGLEN_MAX GISTMaxIndexKeySize |
#define | SIGLEN_DEFAULT (2 * sizeof(int32)) |
#define | BITBYTE 8 |
#define | SIGLEN (sizeof(int32) * SIGLENINT) |
#define | SIGLENBIT(siglen) ((siglen) * BITBYTE) |
#define | LOOPBYTE(siglen) for(i = 0; i < (siglen); i++) |
#define | GETBYTE(x, i) ( *( (BITVECP)(x) + (int)( (i) / BITBYTE ) ) ) |
#define | GETBITBYTE(x, i) ( ((unsigned char)(x)) >> i & 0x01 ) |
#define | CLRBIT(x, i) GETBYTE(x,i) &= ~( 0x01 << ( (i) % BITBYTE ) ) |
#define | SETBIT(x, i) GETBYTE(x,i) |= ( 0x01 << ( (i) % BITBYTE ) ) |
#define | GETBIT(x, i) ( (GETBYTE(x,i) >> ( (i) % BITBYTE )) & 0x01 ) |
#define | HASHVAL(val, siglen) (((unsigned int)(val)) % SIGLENBIT(siglen)) |
#define | HASH(sign, val, siglen) SETBIT((sign), HASHVAL(val, siglen)) |
#define | LTG_ONENODE 0x01 |
#define | LTG_ALLTRUE 0x02 |
#define | LTG_NORIGHT 0x04 |
#define | LTG_HDRSIZE MAXALIGN(VARHDRSZ + sizeof(uint32)) |
#define | LTG_SIGN(x) ( (BITVECP)( ((char*)(x))+LTG_HDRSIZE ) ) |
#define | LTG_NODE(x) ( (ltree*)( ((char*)(x))+LTG_HDRSIZE ) ) |
#define | LTG_ISONENODE(x) ( ((ltree_gist*)(x))->flag & LTG_ONENODE ) |
#define | LTG_ISALLTRUE(x) ( ((ltree_gist*)(x))->flag & LTG_ALLTRUE ) |
#define | LTG_ISNORIGHT(x) ( ((ltree_gist*)(x))->flag & LTG_NORIGHT ) |
#define | LTG_LNODE(x, siglen) ( (ltree*)( ( ((char*)(x))+LTG_HDRSIZE ) + ( LTG_ISALLTRUE(x) ? 0 : (siglen) ) ) ) |
#define | LTG_RENODE(x, siglen) ( (ltree*)( ((char*)LTG_LNODE(x, siglen)) + VARSIZE(LTG_LNODE(x, siglen))) ) |
#define | LTG_RNODE(x, siglen) ( LTG_ISNORIGHT(x) ? LTG_LNODE(x, siglen) : LTG_RENODE(x, siglen) ) |
#define | LTG_GETLNODE(x, siglen) ( LTG_ISONENODE(x) ? LTG_NODE(x) : LTG_LNODE(x, siglen) ) |
#define | LTG_GETRNODE(x, siglen) ( LTG_ISONENODE(x) ? LTG_NODE(x) : LTG_RNODE(x, siglen) ) |
#define | LTREE_ASIGLEN_DEFAULT (7 * sizeof(int32)) |
#define | LTREE_ASIGLEN_MAX GISTMaxIndexKeySize |
#define | LTREE_GET_ASIGLEN() |
#define | ASIGLENBIT(siglen) ((siglen) * BITBYTE) |
#define | ALOOPBYTE(siglen) for (i = 0; i < (siglen); i++) |
#define | AHASHVAL(val, siglen) (((unsigned int)(val)) % ASIGLENBIT(siglen)) |
#define | AHASH(sign, val, siglen) SETBIT((sign), AHASHVAL(val, siglen)) |
Typedefs | |
typedef struct ITEM | ITEM |
typedef unsigned char * | BITVECP |
#define AHASHVAL | ( | val, | |
siglen | |||
) | (((unsigned int)(val)) % ASIGLENBIT(siglen)) |
Definition at line 289 of file ltree.h.
Referenced by checkcondition_bit(), gist_qe(), and gist_te().
Definition at line 286 of file ltree.h.
Referenced by _ltree_compress(), _ltree_picksplit(), _ltree_same(), hemdistsign(), and unionkey().
#define ASIGLENBIT | ( | siglen | ) | ((siglen) * BITBYTE) |
#define DatumGetLqueryP | ( | X | ) | ((lquery *) PG_DETOAST_DATUM(X)) |
#define DatumGetLqueryPCopy | ( | X | ) | ((lquery *) PG_DETOAST_DATUM_COPY(X)) |
#define DatumGetLtreeP | ( | X | ) | ((ltree *) PG_DETOAST_DATUM(X)) |
Definition at line 202 of file ltree.h.
Referenced by ltree_compress().
#define DatumGetLtreePCopy | ( | X | ) | ((ltree *) PG_DETOAST_DATUM_COPY(X)) |
#define DatumGetLtxtqueryP | ( | X | ) | ((ltxtquery *) PG_DETOAST_DATUM(X)) |
#define DatumGetLtxtqueryPCopy | ( | X | ) | ((ltxtquery *) PG_DETOAST_DATUM_COPY(X)) |
#define FLG_CANLOOKSIGN | ( | x | ) | ( ( (x) & ( LQL_NOT | LVAR_ANYEND | LVAR_SUBLEXEME | LVAR_INCASE ) ) == 0 ) |
Definition at line 96 of file ltree.h.
Referenced by checkcondition_bit().
Definition at line 151 of file ltree.h.
Referenced by cleanup_tsquery_stopwords(), collectTSQueryValues(), CompareTSQ(), find_wordentry(), gin_extract_tsquery(), hlfinditem(), join_tsqueries(), ltxtq_exec(), ltxtq_out(), ltxtq_send(), mcelem_tsquery_selec(), parse_tsquery(), QTN2QT(), queryin(), SortAndUniqItems(), ts_match_vq(), tsquery_not(), tsquery_rewrite(), tsquery_rewrite_query(), tsqueryout(), tsqueryrecv(), tsquerysend(), and tsquerytree().
Definition at line 116 of file ltree.h.
Referenced by gettoken_query(), parse_lquery(), and parse_ltree().
#define ISOPERATOR | ( | x | ) | ( (x)=='!' || (x)=='&' || (x)=='|' || (x)=='(' || (x)==')' ) |
Definition at line 153 of file ltree.h.
Referenced by gettoken_query_websearch(), and gettoken_tsvector().
#define LEVEL_HDRSIZE (offsetof(ltree_level,name)) |
Definition at line 26 of file ltree.h.
Referenced by lca_inner(), and parse_ltree().
#define LEVEL_NEXT | ( | x | ) | ( (ltree_level*)( ((char*)(x)) + MAXALIGN(((ltree_level*)(x))->len + LEVEL_HDRSIZE) ) ) |
Definition at line 27 of file ltree.h.
Referenced by checkCond(), checkcondition_str(), deparse_ltree(), gist_te(), gist_tqcmp(), hashing(), inner_isparent(), inner_subltree(), lca_inner(), ltree2text(), ltree_compare(), ltree_index(), ltree_to_plpython(), and parse_ltree().
#define LQL_CANLOOKSIGN | ( | x | ) | FLG_CANLOOKSIGN( ((lquery_level*)(x))->flag ) |
#define LQL_COUNT 0x20 /* level is non-'*' and has repeat counts */ |
Definition at line 91 of file ltree.h.
Referenced by checkCond(), deparse_lquery(), and parse_lquery().
#define LQL_FIRST | ( | x | ) | ( (lquery_variant*)( ((char*)(x))+LQL_HDRSIZE ) ) |
Definition at line 88 of file ltree.h.
Referenced by checkLevel(), deparse_lquery(), gist_qe(), gist_tqcmp(), and parse_lquery().
#define LQL_HDRSIZE MAXALIGN( offsetof(lquery_level,variants) ) |
Definition at line 86 of file ltree.h.
Referenced by parse_lquery().
#define LQL_NEXT | ( | x | ) | ( (lquery_level*)( ((char*)(x)) + MAXALIGN(((lquery_level*)(x))->totallen) ) ) |
Definition at line 87 of file ltree.h.
Referenced by checkCond(), deparse_lquery(), gist_qe(), gist_tqcmp(), and parse_lquery().
#define LQL_NOT 0x10 /* level has '!' (NOT) prefix */ |
Definition at line 90 of file ltree.h.
Referenced by checkLevel(), deparse_lquery(), and parse_lquery().
#define LQUERY_FIRST | ( | x | ) | ( (lquery_level*)( ((char*)(x))+LQUERY_HDRSIZE ) ) |
Definition at line 111 of file ltree.h.
Referenced by deparse_lquery(), gist_qe(), gist_tqcmp(), ltq_regex(), and parse_lquery().
#define LQUERY_HASNOT 0x01 |
Definition at line 114 of file ltree.h.
Referenced by parse_lquery().
Definition at line 110 of file ltree.h.
Referenced by parse_lquery().
#define LQUERY_MAX_LEVELS PG_UINT16_MAX /* lquery.numlevel is uint16 */ |
Definition at line 112 of file ltree.h.
Referenced by parse_lquery().
#define LTG_ALLTRUE 0x02 |
Definition at line 258 of file ltree.h.
Referenced by _ltree_union(), and ltree_gist_alloc().
#define LTG_GETLNODE | ( | x, | |
siglen | |||
) | ( LTG_ISONENODE(x) ? LTG_NODE(x) : LTG_LNODE(x, siglen) ) |
Definition at line 271 of file ltree.h.
Referenced by gist_between(), gist_ischild(), gist_isparent(), ltree_consistent(), ltree_penalty(), and ltree_picksplit().
#define LTG_GETRNODE | ( | x, | |
siglen | |||
) | ( LTG_ISONENODE(x) ? LTG_NODE(x) : LTG_RNODE(x, siglen) ) |
Definition at line 272 of file ltree.h.
Referenced by gist_between(), gist_ischild(), gist_isparent(), ltree_consistent(), ltree_penalty(), and ltree_picksplit().
Definition at line 261 of file ltree.h.
Referenced by _ltree_union(), and ltree_gist_alloc().
#define LTG_ISALLTRUE | ( | x | ) | ( ((ltree_gist*)(x))->flag & LTG_ALLTRUE ) |
Definition at line 265 of file ltree.h.
Referenced by _ltree_compress(), _ltree_picksplit(), _ltree_same(), gist_qe(), gist_qtxt(), gist_te(), hemdist(), ltree_picksplit(), ltree_same(), ltree_union(), and unionkey().
#define LTG_ISNORIGHT | ( | x | ) | ( ((ltree_gist*)(x))->flag & LTG_NORIGHT ) |
#define LTG_ISONENODE | ( | x | ) | ( ((ltree_gist*)(x))->flag & LTG_ONENODE ) |
Definition at line 264 of file ltree.h.
Referenced by ltree_picksplit(), ltree_same(), and ltree_union().
#define LTG_LNODE | ( | x, | |
siglen | |||
) | ( (ltree*)( ( ((char*)(x))+LTG_HDRSIZE ) + ( LTG_ISALLTRUE(x) ? 0 : (siglen) ) ) ) |
Definition at line 267 of file ltree.h.
Referenced by ltree_gist_alloc(), ltree_same(), and ltree_union().
#define LTG_NODE | ( | x | ) | ( (ltree*)( ((char*)(x))+LTG_HDRSIZE ) ) |
Definition at line 263 of file ltree.h.
Referenced by ltree_consistent(), ltree_gist_alloc(), ltree_picksplit(), ltree_same(), and ltree_union().
#define LTG_NORIGHT 0x04 |
Definition at line 259 of file ltree.h.
Referenced by ltree_gist_alloc().
#define LTG_ONENODE 0x01 |
Definition at line 257 of file ltree.h.
Referenced by ltree_gist_alloc().
#define LTG_RNODE | ( | x, | |
siglen | |||
) | ( LTG_ISNORIGHT(x) ? LTG_LNODE(x, siglen) : LTG_RENODE(x, siglen) ) |
Definition at line 269 of file ltree.h.
Referenced by ltree_gist_alloc(), ltree_same(), and ltree_union().
#define LTG_SIGN | ( | x | ) | ( (BITVECP)( ((char*)(x))+LTG_HDRSIZE ) ) |
Definition at line 262 of file ltree.h.
Referenced by _ltree_compress(), _ltree_picksplit(), _ltree_same(), _ltree_union(), gist_qe(), gist_qtxt(), gist_te(), hemdist(), ltree_gist_alloc(), ltree_picksplit(), ltree_same(), ltree_union(), and unionkey().
#define LTREE_ASIGLEN_DEFAULT (7 * sizeof(int32)) |
Definition at line 279 of file ltree.h.
Referenced by _ltree_gist_options().
#define LTREE_ASIGLEN_MAX GISTMaxIndexKeySize |
Definition at line 280 of file ltree.h.
Referenced by _ltree_gist_options().
#define LTREE_FIRST | ( | x | ) | ( (ltree_level*)( ((char*)(x))+LTREE_HDRSIZE ) ) |
Definition at line 38 of file ltree.h.
Referenced by checkcondition_str(), deparse_ltree(), gist_te(), gist_tqcmp(), hashing(), inner_isparent(), inner_subltree(), lca_inner(), ltq_regex(), ltree2text(), ltree_compare(), ltree_concat(), ltree_index(), ltree_to_plpython(), and parse_ltree().
#define LTREE_GET_ASIGLEN | ( | ) |
Definition at line 281 of file ltree.h.
Referenced by _ltree_compress(), _ltree_consistent(), _ltree_penalty(), _ltree_picksplit(), _ltree_same(), _ltree_union(), ltree_consistent(), ltree_penalty(), ltree_picksplit(), ltree_same(), and ltree_union().
Definition at line 37 of file ltree.h.
Referenced by inner_subltree(), lca_inner(), ltree_concat(), and parse_ltree().
#define LTREE_LABEL_MAX_CHARS 255 |
Definition at line 18 of file ltree.h.
Referenced by finish_nodeitem().
#define LTREE_MAX_LEVELS PG_UINT16_MAX /* ltree.numlevel is uint16 */ |
Definition at line 39 of file ltree.h.
Referenced by deparse_lquery(), ltree_concat(), parse_lquery(), and parse_ltree().
#define LTXTQUERY_TOO_BIG | ( | size, | |
lenofoperand | |||
) | ((size) > (MaxAllocSize - HDRSIZEQT - (lenofoperand)) / sizeof(ITEM)) |
#define LVAR_ANYEND 0x01 /* '*' flag: prefix match */ |
Definition at line 61 of file ltree.h.
Referenced by checkcondition_str(), checkLevel(), deparse_lquery(), gettoken_query(), infix(), and parse_lquery().
#define LVAR_HDRSIZE MAXALIGN(offsetof(lquery_variant, name)) |
Definition at line 58 of file ltree.h.
Referenced by parse_lquery().
#define LVAR_INCASE 0x02 /* '@' flag: case-insensitive match */ |
Definition at line 62 of file ltree.h.
Referenced by checkcondition_str(), checkLevel(), deparse_lquery(), gettoken_query(), infix(), and parse_lquery().
#define LVAR_NEXT | ( | x | ) | ( (lquery_variant*)( ((char*)(x)) + MAXALIGN(((lquery_variant*)(x))->len) + LVAR_HDRSIZE ) ) |
Definition at line 59 of file ltree.h.
Referenced by checkLevel(), deparse_lquery(), gist_qe(), and parse_lquery().
#define LVAR_SUBLEXEME 0x04 /* '%' flag: word-wise match */ |
Definition at line 63 of file ltree.h.
Referenced by checkcondition_str(), checkLevel(), deparse_lquery(), gettoken_query(), infix(), and parse_lquery().
#define PG_GETARG_LQUERY_P | ( | n | ) | DatumGetLqueryP(PG_GETARG_DATUM(n)) |
Definition at line 209 of file ltree.h.
Referenced by _ltq_extract_regex(), _ltq_regex(), lquery_out(), lquery_send(), ltq_regex(), and ltree_consistent().
#define PG_GETARG_LQUERY_P_COPY | ( | n | ) | DatumGetLqueryPCopy(PG_GETARG_DATUM(n)) |
#define PG_GETARG_LTREE_P | ( | n | ) | DatumGetLtreeP(PG_GETARG_DATUM(n)) |
Definition at line 204 of file ltree.h.
Referenced by _ltree_extract_isparent(), _ltree_extract_risparent(), _ltree_isparent(), _ltree_risparent(), lca(), lt_q_regex(), ltq_regex(), ltree2text(), ltree_addltree(), ltree_addtext(), ltree_consistent(), ltree_index(), ltree_isparent(), ltree_out(), ltree_risparent(), ltree_send(), ltree_textadd(), ltree_to_plpython(), ltxtq_exec(), nlevel(), subltree(), and subpath().
#define PG_GETARG_LTREE_P_COPY | ( | n | ) | DatumGetLtreePCopy(PG_GETARG_DATUM(n)) |
Definition at line 205 of file ltree.h.
Referenced by ltree_consistent().
#define PG_GETARG_LTXTQUERY_P | ( | n | ) | DatumGetLtxtqueryP(PG_GETARG_DATUM(n)) |
Definition at line 214 of file ltree.h.
Referenced by _ltxtq_exec(), _ltxtq_extract_exec(), ltree_consistent(), ltxtq_exec(), ltxtq_out(), and ltxtq_send().
#define PG_GETARG_LTXTQUERY_P_COPY | ( | n | ) | DatumGetLtxtqueryPCopy(PG_GETARG_DATUM(n)) |
#define SIGLEN_MAX GISTMaxIndexKeySize |
#define VALTRUE 6 /* for stop words */ |
Definition at line 161 of file ltree.h.
Referenced by findoprnd().
Datum _lt_q_regex | ( | PG_FUNCTION_ARGS | ) |
Definition at line 134 of file _ltree_op.c.
References ARR_DATA_PTR, ARR_DIMS, ARR_NDIM, array_contains_nulls(), array_iterator(), ArrayGetNItems(), ereport, errcode(), errmsg(), ERROR, ltq_regex(), NEXTVAL, PG_FREE_IF_COPY, PG_GETARG_ARRAYTYPE_P, and PG_RETURN_BOOL.
Referenced by _lt_q_rregex().
Datum _lt_q_rregex | ( | PG_FUNCTION_ARGS | ) |
Definition at line 168 of file _ltree_op.c.
References _lt_q_regex(), DirectFunctionCall2, PG_GETARG_DATUM, and PG_RETURN_DATUM.
Datum _ltq_regex | ( | PG_FUNCTION_ARGS | ) |
Definition at line 113 of file _ltree_op.c.
References array_iterator(), ltq_regex(), PG_FREE_IF_COPY, PG_GETARG_ARRAYTYPE_P, PG_GETARG_LQUERY_P, and PG_RETURN_BOOL.
Referenced by _ltq_rregex().
Datum _ltq_rregex | ( | PG_FUNCTION_ARGS | ) |
Definition at line 125 of file _ltree_op.c.
References _ltq_regex(), DirectFunctionCall2, PG_GETARG_DATUM, and PG_RETURN_DATUM.
Datum _ltree_isparent | ( | PG_FUNCTION_ARGS | ) |
Definition at line 71 of file _ltree_op.c.
References array_iterator(), ltree_isparent(), PG_FREE_IF_COPY, PG_GETARG_ARRAYTYPE_P, PG_GETARG_LTREE_P, and PG_RETURN_BOOL.
Referenced by _ltree_r_isparent().
Datum _ltree_risparent | ( | PG_FUNCTION_ARGS | ) |
Definition at line 92 of file _ltree_op.c.
References array_iterator(), ltree_risparent(), PG_FREE_IF_COPY, PG_GETARG_ARRAYTYPE_P, PG_GETARG_LTREE_P, and PG_RETURN_BOOL.
Referenced by _ltree_r_risparent().
Datum _ltxtq_exec | ( | PG_FUNCTION_ARGS | ) |
Definition at line 178 of file _ltree_op.c.
References array_iterator(), ltxtq_exec(), PG_FREE_IF_COPY, PG_GETARG_ARRAYTYPE_P, PG_GETARG_LTXTQUERY_P, and PG_RETURN_BOOL.
Referenced by _ltxtq_rexec().
Datum _ltxtq_rexec | ( | PG_FUNCTION_ARGS | ) |
Definition at line 190 of file _ltree_op.c.
References _ltxtq_exec(), DirectFunctionCall2, PG_GETARG_DATUM, and PG_RETURN_DATUM.
bool compare_subnode | ( | ltree_level * | t, |
char * | q, | ||
int | len, | ||
int(*)(const char *, const char *, size_t) | cmpptr, | ||
bool | anyend | ||
) |
Definition at line 44 of file lquery_op.c.
References getlexeme(), ltree_level::len, and ltree_level::name.
Referenced by checkcondition_str(), and checkLevel().
Definition at line 143 of file ltree_op.c.
References ltree_level::len, LEVEL_NEXT, LTREE_FIRST, ltree_level::name, and ltree::numlevel.
Referenced by ltree_consistent(), ltree_isparent(), and ltree_risparent().
Definition at line 426 of file ltree_op.c.
References i, ltree_level::len, LEVEL_HDRSIZE, LEVEL_NEXT, LTREE_FIRST, LTREE_HDRSIZE, MAXALIGN, Min, ltree_level::name, ltree::numlevel, palloc0(), and SET_VARSIZE.
Referenced by _lca(), and lca().
Datum lt_q_regex | ( | PG_FUNCTION_ARGS | ) |
Definition at line 239 of file lquery_op.c.
References ARR_DATA_PTR, ARR_DIMS, ARR_NDIM, array_contains_nulls(), ArrayGetNItems(), DatumGetBool, DirectFunctionCall2, ereport, errcode(), errmsg(), ERROR, ltq_regex(), NEXTVAL, PG_FREE_IF_COPY, PG_GETARG_ARRAYTYPE_P, PG_GETARG_LTREE_P, PG_RETURN_BOOL, and PointerGetDatum.
Referenced by lt_q_rregex(), and ltree_consistent().
Datum lt_q_rregex | ( | PG_FUNCTION_ARGS | ) |
Definition at line 275 of file lquery_op.c.
References DirectFunctionCall2, lt_q_regex(), PG_GETARG_DATUM, and PG_RETURN_DATUM.
Datum ltq_regex | ( | PG_FUNCTION_ARGS | ) |
Definition at line 215 of file lquery_op.c.
References checkCond(), LQUERY_FIRST, LTREE_FIRST, ltree::numlevel, lquery::numlevel, PG_FREE_IF_COPY, PG_GETARG_LQUERY_P, PG_GETARG_LTREE_P, and PG_RETURN_BOOL.
Referenced by _lt_q_regex(), _ltq_extract_regex(), _ltq_regex(), lt_q_regex(), ltq_rregex(), and ltree_consistent().
Datum ltq_rregex | ( | PG_FUNCTION_ARGS | ) |
Definition at line 230 of file lquery_op.c.
References DirectFunctionCall2, ltq_regex(), PG_GETARG_DATUM, and PG_RETURN_DATUM.
Datum ltree_addltree | ( | PG_FUNCTION_ARGS | ) |
Definition at line 297 of file ltree_op.c.
References ltree_concat(), PG_FREE_IF_COPY, PG_GETARG_LTREE_P, and PG_RETURN_POINTER.
Datum ltree_addtext | ( | PG_FUNCTION_ARGS | ) |
Definition at line 310 of file ltree_op.c.
References DatumGetPointer, DirectFunctionCall1, ltree_concat(), ltree_in(), pfree(), PG_FREE_IF_COPY, PG_GETARG_LTREE_P, PG_GETARG_TEXT_PP, PG_RETURN_POINTER, PointerGetDatum, and text_to_cstring().
Definition at line 42 of file ltree_op.c.
References ltree_level::len, LEVEL_NEXT, LTREE_FIRST, Min, ltree_level::name, and ltree::numlevel.
Referenced by gist_ischild(), gist_isparent(), ltree_consistent(), ltree_penalty(), ltree_picksplit(), ltree_union(), and treekey_cmp().
bool ltree_execute | ( | ITEM * | curitem, |
void * | checkval, | ||
bool | calcnot, | ||
bool(*)(void *checkval, ITEM *val) | chkcond | ||
) |
Definition at line 20 of file ltxtquery_op.c.
References check_stack_depth(), ITEM::left, ITEM::type, ITEM::val, and VAL.
Referenced by gist_qtxt(), and ltxtq_exec().
ltree_gist* ltree_gist_alloc | ( | bool | isalltrue, |
BITVECP | sign, | ||
int | siglen, | ||
ltree * | left, | ||
ltree * | right | ||
) |
Definition at line 39 of file ltree_gist.c.
References Assert, ltree_gist::flag, ISEQ, LTG_ALLTRUE, LTG_HDRSIZE, LTG_LNODE, LTG_NODE, LTG_NORIGHT, LTG_ONENODE, LTG_RNODE, LTG_SIGN, ltree_compress(), ltree_consistent(), ltree_decompress(), ltree_gist_options(), ltree_penalty(), ltree_picksplit(), ltree_same(), ltree_union(), palloc(), PG_FUNCTION_INFO_V1(), SET_VARSIZE, and VARSIZE.
Referenced by _ltree_compress(), _ltree_picksplit(), _ltree_union(), ltree_compress(), ltree_picksplit(), and ltree_union().
Datum ltree_in | ( | PG_FUNCTION_ARGS | ) |
Definition at line 172 of file ltree_io.c.
References buf, ltree_out(), parse_ltree(), PG_FUNCTION_INFO_V1(), PG_GETARG_POINTER, and PG_RETURN_POINTER.
Referenced by deparse_ltree(), ltree_addtext(), ltree_textadd(), and text2ltree().
Datum ltree_isparent | ( | PG_FUNCTION_ARGS | ) |
Definition at line 167 of file ltree_op.c.
References inner_isparent(), PG_FREE_IF_COPY, PG_GETARG_LTREE_P, and PG_RETURN_BOOL.
Referenced by _ltree_extract_isparent(), and _ltree_isparent().
Datum ltree_risparent | ( | PG_FUNCTION_ARGS | ) |
Definition at line 179 of file ltree_op.c.
References inner_isparent(), PG_FREE_IF_COPY, PG_GETARG_LTREE_P, and PG_RETURN_BOOL.
Referenced by _ltree_extract_risparent(), and _ltree_risparent().
int ltree_strncasecmp | ( | const char * | a, |
const char * | b, | ||
size_t | s | ||
) |
Definition at line 78 of file lquery_op.c.
References pfree(), and str_tolower().
Referenced by checkcondition_str(), and checkLevel().
Datum ltree_textadd | ( | PG_FUNCTION_ARGS | ) |
Definition at line 395 of file ltree_op.c.
References DatumGetPointer, DirectFunctionCall1, ltree_concat(), ltree_in(), pfree(), PG_FREE_IF_COPY, PG_GETARG_LTREE_P, PG_GETARG_TEXT_PP, PG_RETURN_POINTER, PointerGetDatum, and text_to_cstring().
Datum ltxtq_exec | ( | PG_FUNCTION_ARGS | ) |
Definition at line 84 of file ltxtquery_op.c.
References checkcondition_str(), GETOPERAND, GETQUERY, ltree_execute(), CHKVAL::node, CHKVAL::operand, PG_FREE_IF_COPY, PG_GETARG_LTREE_P, PG_GETARG_LTXTQUERY_P, PG_RETURN_BOOL, and val.
Referenced by _ltxtq_exec(), _ltxtq_extract_exec(), ltree_consistent(), and ltxtq_rexec().
Datum ltxtq_rexec | ( | PG_FUNCTION_ARGS | ) |
Definition at line 105 of file ltxtquery_op.c.
References DirectFunctionCall2, ltxtq_exec(), PG_GETARG_DATUM, and PG_RETURN_DATUM.