Functions

DsePolygonIterator *

dse_polygon_iterator_new

( )

Creates a new polygon iterator.

Returns:
Type Details
DsePolygonIterator *

Returns an iterator that must be freed.

See Also:
void

dse_polygon_iterator_free

( DsePolygonIterator * iterator )

Frees a polygon iterator instance.

Parameters:
Name Type Details
in iterator DsePolygonIterator *
CassError

dse_polygon_iterator_reset

( DsePolygonIterator * iterator, const CassValue * value )

Resets a polygon iterator so that it can be reused to process a binary representation.

Parameters:
Name Type Details
in iterator DsePolygonIterator *

the iterator to reset

in value const CassValue *

binary representation of the polygon

Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

dse_polygon_iterator_reset_with_wkt

( DsePolygonIterator * iterator, const char * wkt )

Resets a polygon iterator so that it can be reused to parse WKT.

Parameters:
Name Type Details
in iterator DsePolygonIterator *

the iterator to reset

in wkt const char *

WKT representation of the polygon

Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

dse_polygon_iterator_reset_with_wkt_n

( DsePolygonIterator * iterator, const char * wkt, size_t wkt_length )

Same as DsePolygonIterator::dse_polygon_iterator_reset_with_wkt, but with lengths for string parameters.

Parameters:
Name Type Details
in iterator DsePolygonIterator *

the iterator to reset

in wkt const char *

WKT representation (string) of the polygon

in wkt_length size_t

length of wkt string

Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

cass_uint32_t

dse_polygon_iterator_num_rings

( const DsePolygonIterator * iterator )

Gets the number rings in the polygon.

Parameters:
Name Type Details
in iterator const DsePolygonIterator *
Returns:
Type Details
cass_uint32_t

The number of rings in the polygon.

CassError

dse_polygon_iterator_next_num_points

( DsePolygonIterator * iterator, cass_uint32_t * num_points )

Gets the number of points for the current ring.

Parameters:
Name Type Details
in iterator DsePolygonIterator *
out num_points cass_uint32_t *
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

dse_polygon_iterator_next_point

( DsePolygonIterator * iterator, cass_double_t * x, cass_double_t * y )

Gets the next point in the current ring.

Parameters:
Name Type Details
in iterator DsePolygonIterator *
out x cass_double_t *
out y cass_double_t *
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.