PostgreSQL Source Code
git master
|
#include "postgres.h"
#include "btree_gist.h"
#include "btree_utils_num.h"
#include "utils/builtins.h"
#include "utils/timestamp.h"
Go to the source code of this file.
Data Structures | |
struct | intvKEY |
Macros | |
#define | INTERVALSIZE 16 |
Variables | |
static const gbtree_ninfo | tinfo |
#define INTERVALSIZE 16 |
Definition at line 96 of file btree_interval.c.
Definition at line 114 of file btree_interval.c.
References a, DatumGetBool(), DatumGetIntervalP(), DirectFunctionCall1, DirectFunctionCall2, interval_lt(), interval_um(), and IntervalPGetDatum().
Referenced by interval_dist(), time_dist(), ts_dist(), and tstz_dist().
Datum gbt_intv_compress | ( | PG_FUNCTION_ARGS | ) |
Definition at line 145 of file btree_interval.c.
References DatumGetIntervalP(), DatumGetPointer(), gistentryinit, INTERVALSIZE, GISTENTRY::key, sort-test::key, GISTENTRY::leafkey, GISTENTRY::offset, GISTENTRY::page, palloc(), PG_GETARG_POINTER, PG_RETURN_POINTER, PointerGetDatum(), and GISTENTRY::rel.
Datum gbt_intv_consistent | ( | PG_FUNCTION_ARGS | ) |
Definition at line 210 of file btree_interval.c.
References DatumGetPointer(), gbt_num_consistent(), GIST_LEAF, GISTENTRY::key, sort-test::key, intvKEY::lower, PG_GETARG_INTERVAL_P, PG_GETARG_POINTER, PG_GETARG_UINT16, PG_RETURN_BOOL, tinfo, and intvKEY::upper.
Datum gbt_intv_decompress | ( | PG_FUNCTION_ARGS | ) |
Definition at line 187 of file btree_interval.c.
References DatumGetPointer(), gistentryinit, INTERVALSIZE, GISTENTRY::key, sort-test::key, intvKEY::lower, GISTENTRY::offset, GISTENTRY::page, palloc(), PG_GETARG_POINTER, PG_RETURN_POINTER, PointerGetDatum(), GISTENTRY::rel, and intvKEY::upper.
Datum gbt_intv_distance | ( | PG_FUNCTION_ARGS | ) |
Definition at line 233 of file btree_interval.c.
References DatumGetPointer(), gbt_num_distance(), GIST_LEAF, GISTENTRY::key, sort-test::key, intvKEY::lower, PG_GETARG_INTERVAL_P, PG_GETARG_POINTER, PG_RETURN_FLOAT8, tinfo, and intvKEY::upper.
Datum gbt_intv_fetch | ( | PG_FUNCTION_ARGS | ) |
Definition at line 179 of file btree_interval.c.
References gbt_num_fetch(), PG_GETARG_POINTER, PG_RETURN_POINTER, and tinfo.
Datum gbt_intv_penalty | ( | PG_FUNCTION_ARGS | ) |
Definition at line 262 of file btree_interval.c.
References DatumGetPointer(), intr2num(), sort-test::key, intvKEY::lower, penalty_num, PG_GETARG_POINTER, PG_RETURN_POINTER, and intvKEY::upper.
Datum gbt_intv_picksplit | ( | PG_FUNCTION_ARGS | ) |
Definition at line 281 of file btree_interval.c.
References gbt_num_picksplit(), PG_GETARG_POINTER, PG_RETURN_POINTER, and tinfo.
Datum gbt_intv_same | ( | PG_FUNCTION_ARGS | ) |
Definition at line 289 of file btree_interval.c.
References gbt_num_same(), PG_GETARG_POINTER, PG_RETURN_POINTER, and tinfo.
Datum gbt_intv_union | ( | PG_FUNCTION_ARGS | ) |
Definition at line 251 of file btree_interval.c.
References gbt_num_union(), palloc(), PG_GETARG_POINTER, PG_RETURN_POINTER, and tinfo.
Definition at line 45 of file btree_interval.c.
References a, b, DatumGetBool(), DirectFunctionCall2, interval_eq(), and IntervalPGetDatum().
Definition at line 39 of file btree_interval.c.
References a, b, DatumGetBool(), DirectFunctionCall2, interval_ge(), and IntervalPGetDatum().
Definition at line 33 of file btree_interval.c.
References a, b, DatumGetBool(), DirectFunctionCall2, interval_gt(), and IntervalPGetDatum().
|
static |
Definition at line 63 of file btree_interval.c.
References a, b, DatumGetInt32(), DirectFunctionCall2, interval_cmp(), IntervalPGetDatum(), intvKEY::lower, res, and intvKEY::upper.
Definition at line 51 of file btree_interval.c.
References a, b, DatumGetBool(), DirectFunctionCall2, interval_le(), and IntervalPGetDatum().
Definition at line 57 of file btree_interval.c.
References a, b, DatumGetBool(), DirectFunctionCall2, interval_lt(), and IntervalPGetDatum().
Datum interval_dist | ( | PG_FUNCTION_ARGS | ) |
Definition at line 129 of file btree_interval.c.
References abs_interval(), DatumGetIntervalP(), DirectFunctionCall2, interval_mi(), PG_GETARG_DATUM, and PG_RETURN_INTERVAL_P.
|
static |
Definition at line 78 of file btree_interval.c.
References i, and INTERVAL_TO_SEC.
Referenced by gbt_intv_dist(), and gbt_intv_penalty().
PG_FUNCTION_INFO_V1 | ( | gbt_intv_compress | ) |
PG_FUNCTION_INFO_V1 | ( | gbt_intv_consistent | ) |
PG_FUNCTION_INFO_V1 | ( | gbt_intv_decompress | ) |
PG_FUNCTION_INFO_V1 | ( | gbt_intv_distance | ) |
PG_FUNCTION_INFO_V1 | ( | gbt_intv_fetch | ) |
PG_FUNCTION_INFO_V1 | ( | gbt_intv_penalty | ) |
PG_FUNCTION_INFO_V1 | ( | gbt_intv_picksplit | ) |
PG_FUNCTION_INFO_V1 | ( | gbt_intv_same | ) |
PG_FUNCTION_INFO_V1 | ( | gbt_intv_union | ) |
PG_FUNCTION_INFO_V1 | ( | interval_dist | ) |
|
static |
Definition at line 98 of file btree_interval.c.
Referenced by gbt_intv_consistent(), gbt_intv_distance(), gbt_intv_fetch(), gbt_intv_picksplit(), gbt_intv_same(), and gbt_intv_union().