PostGIS  2.5.7dev-r@@SVN_REVISION@@

◆ lwtype_is_collection()

int lwtype_is_collection ( uint8_t  type)

Determine whether a type number is a collection or not.

Determine whether a type number is a collection or not.

it is a MULTI* or COMPOUNDCURVE

Definition at line 1093 of file lwgeom.c.

1094 {
1095 
1096  switch (type)
1097  {
1098  case MULTIPOINTTYPE:
1099  case MULTILINETYPE:
1100  case MULTIPOLYGONTYPE:
1101  case COLLECTIONTYPE:
1102  case CURVEPOLYTYPE:
1103  case COMPOUNDTYPE:
1104  case MULTICURVETYPE:
1105  case MULTISURFACETYPE:
1106  case POLYHEDRALSURFACETYPE:
1107  case TINTYPE:
1108  return LW_TRUE;
1109  break;
1110 
1111  default:
1112  return LW_FALSE;
1113  }
1114 }
#define LW_FALSE
Definition: liblwgeom.h:77
#define COLLECTIONTYPE
Definition: liblwgeom.h:91
#define COMPOUNDTYPE
Definition: liblwgeom.h:93
#define CURVEPOLYTYPE
Definition: liblwgeom.h:94
#define MULTILINETYPE
Definition: liblwgeom.h:89
#define MULTISURFACETYPE
Definition: liblwgeom.h:96
#define MULTIPOINTTYPE
Definition: liblwgeom.h:88
#define TINTYPE
Definition: liblwgeom.h:99
#define MULTIPOLYGONTYPE
Definition: liblwgeom.h:90
#define POLYHEDRALSURFACETYPE
Definition: liblwgeom.h:97
#define MULTICURVETYPE
Definition: liblwgeom.h:95
#define LW_TRUE
Return types for functions with status returns.
Definition: liblwgeom.h:76
type
Definition: ovdump.py:41

References COLLECTIONTYPE, COMPOUNDTYPE, CURVEPOLYTYPE, LW_FALSE, LW_TRUE, MULTICURVETYPE, MULTILINETYPE, MULTIPOINTTYPE, MULTIPOLYGONTYPE, MULTISURFACETYPE, POLYHEDRALSURFACETYPE, TINTYPE, and ovdump::type.

Referenced by circ_node_internal_new(), circ_tree_distance_tree_internal(), getTableInfo(), gserialized_is_empty_recurse(), lwcollection_construct(), lwcollection_construct_empty(), lwcollection_extract(), lwgeom_covers_lwgeom_sphere(), lwgeom_distance_spheroid(), lwgeom_is_collection(), lwgeom_length_spheroid(), lwgeom_nudge_geodetic(), ST_IsCollection(), and wkt_parser_set_dims().

Here is the caller graph for this function: