MobilityDB 1.3
Loading...
Searching...
No Matches
Functions
trgeo_spatialrels.c File Reference

Ever/always spatial relationships for temporal rigid geometries. More...

#include <assert.h>
#include <meos.h>
#include <meos_rgeo.h>
#include <meos_internal.h>
#include "temporal/lifting.h"
#include "geo/postgis_funcs.h"
#include "geo/tgeo_spatialfuncs.h"
#include "geo/tgeo_spatialrels.h"
#include "rgeo/trgeo.h"
#include "rgeo/trgeo_spatialfuncs.h"

Functions

int acontains_geo_trgeo (const GSERIALIZED *gs, const Temporal *temp)
 Return 1 if a geometry always contains a temporal rigid geometry, 0 if not, and -1 on error or if the geometry is empty. More...
 
int acovers_geo_trgeo (const GSERIALIZED *gs, const Temporal *temp)
 Return 1 if a geometry always covers a temporal geometry, 0 if not, and -1 on error or if the geometry is empty. More...
 
int acovers_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs)
 Return 1 if a temporal geometry always covers a geometry, 0 if not, and -1 on error or if the geometry is empty. More...
 
int adisjoint_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs)
 Return 1 if a temporal rigid geometry and a geometry are always disjoint,0 if not, and -1 on error or if the geometry is empty. More...
 
int adisjoint_trgeo_trgeo (const Temporal *temp1, const Temporal *temp2)
 Return 1 if the temporal rigid geometries are always disjoint, 0 if not, and -1 on error or if the temporal rigid geometries do not intersect in time. More...
 
int adwithin_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs, double dist)
 Return 1 if a geometry and a temporal rigid geometry are always within a distance, 0 if not, -1 on error or if the geometry is empty. More...
 
int adwithin_trgeo_trgeo (const Temporal *temp1, const Temporal *temp2, double dist)
 Return 1 if two temporal rigid geometries are always within a distance, 0 if not, -1 on error or if the temporal rigid geometries do not intersect on time. More...
 
int aintersects_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs)
 Return 1 if a geometry and a temporal rigid geometry always intersect, 0 if not, and -1 on error or if the geometry is empty. More...
 
int aintersects_trgeo_trgeo (const Temporal *temp1, const Temporal *temp2)
 Return 1 if the temporal rigid geometries always intersect, 0 if not, and -1 on error or if the temporal rigid geometries do not intersect in time. More...
 
int atouches_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs)
 Return 1 if a temporal rigid geometry and a geometry always touch, 0 if not, and -1 on error or if the geometry is empty. More...
 
int ea_contains_geo_trgeo (const GSERIALIZED *gs, const Temporal *temp, bool ever)
 Return 1 if a geometry ever contains a temporal rigid geometry, 0 if not, and -1 on error or if the geometry is empty. More...
 
int ea_covers_geo_trgeo (const GSERIALIZED *gs, const Temporal *temp, bool ever)
 Return 1 if a geometry ever covers a temporal geometry, 0 if not, and -1 on error or if the geometry is empty. More...
 
int ea_covers_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs, bool ever)
 Return 1 if a geometry ever covers a temporal geometry, 0 if not, and -1 on error or if the geometry is empty. More...
 
int ea_disjoint_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs, bool ever)
 Return 1 if a temporal rigid geometry and a geometry are ever disjoint,0 if not, and -1 on error or if the geometry is empty. More...
 
int ea_dwithin_trgeo_trgeo (const Temporal *temp1, const Temporal *temp2, double dist, bool ever)
 Return 1 if two temporal rigid geometries are ever within a distance, 0 if not, -1 on error or if the temporal rigid geometries do not intersect on time. More...
 
int ea_dwithin_trgeo_trgeo_sync (const Temporal *sync1, const Temporal *sync2, double dist, bool ever)
 Return 1 if two temporal rigid geometries are ever within a distance, 0 if not, -1 if the temporal rigid geometries do not intersect on time. More...
 
static bool ea_dwithin_trgeoinst_trgeoinst (const TInstant *inst1, const TInstant *inst2, double dist)
 Return true if the temporal rigid geometries are ever within a distance. More...
 
static bool ea_dwithin_trgeoseq_trgeoseq_cont (const TSequence *seq1, const TSequence *seq2, double dist, bool ever)
 Return true if two temporal rigid geometries are ever within a distance. More...
 
static bool ea_dwithin_trgeoseq_trgeoseq_discstep (const TSequence *seq1, const TSequence *seq2, double dist, bool ever)
 Return true if two temporal rigid geometries are ever within a distance. More...
 
static bool ea_dwithin_trgeoseqset_trgeoseqset (const TSequenceSet *ss1, const TSequenceSet *ss2, double dist, bool ever)
 Return true if two temporal rigid geometries are ever within a distance. More...
 
int econtains_geo_trgeo (const GSERIALIZED *gs, const Temporal *temp)
 Return 1 if a geometry ever contains a temporal rigid geometry, 0 if not, and -1 on error or if the geometry is empty. More...
 
int ecovers_geo_trgeo (const GSERIALIZED *gs, const Temporal *temp)
 Return 1 if a geometry ever covers a temporal geometry, 0 if not, and -1 on error or if the geometry is empty. More...
 
int ecovers_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs)
 Return 1 if a geometry ever covers a temporal geometry, 0 if not, and -1 on error or if the geometry is empty. More...
 
int edisjoint_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs)
 Return 1 if a temporal rigid geometry and a geometry are ever disjoint, 0 if not, and -1 on error or if the geometry is empty. More...
 
int edisjoint_trgeo_trgeo (const Temporal *temp1, const Temporal *temp2)
 Return 1 if the temporal rigid geometries are ever disjoint, 0 if not, and -1 on error or if the temporal rigid geometries do not intersect in time. More...
 
int edwithin_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs, double dist)
 Return 1 if a geometry and a temporal rigid geometry are ever within the given distance, 0 if not, -1 on error or if the geometry is empty. More...
 
int edwithin_trgeo_trgeo (const Temporal *temp1, const Temporal *temp2, double dist)
 Return 1 if two temporal rigid geometries are ever within a distance, 0 if not, -1 on error or if the temporal rigid geometries do not intersect on time. More...
 
int eintersects_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs)
 Return 1 if a geometry and a temporal rigid geometry ever intersect, 0 if not, and -1 on error or if the geometry is empty. More...
 
int eintersects_trgeo_trgeo (const Temporal *temp1, const Temporal *temp2)
 Return 1 if the temporal rigid geometries ever intersect, 0 if not, and -1 on error or if the temporal rigid geometries do not intersect in time. More...
 
int etouches_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs)
 Return 1 if a temporal rigid geometry and a geometry ever touch, 0 if not, and -1 on error or if the geometry is empty. More...
 
static int spatialrel_trgeo_geo (const Temporal *temp, const GSERIALIZED *gs, Datum param, varfunc func, int numparam, bool invert)
 Generic spatial relationship for the traversed area of a temporal rigid geometry and a geometry. More...
 
int spatialrel_trgeo_trav_geo (const Temporal *temp, const GSERIALIZED *gs, Datum param, varfunc func, int numparam, bool invert)
 Generic spatial relationship for the traversed area of a temporal rigid geometry and a geometry. More...
 
int tdwithin_trgeosegm_trgeosegm (Datum sv1 UNUSED, Datum ev1 UNUSED, Datum sv2 UNUSED, Datum ev2 UNUSED, TimestampTz lower UNUSED, TimestampTz upper UNUSED, double dist UNUSED, TimestampTz *t1 UNUSED, TimestampTz *t2 UNUSED)
 Return the timestamps at which EITHER the segments of the two temporal points OR a segment of a temporal point and a point are within a distance. More...
 

Detailed Description

Ever/always spatial relationships for temporal rigid geometries.

These relationships compute the ever/always spatial relationship between the arguments and return a Boolean. These functions may be used for filtering purposes before applying the corresponding spatiotemporal relationship.

The following relationships are supported: contains, disjoint, intersects, touches, and dwithin.