Definition at line 89 of file lwgeom_debug.c.
90{
91 size_t size = 128;
93 char *tmp;
94 uint32_t i;
95 static char *nl = "\n";
96 char *pad="";
98
99 LWDEBUG(2,
"lwcollection_summary called");
100
102
103 snprintf(
result, size,
"%*.s%s[%s] with %d element%s",
105 zmflags,
108 ( col->
ngeoms > 1 ?
"s:\n" :
":\n")
109 : "s");
110
111 for (i=0; i<col->
ngeoms; i++)
112 {
114 size += strlen(tmp)+1;
116
117 LWDEBUGF(4,
"Reallocated %d bytes for result", size);
118 if ( i > 0 ) strcat(
result,nl);
119
122 }
123
124 LWDEBUG(3,
"lwcollection_summary returning");
125
127}
char result[OUT_DOUBLE_BUFFER_SIZE]
const char * lwtype_name(uint8_t type)
Return the type name string associated with a type number (e.g.
void * lwrealloc(void *mem, size_t size)
void * lwalloc(size_t size)
static char * lwgeom_flagchars(LWGEOM *lwg)
char * lwgeom_summary(const LWGEOM *lwgeom, int offset)
#define LWDEBUG(level, msg)
#define LWDEBUGF(level, msg,...)
References LWCOLLECTION::geoms, lwalloc(), LWDEBUG, LWDEBUGF, lwfree(), lwgeom_flagchars(), lwgeom_summary(), lwrealloc(), lwtype_name(), LWCOLLECTION::ngeoms, result, and LWCOLLECTION::type.
Referenced by lwgeom_summary().