MobilityDB 1.1
Functions
set_ops.c File Reference
#include <assert.h>
#include <postgres.h>
#include <meos.h>
#include <meos_internal.h>
#include "general/set.h"
#include "general/type_util.h"
Include dependency graph for set_ops.c:

Functions

bool after_timestamp_timestampset (TimestampTz t, const Set *ts)
 Return true if a timestamp is strictly after a timestamp set. More...
 
bool after_timestampset_timestamptz (const Set *s, TimestampTz t)
 Return true if a set is strictly to the right of a value. More...
 
bool bbox_contains_set_set (const Set *s1, const Set *s2)
 Return true if the bounding box of the first set contains the bounding box of the second. More...
 
bool bbox_contains_set_value (const Set *s, Datum d, meosType basetype)
 Return true if the bounding box of the first set contains the value. More...
 
bool bbox_overlaps_set_set (const Set *s1, const Set *s2)
 Operators for set types. More...
 
bool before_timestamp_timestampset (TimestampTz t, const Set *ts)
 Return true if a timestamp is strictly before the second one. More...
 
bool before_timestampset_timestamp (const Set *s, TimestampTz t)
 Return true if a set is strictly to the left of a value. More...
 
bool contained_bigint_bigintset (int64 i, const Set *s)
 Return true if a value is contained by a set. More...
 
bool contained_float_floatset (double d, const Set *s)
 Return true if a value is contained by a set. More...
 
bool contained_int_intset (int i, const Set *s)
 Return true if a value is contained by a set. More...
 
bool contained_set_set (const Set *s1, const Set *s2)
 Return true if a set is contained by the second one. More...
 
bool contained_text_textset (text *txt, const Set *s)
 Return true if a value is contained by a set. More...
 
bool contained_timestamp_timestampset (TimestampTz t, const Set *ts)
 Return true if a timestamp is contained by a timestamp set. More...
 
bool contained_value_set (Datum d, meosType basetype, const Set *s)
 Return true if a value is contained by a set. More...
 
bool contains_bigintset_bigint (const Set *s, int64 i)
 Return true if a set contains a value. More...
 
bool contains_floatset_float (const Set *s, double d)
 Return true if a set contains a value. More...
 
bool contains_intset_int (const Set *s, int i)
 Return true if a set contains a value. More...
 
bool contains_set_set (const Set *s1, const Set *s2)
 Return true if the first set contains the second one. More...
 
bool contains_set_value (const Set *s, Datum d, meosType basetype)
 Return true if a set contains a value. More...
 
bool contains_textset_text (const Set *s, text *t)
 Return true if a set contains a value. More...
 
bool contains_timestampset_timestamp (const Set *ts, TimestampTz t)
 Return true if a timestamp set contains a timestamp. More...
 
double distance_bigintset_bigint (const Set *s, int64 i)
 Return the distance between a set and a value. More...
 
double distance_floatset_float (const Set *s, double d)
 Return the distance between a set and a value. More...
 
double distance_intset_int (const Set *s, int i)
 Return the distance between a set and a value. More...
 
double distance_set_set (const Set *s1, const Set *s2)
 Return the distance between two sets. More...
 
double distance_set_value (const Set *s, Datum d, meosType basetype)
 Return the distance between a set and a value. More...
 
double distance_textset_text (const Set *s, const text *txt)
 Return the distance between a set and a value. More...
 
double distance_timestampset_timestamp (const Set *ts, TimestampTz t)
 Return the distance in seconds between a timestamp set and a timestamp. More...
 
bool intersection_bigintset_bigint (const Set *s, int64 i, int64 *result)
 Return the intersection of a set and a value. More...
 
bool intersection_floatset_float (const Set *s, double d, double *result)
 Return the intersection of a set and a value. More...
 
bool intersection_intset_int (const Set *s, int i, int *result)
 Return the intersection of a set and a value. More...
 
Setintersection_set_set (const Set *s1, const Set *s2)
 Return the intersection of two sets. More...
 
bool intersection_set_value (const Set *s, Datum d, meosType basetype, Datum *result)
 Return the intersection of a set and a value. More...
 
bool intersection_textset_text (const Set *s, const text *txt, text **result)
 Return the intersection of a set and a value. More...
 
bool intersection_timestampset_timestamp (const Set *ts, TimestampTz t, TimestampTz *result)
 Return the intersection of a timestamp set and a timestamp. More...
 
bool left_bigint_bigintset (int64 i, const Set *s)
 Return true if a value is strictly to the left of a span set. More...
 
bool left_bigintset_bigint (const Set *s, int64 i)
 Return true if a set is strictly to the left of a value. More...
 
bool left_float_floatset (double d, const Set *s)
 Return true if a value is strictly to the left of a span set. More...
 
bool left_floatset_float (const Set *s, double d)
 Return true if a set is strictly to the left of a value. More...
 
bool left_int_intset (int i, const Set *s)
 Return true if a value is strictly to the left of a span set. More...
 
bool left_intset_int (const Set *s, int i)
 Return true if a set is strictly to the left of a value. More...
 
bool left_set_set (const Set *s1, const Set *s2)
 Return true if the first set is strictly to the left of a second one. More...
 
bool left_set_value (const Set *s, Datum d, meosType basetype)
 Return true if a set is strictly to the left of a value. More...
 
bool left_text_textset (text *txt, const Set *s)
 Return true if a value is strictly to the left of a span set. More...
 
bool left_textset_text (const Set *s, text *txt)
 Return true if a set is strictly to the left of a value. More...
 
bool left_value_set (Datum d, meosType basetype, const Set *s)
 Return true if a value is strictly to the left of a set. More...
 
bool minus_bigint_bigintset (int64 i, const Set *s, int64 *result)
 Return the difference of a value and a set. More...
 
Setminus_bigintset_bigint (const Set *s, int64 i)
 Return the difference of a set and a value. More...
 
bool minus_float_floatset (double d, const Set *s, double *result)
 Return the intersection of a value and a span set. More...
 
Setminus_floatset_float (const Set *s, double d)
 Return the difference of a set and a value. More...
 
bool minus_int_intset (int i, const Set *s, int *result)
 Return the difference of a value and a set. More...
 
Setminus_intset_int (const Set *s, int i)
 Return the difference of a set and a value. More...
 
Setminus_set_set (const Set *s1, const Set *s2)
 Return the difference of two sets. More...
 
Setminus_set_value (const Set *s, Datum d, meosType basetype)
 Return the difference of a set and a value. More...
 
bool minus_text_textset (const text *txt, const Set *s, text **result)
 Return the intersection of a value and a span set. More...
 
Setminus_textset_text (const Set *s, const text *txt)
 Return the difference of a set and a value. More...
 
Setminus_timestampset_timestamp (const Set *ts, TimestampTz t)
 Return the difference of a timestamp set and a timestamp. More...
 
bool minus_value_set (Datum d, meosType basetype, const Set *s, Datum *result)
 Return the difference of a value and a set. More...
 
bool overafter_timestamp_timestampset (TimestampTz t, const Set *ts)
 Return true if a timestamp is not before a timestamp set. More...
 
bool overafter_timestampset_timestamp (const Set *s, TimestampTz t)
 Return true if a set does not extend to the left of a value. More...
 
bool overbefore_timestamp_timestampset (TimestampTz t, const Set *ts)
 Return true if a timestamp is not after a timestamp set. More...
 
bool overbefore_timestampset_timestamp (const Set *s, TimestampTz t)
 Return true if a set does not extend to the right of a value. More...
 
bool overlaps_set_set (const Set *s1, const Set *s2)
 Return true if the sets overlap. More...
 
bool overleft_bigint_bigintset (int64 i, const Set *s)
 Return true if a value does not extend to the right of a set. More...
 
bool overleft_bigintset_bigint (const Set *s, int64 i)
 Return true if a set does not extend to the right of a value. More...
 
bool overleft_float_floatset (double d, const Set *s)
 Return true if a value does not extend to the right of a set. More...
 
bool overleft_floatset_float (const Set *s, double d)
 Return true if a set does not extend to the right of a value. More...
 
bool overleft_int_intset (int i, const Set *s)
 Return true if a value does not extend to the right of a set. More...
 
bool overleft_intset_int (const Set *s, int i)
 Return true if a set does not extend to the right of a value. More...
 
bool overleft_set_set (const Set *s1, const Set *s2)
 Return true if the first set does not extend to the right of the second one. More...
 
bool overleft_set_value (const Set *s, Datum d, meosType basetype)
 Return true if a set does not extend to the right of a value. More...
 
bool overleft_text_textset (text *txt, const Set *s)
 Return true if a value does not extend to the right of a set. More...
 
bool overleft_textset_text (const Set *s, text *txt)
 Return true if a set does not extend to the right of a value. More...
 
bool overleft_value_set (Datum d, meosType basetype, const Set *s)
 Return true if a value does not extend to the right of a set. More...
 
bool overright_bigint_bigintset (int64 i, const Set *s)
 Return true if a value does not extend to the the left of a set. More...
 
bool overright_bigintset_bigint (const Set *s, int64 i)
 Return true if a set does not extend to the left of a value. More...
 
bool overright_float_floatset (double d, const Set *s)
 Return true if a value does not extend to the the left of a set. More...
 
bool overright_floatset_float (const Set *s, double d)
 Return true if a set does not extend to the left of a value. More...
 
bool overright_int_intset (int i, const Set *s)
 Return true if a value does not extend to the the left of a set. More...
 
bool overright_intset_int (const Set *s, int i)
 Return true if a set does not extend to the left of a value. More...
 
bool overright_set_set (const Set *s1, const Set *s2)
 Return true if the first set does not extend to the left of the second one. More...
 
bool overright_set_value (const Set *s, Datum d, meosType basetype)
 Return true if a set does not extend to the left of a value. More...
 
bool overright_textset_text (const Set *s, text *txt)
 Return true if a set does not extend to the left of a value. More...
 
bool overright_value_set (Datum d, meosType basetype, const Set *s)
 Return true if a value does not extend to the the left of a set. More...
 
bool right_bigint_bigintset (int64 i, const Set *s)
 Return true if a value is strictly to the right of a span set. More...
 
bool right_bigintset_bigint (const Set *s, int64 i)
 Return true if a set is strictly to the right of a value. More...
 
bool right_float_floatset (double d, const Set *s)
 Return true if a value is strictly to the right of a span set. More...
 
bool right_floatset_float (const Set *s, double d)
 Return true if a set is strictly to the right of a value. More...
 
bool right_int_intset (int i, const Set *s)
 Return true if a value is strictly to the right of a span set. More...
 
bool right_intset_int (const Set *s, int i)
 Return true if a set is strictly to the right of a value. More...
 
bool right_set_set (const Set *s1, const Set *s2)
 Return true if the first set is strictly to the right of the second one. More...
 
bool right_set_value (const Set *s, Datum d, meosType basetype)
 Return true if a set is strictly to the right of a value. More...
 
bool right_text_textset (text *txt, const Set *s)
 Return true if a value is strictly to the right of a span set. More...
 
bool right_textset_text (const Set *s, text *txt)
 Return true if a set is strictly to the right of a value. More...
 
bool right_value_set (Datum d, meosType basetype, const Set *s)
 Return true if a value is strictly to the right of a set. More...
 
static Setsetop_set_set (const Set *s1, const Set *s2, SetOper setop)
 Return the union, intersection, or difference of two sets. More...
 
bool union_bigintset_bigint (const Set *s, int64 i)
 Return the union of a set and a value. More...
 
bool union_floatset_float (const Set *s, double d)
 Return the union of a set and a value. More...
 
bool union_intset_int (const Set *s, int i)
 Return the union of a set and a value. More...
 
Setunion_set_set (const Set *s1, const Set *s2)
 Return the union of two sets. More...
 
Setunion_set_value (const Set *s, Datum d, meosType basetype)
 Return the union of a value and a set. More...
 
bool union_textset_text (const Set *s, text *txt)
 Return the union of a set and a value. More...
 
Setunion_timestamp_timestampset (const TimestampTz t, const Set *ts)
 Return the union of a timestamp and a timestamp set. More...
 
Setunion_timestampset_timestamp (const Set *ts, const TimestampTz t)
 Return the union of a timestamp set and a timestamp. More...