34#ifndef __TYPE_PARSER_H__
35#define __TYPE_PARSER_H__
39#include "temporal/meos_catalog.h"
45extern bool p_delimchar(
const char **str,
char delim);
46extern bool p_obrace(
const char **str);
48extern bool p_cbrace(
const char **str);
52extern bool p_oparen(
const char **str);
54extern bool p_cparen(
const char **str);
56extern bool p_comma(
const char **str);
59extern bool double_parse(
const char **str,
double *result);
MeosType
Enumeration that defines the built-in and temporal types used in MobilityDB.
Definition: meos_catalog.h:55
interpType
Enumeration that defines the interpolation types used in MEOS.
Definition: meos.h:171
External API of the Mobility Engine Open Source (MEOS) library.
int64 TimestampTz
Definition: postgres_ext_defs.in.h:22
uintptr_t Datum
Definition: postgres_ext_defs.in.h:7
Structure to represent sets of values.
Definition: meos.h:90
Structure to represent span sets.
Definition: meos.h:118
Structure to represent spans (a.k.a.
Definition: meos.h:104
Structure to represent temporal boxes.
Definition: meos.h:134
Structure to represent temporal values of instant subtype.
Definition: meos.h:195
Structure to represent temporal values of sequence set subtype.
Definition: meos.h:234
Structure to represent temporal values of sequence subtype.
Definition: meos.h:212
Structure to represent the common structure of temporal values of any temporal subtype.
Definition: meos.h:183
bool p_oparen(const char **str)
Input an opening parenthesis from the buffer.
Definition: type_parser.c:193
bool ensure_oparen(const char **str, const char *type)
Ensure to input an opening parenthesis from the buffer.
Definition: type_parser.c:208
TBox * tbox_parse(const char **str)
Parse a temporal box value from the buffer.
Definition: type_parser.c:336
bool ensure_obrace(const char **str, const char *type)
Ensure to input an opening brace from the buffer.
Definition: type_parser.c:118
bool ensure_cbrace(const char **str, const char *type)
Ensure to input a closing brace from the buffer.
Definition: type_parser.c:148
TSequence * tcontseq_parse(const char **str, MeosType temptype, interpType interp, bool end)
Parse a temporal sequence value from the buffer.
Definition: type_parser.c:747
bool p_obrace(const char **str)
Input an opening brace from the buffer.
Definition: type_parser.c:103
bool p_comma(const char **str)
Input a comma from the buffer.
Definition: type_parser.c:253
bool double_parse(const char **str, double *result)
Input a double from the buffer.
Definition: type_parser.c:271
Set * set_parse(const char **str, MeosType basetype)
Parse a set value from the buffer.
Definition: type_parser.c:493
bool p_cparen(const char **str)
Input a closing parenthesis from the buffer.
Definition: type_parser.c:223
bool p_cbrace(const char **str)
Input a closing brace from the buffer.
Definition: type_parser.c:133
TInstant * tinstant_parse(const char **str, MeosType temptype, bool end)
Parse a temporal instant value from the buffer.
Definition: type_parser.c:667
bool basetype_parse(const char **str, MeosType basetypid, char delim, Datum *result)
Parse a base value from the buffer.
Definition: type_parser.c:290
bool elem_parse(const char **str, MeosType basetype, Datum *result)
Parse a element value from the buffer.
Definition: type_parser.c:457
Temporal * temporal_parse(const char **str, MeosType temptype)
Parse a temporal value from the buffer (dispatch function)
Definition: type_parser.c:856
bool p_delimchar(const char **str, char delim)
Input an opening brace from the buffer.
Definition: type_parser.c:88
TSequenceSet * tsequenceset_parse(const char **str, MeosType temptype, interpType interp)
Parse a temporal sequence set from the buffer.
Definition: type_parser.c:811
bool ensure_end_input(const char **str, const char *type)
Functions for parsing temporal types.
Definition: type_parser.c:61
bool ensure_cparen(const char **str, const char *type)
Ensure to input a closing parenthesis from the buffer.
Definition: type_parser.c:238
bool p_cbracket(const char **str)
Input a closing bracket from the buffer.
Definition: type_parser.c:178
TimestampTz timestamp_parse(const char **str)
Parse a timestamp value from the buffer.
Definition: type_parser.c:431
SpanSet * spanset_parse(const char **str, MeosType spantype)
Parse a span set value from the buffer.
Definition: type_parser.c:621
TSequence * tdiscseq_parse(const char **str, MeosType temptype)
Parse a temporal discrete sequence from the buffer.
Definition: type_parser.c:696
bool span_parse(const char **str, MeosType spantype, bool end, Span *span)
Parse a span value from the buffer.
Definition: type_parser.c:575
bool p_obracket(const char **str)
Input an opening bracket from the buffer.
Definition: type_parser.c:163
void p_whitespace(const char **str)
Input a white space from the buffer.
Definition: type_parser.c:77