PostGIS  3.0.6dev-r@@SVN_REVISION@@

◆ lwpointiterator_peek()

int lwpointiterator_peek ( LWPOINTITERATOR s,
POINT4D p 
)

Attempts to assigns the next point in the iterator to p.

Does not advance. Returns LW_SUCCESS if the assignment was successful, LW_FAILURE otherwise.

Definition at line 193 of file lwiterator.c.

194 {
196  return LW_FAILURE;
197 
198  return getPoint4d_p(s->pointarrays->item, s->i, p);
199 }
char * s
Definition: cu_in_wkt.c:23
#define LW_FAILURE
Definition: liblwgeom.h:110
int getPoint4d_p(const POINTARRAY *pa, uint32_t n, POINT4D *point)
Definition: lwgeom_api.c:125
int lwpointiterator_has_next(LWPOINTITERATOR *s)
Returns LW_TRUE if there is another point available in the iterator.
Definition: lwiterator.c:202

References getPoint4d_p(), LW_FAILURE, lwpointiterator_has_next(), and s.

Referenced by lwgeom_trim_bits_in_place(), lwpointiterator_next(), and test_mixed_rw_access().

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