MobilityDB 1.1
tnpoint_distance.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 __TNPOINT_DISTANCE_H__
35#define __TNPOINT_DISTANCE_H__
36
37/* PostgreSQL */
38#include <postgres.h>
39/* MEOS */
40#include "general/temporal.h"
41#include "npoint/tnpoint_static.h"
42
43/*****************************************************************************/
44
45extern Temporal *distance_tnpoint_geo(const Temporal *temp,
46 const GSERIALIZED *geo);
47extern Temporal *distance_tnpoint_npoint(const Temporal *temp,
48 const Npoint *np);
49extern Temporal *distance_tnpoint_tnpoint(const Temporal *temp1,
50 const Temporal *temp2);
51
52extern TInstant *nai_tnpoint_geo(const Temporal *temp, const GSERIALIZED *geo);
53extern TInstant *nai_tnpoint_npoint(const Temporal *temp, const Npoint *np);
54extern TInstant *nai_tnpoint_tnpoint(const Temporal *temp,
55 const Temporal *temp2);
56
57extern double nad_tnpoint_geo(const Temporal *temp, const GSERIALIZED *geo);
58extern double nad_tnpoint_npoint(const Temporal *temp, const Npoint *np);
59extern double nad_tnpoint_tnpoint(const Temporal *temp1,
60 const Temporal *temp2);
61
62extern bool shortestline_tnpoint_geo(const Temporal *temp,
63 const GSERIALIZED *geo, GSERIALIZED **result);
65 const Npoint *np);
66extern bool shortestline_tnpoint_tnpoint(const Temporal *temp1,
67 const Temporal *temp2, GSERIALIZED **result);
68
69/*****************************************************************************/
70
71#endif /* __TNPOINT_DISTANCE_H__ */
Definition: postgis_ext_defs.in.h:139
Functions for temporal network points.
Definition: tnpoint.h:50
Structure to represent temporal values of instant subtype.
Definition: meos.h:148
Structure to represent the common structure of temporal values of any temporal subtype.
Definition: meos.h:136
Temporal * distance_tnpoint_npoint(const Temporal *temp, const Npoint *np)
Return the temporal distance between the temporal network point and the network point.
Definition: tnpoint_distance.c:76
TInstant * nai_tnpoint_tnpoint(const Temporal *temp, const Temporal *temp2)
Return the nearest approach instant of the two temporal network points.
Definition: tnpoint_distance.c:155
GSERIALIZED * shortestline_tnpoint_npoint(const Temporal *temp, const Npoint *np)
Return the line connecting the nearest approach point between the network point and the temporal netw...
Definition: tnpoint_distance.c:247
double nad_tnpoint_geo(const Temporal *temp, const GSERIALIZED *geo)
Return the nearest approach distance of the temporal network point and the geometry.
Definition: tnpoint_distance.c:181
bool shortestline_tnpoint_geo(const Temporal *temp, const GSERIALIZED *geo, GSERIALIZED **result)
Return the line connecting the nearest approach point between the geometry and the temporal network p...
Definition: tnpoint_distance.c:231
double nad_tnpoint_npoint(const Temporal *temp, const Npoint *np)
Return the nearest approach distance of the temporal network point and the network point.
Definition: tnpoint_distance.c:197
Temporal * distance_tnpoint_geo(const Temporal *temp, const GSERIALIZED *geo)
Temporal distance for temporal network points.
Definition: tnpoint_distance.c:60
Temporal * distance_tnpoint_tnpoint(const Temporal *temp1, const Temporal *temp2)
Return the temporal distance between the two temporal network points.
Definition: tnpoint_distance.c:89
bool shortestline_tnpoint_tnpoint(const Temporal *temp1, const Temporal *temp2, GSERIALIZED **result)
Return the line connecting the nearest approach point between the two temporal networks.
Definition: tnpoint_distance.c:262
TInstant * nai_tnpoint_geo(const Temporal *temp, const GSERIALIZED *geo)
Return the nearest approach instant of the temporal network point and the geometry.
Definition: tnpoint_distance.c:114
double nad_tnpoint_tnpoint(const Temporal *temp1, const Temporal *temp2)
Return the nearest approach distance of the two temporal network points.
Definition: tnpoint_distance.c:213
TInstant * nai_tnpoint_npoint(const Temporal *temp, const Npoint *np)
Return the nearest approach instant of the network point and the temporal network point.
Definition: tnpoint_distance.c:135