MobilityDB 1.3
Loading...
Searching...
No Matches
tpose.h
Go to the documentation of this file.
1/*****************************************************************************
2 *
3 * This MobilityDB code is provided under The PostgreSQL License.
4 * Copyright (c) 2016-2025, 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-2025, 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 __TPOSE_H__
35#define __TPOSE_H__
36
37#include "temporal/temporal.h"
38#include "pose/pose.h"
39
40/*****************************************************************************/
41
42/* Validity functions */
43
44extern bool ensure_valid_tpose_geo(const Temporal *temp,
45 const GSERIALIZED *gs);
46extern bool ensure_valid_tpose_pose(const Temporal *temp, const Pose *pose);
47extern bool ensure_valid_tpose_stbox(const Temporal *temp, const STBox *box);
48extern bool ensure_valid_tpose_tpose(const Temporal *temp1,
49 const Temporal *temp2);
50
51/* Interpolation functions */
52
53extern int tposesegm_intersection_value(Datum start, Datum end, Datum value,
54 TimestampTz lower, TimestampTz upper, TimestampTz *t1, TimestampTz *t2);
55extern int tposesegm_intersection(Datum start1, Datum end1, Datum start2,
56 Datum end2, TimestampTz lower, TimestampTz upper, TimestampTz *t1,
57 TimestampTz *t2);
58
59/*****************************************************************************/
60
61#endif /* __TPOSE_H__ */
int64 TimestampTz
Definition: postgres_ext_defs.in.h:22
uintptr_t Datum
Definition: postgres_ext_defs.in.h:7
Definition: postgis_ext_defs.in.h:170
Basic functions for static pose objects.
Definition: pose.h:56
Structure to represent spatiotemporal boxes.
Definition: meos.h:134
Structure to represent the common structure of temporal values of any temporal subtype.
Definition: meos.h:173
bool ensure_valid_tpose_pose(const Temporal *temp, const Pose *pose)
Ensure the validity of a temporal pose and a pose.
Definition: tpose.c:74
bool ensure_valid_tpose_tpose(const Temporal *temp1, const Temporal *temp2)
Ensure the validity of two temporal poses.
Definition: tpose.c:99
int tposesegm_intersection_value(Datum start, Datum end, Datum value, TimestampTz lower, TimestampTz upper, TimestampTz *t1, TimestampTz *t2)
Return 1 if a segment of a temporal pose value intersects a pose at the timestamp output in the last ...
Definition: tpose.c:121
bool ensure_valid_tpose_geo(const Temporal *temp, const GSERIALIZED *gs)
General functions for temporal pose objects.
Definition: tpose.c:62
bool ensure_valid_tpose_stbox(const Temporal *temp, const STBox *box)
Ensure the validity of a temporal pose and a spatiotemporal box.
Definition: tpose.c:86
int tposesegm_intersection(Datum start1, Datum end1, Datum start2, Datum end2, TimestampTz lower, TimestampTz upper, TimestampTz *t1, TimestampTz *t2)
int const GSERIALIZED * gs
Definition: trgeo_spatialrels.h:52