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:161
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:80
Structure to represent span sets.
Definition: meos.h:108
Structure to represent spans (a.k.a.
Definition: meos.h:94
Structure to represent temporal boxes.
Definition: meos.h:124
Structure to represent temporal values of instant subtype.
Definition: meos.h:185
Structure to represent temporal values of sequence set subtype.
Definition: meos.h:224
Structure to represent temporal values of sequence subtype.
Definition: meos.h:202
Structure to represent the common structure of temporal values of any temporal subtype.
Definition: meos.h:173
bool p_oparen(const char **str)
Input an opening parenthesis from the buffer.
Definition: type_parser.c:188
bool ensure_oparen(const char **str, const char *type)
Ensure to input an opening parenthesis from the buffer.
Definition: type_parser.c:203
TBox * tbox_parse(const char **str)
Parse a temporal box value from the buffer.
Definition: type_parser.c:331
bool ensure_obrace(const char **str, const char *type)
Ensure to input an opening brace from the buffer.
Definition: type_parser.c:113
bool elem_parse(const char **str, meosType basetype, Datum *result)
Parse a element value from the buffer.
Definition: type_parser.c:452
bool ensure_cbrace(const char **str, const char *type)
Ensure to input a closing brace from the buffer.
Definition: type_parser.c:143
Set * set_parse(const char **str, meosType basetype)
Parse a set value from the buffer.
Definition: type_parser.c:488
bool p_obrace(const char **str)
Input an opening brace from the buffer.
Definition: type_parser.c:98
bool p_comma(const char **str)
Input a comma from the buffer.
Definition: type_parser.c:248
bool double_parse(const char **str, double *result)
Input a double from the buffer.
Definition: type_parser.c:266
bool tinstant_parse(const char **str, meosType temptype, bool end, TInstant **result)
Parse a temporal instant value from the buffer.
Definition: type_parser.c:664
bool tcontseq_parse(const char **str, meosType temptype, interpType interp, bool end, TSequence **result)
Parse a temporal sequence value from the buffer.
Definition: type_parser.c:741
TSequence * tdiscseq_parse(const char **str, meosType temptype)
Parse a temporal discrete sequence from the buffer.
Definition: type_parser.c:695
bool basetype_parse(const char **str, meosType basetypid, char delim, Datum *result)
Parse a base value from the buffer.
Definition: type_parser.c:285
bool p_cparen(const char **str)
Input a closing parenthesis from the buffer.
Definition: type_parser.c:218
SpanSet * spanset_parse(const char **str, meosType spantype)
Parse a span set value from the buffer.
Definition: type_parser.c:618
bool p_cbrace(const char **str)
Input a closing brace from the buffer.
Definition: type_parser.c:128
TSequenceSet * tsequenceset_parse(const char **str, meosType temptype, interpType interp)
Parse a temporal sequence set from the buffer.
Definition: type_parser.c:804
Temporal * temporal_parse(const char **str, meosType temptype)
Parse a temporal value from the buffer (dispatch function)
Definition: type_parser.c:845
bool p_delimchar(const char **str, char delim)
Input an opening brace from the buffer.
Definition: type_parser.c:83
bool ensure_end_input(const char **str, const char *type)
Functions for parsing temporal types.
Definition: type_parser.c:56
bool ensure_cparen(const char **str, const char *type)
Ensure to input a closing parenthesis from the buffer.
Definition: type_parser.c:233
bool span_parse(const char **str, meosType spantype, bool end, Span *span)
Parse a span value from the buffer.
Definition: type_parser.c:572
bool p_cbracket(const char **str)
Input a closing bracket from the buffer.
Definition: type_parser.c:173
TimestampTz timestamp_parse(const char **str)
Parse a timestamp value from the buffer.
Definition: type_parser.c:426
bool p_obracket(const char **str)
Input an opening bracket from the buffer.
Definition: type_parser.c:158
void p_whitespace(const char **str)
Input a white space from the buffer.
Definition: type_parser.c:72