98{
100 text *xml_input;
102 char *xml;
104 int xml_size;
105
106
107 if (PG_ARGISNULL(0)) PG_RETURN_NULL();
108 xml_input = PG_GETARG_TEXT_P(0);
109 xml = text_to_cstring(xml_input);
110 xml_size = VARSIZE_ANY_EXHDR(xml_input);
111
112
113 root_srid = PG_GETARG_INT32(1);
114
117 lwgeom->
srid = root_srid;
118
119 geom = geometry_serialize(lwgeom);
121
122 PG_RETURN_POINTER(geom);
123}
void lwgeom_free(LWGEOM *geom)
#define SRID_UNKNOWN
Unknown SRID value.
static LWGEOM * lwgeom_from_gml(const char *wkt, int xml_size)
Read GML.