MobilityDB 1.1
tpoint_spatialrels.h
Go to the documentation of this file.
1/*****************************************************************************
2 *
3 * This MobilityDB code is provided under The PostgreSQL License.
4 * Copyright (c) 2016-2023, Université libre de Bruxelles and MobilityDB
5 * contributors
6 *
7 * MobilityDB includes portions of PostGIS version 3 source code released
8 * under the GNU General Public License (GPLv2 or later).
9 * Copyright (c) 2001-2023, PostGIS contributors
10 *
11 * Permission to use, copy, modify, and distribute this software and its
12 * documentation for any purpose, without fee, and without a written
13 * agreement is hereby granted, provided that the above copyright notice and
14 * this paragraph and the following two paragraphs appear in all copies.
15 *
16 * IN NO EVENT SHALL UNIVERSITE LIBRE DE BRUXELLES BE LIABLE TO ANY PARTY FOR
17 * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, INCLUDING
18 * LOST PROFITS, ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION,
19 * EVEN IF UNIVERSITE LIBRE DE BRUXELLES HAS BEEN ADVISED OF THE POSSIBILITY
20 * OF SUCH DAMAGE.
21 *
22 * UNIVERSITE LIBRE DE BRUXELLES SPECIFICALLY DISCLAIMS ANY WARRANTIES,
23 * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
24 * AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON
25 * AN "AS IS" BASIS, AND UNIVERSITE LIBRE DE BRUXELLES HAS NO OBLIGATIONS TO
26 * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. 
27 *
28 *****************************************************************************/
29
34#ifndef __TPOINT_SPATIALRELS_H__
35#define __TPOINT_SPATIALRELS_H__
36
37/* PostgreSQL */
38#include <postgres.h>
39/* MEOS */
40#include "general/temporal.h"
41
42/*****************************************************************************/
43
44extern Datum geom_contains(Datum geom1, Datum geom2);
45extern Datum geom_disjoint2d(Datum geom1, Datum geom2);
46extern Datum geom_disjoint3d(Datum geom1, Datum geom2);
47extern Datum geog_disjoint(Datum geog1, Datum geog2);
48extern Datum geom_intersects2d(Datum geom1, Datum geom2);
49extern Datum geom_intersects3d(Datum geom1, Datum geom2);
50extern Datum geog_intersects(Datum geog1, Datum geog2);
51extern Datum geom_touches(Datum geom1, Datum geom2);
52extern Datum geom_dwithin2d(Datum geom1, Datum geom2, Datum dist);
53extern Datum geom_dwithin3d(Datum geom1, Datum geom2, Datum dist);
54extern Datum geog_dwithin(Datum geog1, Datum geog2, Datum dist);
55
56extern datum_func3 get_dwithin_fn(int16 flags1, int16 flags2);
57
58/*****************************************************************************/
59
60extern int espatialrel_tpoint_tpoint(const Temporal *temp1,
61 const Temporal *temp2, Datum (*func)(Datum, Datum));
62
63extern int edwithin_tpoint_tpoint1(const Temporal *sync1, const Temporal *sync2,
64 double dist);
65
66/*****************************************************************************/
67
68#endif
signed short int16
Functions for building a cache of temporal types and operators.
Definition: meos_catalog.h:41
Datum(* datum_func3)(Datum, Datum, Datum)
Definition: temporal.h:368
uintptr_t Datum
Definition: pg_ext_defs.in.h:4
Structure to represent the common structure of temporal values of any temporal subtype.
Definition: meos.h:136
Datum geog_dwithin(Datum geog1, Datum geog2, Datum dist)
Call the PostGIS function ST_DWithin for geographies with the 3 arguments.
Definition: tpoint_spatialrels.c:167
Datum geom_intersects3d(Datum geom1, Datum geom2)
Call the PostGIS function ST_3DIntersects with the 2 arguments.
Definition: tpoint_spatialrels.c:117
Datum geog_disjoint(Datum geog1, Datum geog2)
Call the PostGIS function ST_Intersects for geographies with the 2 arguments.
Definition: tpoint_spatialrels.c:98
Datum geom_intersects2d(Datum geom1, Datum geom2)
Call the PostGIS function ST_Intersects with the 2 arguments.
Definition: tpoint_spatialrels.c:107
Datum geom_dwithin2d(Datum geom1, Datum geom2, Datum dist)
Call the PostGIS function ST_DWithin with the 3 arguments.
Definition: tpoint_spatialrels.c:147
int edwithin_tpoint_tpoint1(const Temporal *sync1, const Temporal *sync2, double dist)
Return 1 if the temporal points are ever within the given distance, 0 if not, -1 if the temporal poin...
Definition: tpoint_spatialrels.c:649
Datum geom_disjoint2d(Datum geom1, Datum geom2)
Call the PostGIS function ST_Intersects with the 2 arguments and negate the result.
Definition: tpoint_spatialrels.c:79
int espatialrel_tpoint_tpoint(const Temporal *temp1, const Temporal *temp2, Datum(*func)(Datum, Datum))
Return true if the temporal points ever satisfy the spatial relationship.
Definition: tpoint_spatialrels.c:282
datum_func3 get_dwithin_fn(int16 flags1, int16 flags2)
Select the appropriate dwithin function for two MobilityDB types.
Definition: tpoint_spatialrels.c:214
Datum geom_touches(Datum geom1, Datum geom2)
Call the PostGIS function ST_Touches with the 2 arguments.
Definition: tpoint_spatialrels.c:137
Datum geom_disjoint3d(Datum geom1, Datum geom2)
Call the PostGIS function ST_Intersects3D with the 2 arguments and negates the result.
Definition: tpoint_spatialrels.c:89
Datum geom_contains(Datum geom1, Datum geom2)
Spatial relationships for temporal points.
Definition: tpoint_spatialrels.c:68
Datum geog_intersects(Datum geog1, Datum geog2)
Call the PostGIS function ST_Intersects for geographies with the 2 arguments.
Definition: tpoint_spatialrels.c:127
Datum geom_dwithin3d(Datum geom1, Datum geom2, Datum dist)
Call the PostGIS function ST_3DDWithin with the 3 arguments.
Definition: tpoint_spatialrels.c:157