PostGIS 3.0.6dev-r@@SVN_REVISION@@
Loading...
Searching...
No Matches

◆ gserialized2_from_any_size()

static size_t gserialized2_from_any_size ( const LWGEOM geom)
static

Definition at line 772 of file gserialized2.c.

773{
774 LWDEBUGF(2, "Input type: %s", lwtype_name(geom->type));
775
776 switch (geom->type)
777 {
778 case POINTTYPE:
780 case LINETYPE:
782 case POLYGONTYPE:
784 case TRIANGLETYPE:
786 case CIRCSTRINGTYPE:
788 case CURVEPOLYTYPE:
789 case COMPOUNDTYPE:
790 case MULTIPOINTTYPE:
791 case MULTILINETYPE:
792 case MULTICURVETYPE:
793 case MULTIPOLYGONTYPE:
794 case MULTISURFACETYPE:
796 case TINTYPE:
797 case COLLECTIONTYPE:
799 default:
800 lwerror("Unknown geometry type: %d - %s", geom->type, lwtype_name(geom->type));
801 return 0;
802 }
803}
static size_t gserialized2_from_lwcircstring_size(const LWCIRCSTRING *curve)
static size_t gserialized2_from_lwpoly_size(const LWPOLY *poly)
static size_t gserialized2_from_lwpoint_size(const LWPOINT *point)
static size_t gserialized2_from_lwtriangle_size(const LWTRIANGLE *triangle)
static size_t gserialized2_from_lwcollection_size(const LWCOLLECTION *col)
static size_t gserialized2_from_lwline_size(const LWLINE *line)
const char * lwtype_name(uint8_t type)
Return the type name string associated with a type number (e.g.
Definition lwutil.c:216
#define COLLECTIONTYPE
Definition liblwgeom.h:122
#define COMPOUNDTYPE
Definition liblwgeom.h:124
#define CURVEPOLYTYPE
Definition liblwgeom.h:125
#define MULTILINETYPE
Definition liblwgeom.h:120
#define MULTISURFACETYPE
Definition liblwgeom.h:127
#define LINETYPE
Definition liblwgeom.h:117
#define MULTIPOINTTYPE
Definition liblwgeom.h:119
#define POINTTYPE
LWTYPE numbers, used internally by PostGIS.
Definition liblwgeom.h:116
#define TINTYPE
Definition liblwgeom.h:130
#define MULTIPOLYGONTYPE
Definition liblwgeom.h:121
#define POLYGONTYPE
Definition liblwgeom.h:118
#define POLYHEDRALSURFACETYPE
Definition liblwgeom.h:128
#define CIRCSTRINGTYPE
Definition liblwgeom.h:123
#define MULTICURVETYPE
Definition liblwgeom.h:126
#define TRIANGLETYPE
Definition liblwgeom.h:129
#define LWDEBUGF(level, msg,...)
Definition lwgeom_log.h:88
void lwerror(const char *fmt,...)
Write a notice out to the error handler.
Definition lwutil.c:190
uint8_t type
Definition liblwgeom.h:448

References CIRCSTRINGTYPE, COLLECTIONTYPE, COMPOUNDTYPE, CURVEPOLYTYPE, gserialized2_from_lwcircstring_size(), gserialized2_from_lwcollection_size(), gserialized2_from_lwline_size(), gserialized2_from_lwpoint_size(), gserialized2_from_lwpoly_size(), gserialized2_from_lwtriangle_size(), LINETYPE, LWDEBUGF, lwerror(), lwtype_name(), MULTICURVETYPE, MULTILINETYPE, MULTIPOINTTYPE, MULTIPOLYGONTYPE, MULTISURFACETYPE, POINTTYPE, POLYGONTYPE, POLYHEDRALSURFACETYPE, TINTYPE, TRIANGLETYPE, LWGEOM::type, and LWPOINT::type.

Referenced by gserialized2_from_lwcollection_size(), and gserialized2_from_lwgeom_size().

Here is the call graph for this function:
Here is the caller graph for this function: