PostGIS  2.3.7dev-r@@SVN_REVISION@@
static size_t gserialized_from_lwcollection_size ( const LWCOLLECTION col)
static

Definition at line 510 of file g_serialized.c.

References LWCOLLECTION::geoms, gserialized_from_any_size(), LWDEBUGF, and LWCOLLECTION::ngeoms.

Referenced by gserialized_from_any_size().

511 {
512  size_t size = 4; /* Type number. */
513  int i = 0;
514 
515  assert(col);
516 
517  size += 4; /* Number of sub-geometries (zero => empty). */
518 
519  for ( i = 0; i < col->ngeoms; i++ )
520  {
521  size_t subsize = gserialized_from_any_size(col->geoms[i]);
522  size += subsize;
523  LWDEBUGF(3, "lwcollection subgeom(%d) size = %d", i, subsize);
524  }
525 
526  LWDEBUGF(3, "lwcollection size = %d", size);
527 
528  return size;
529 }
LWGEOM ** geoms
Definition: liblwgeom.h:508
static size_t gserialized_from_any_size(const LWGEOM *geom)
Definition: g_serialized.c:531
#define LWDEBUGF(level, msg,...)
Definition: lwgeom_log.h:88

Here is the call graph for this function:

Here is the caller graph for this function: