GEOS  3.8.0dev
Public Member Functions | Static Public Member Functions | List of all members
geos::index::chain::MonotoneChainBuilder Class Reference

Constructs MonotoneChains for sequences of Coordinates. More...

#include <MonotoneChainBuilder.h>

Public Member Functions

 MonotoneChainBuilder (const MonotoneChainBuilder &)=delete
 
MonotoneChainBuilderoperator= (const MonotoneChainBuilder &)=delete
 

Static Public Member Functions

static std::unique_ptr
< std::vector< std::unique_ptr
< MonotoneChain > > > 
getChains (const geom::CoordinateSequence *pts, void *context)
 Return a newly-allocated vector of newly-allocated MonotoneChain objects for the given CoordinateSequence. More...
 
static void getChains (const geom::CoordinateSequence *pts, void *context, std::vector< std::unique_ptr< MonotoneChain >> &mcList)
 Fill the provided vector with newly-allocated MonotoneChain objects for the given CoordinateSequence. More...
 
static std::unique_ptr
< std::vector< std::unique_ptr
< MonotoneChain > > > 
getChains (const geom::CoordinateSequence *pts)
 
static void getChainStartIndices (const geom::CoordinateSequence &pts, std::vector< std::size_t > &startIndexList)
 Fill the given vector with start/end indexes of the monotone chains for the given CoordinateSequence. More...
 

Detailed Description

Constructs MonotoneChains for sequences of Coordinates.

TODO: use vector<const Coordinate*> instead ?

Constructor & Destructor Documentation

geos::index::chain::MonotoneChainBuilder::MonotoneChainBuilder ( const MonotoneChainBuilder )
delete

Disable copy construction and assignment. Apparently needed to make this class compile under MSVC. (See https://stackoverflow.com/q/29565299)

Member Function Documentation

static std::unique_ptr<std::vector<std::unique_ptr<MonotoneChain> > > geos::index::chain::MonotoneChainBuilder::getChains ( const geom::CoordinateSequence pts,
void *  context 
)
static

Return a newly-allocated vector of newly-allocated MonotoneChain objects for the given CoordinateSequence.

Note
Remember to deep-delete the result.
static void geos::index::chain::MonotoneChainBuilder::getChains ( const geom::CoordinateSequence pts,
void *  context,
std::vector< std::unique_ptr< MonotoneChain >> &  mcList 
)
static

Fill the provided vector with newly-allocated MonotoneChain objects for the given CoordinateSequence.

Note
Remember to delete vector elements!
static void geos::index::chain::MonotoneChainBuilder::getChainStartIndices ( const geom::CoordinateSequence pts,
std::vector< std::size_t > &  startIndexList 
)
static

Fill the given vector with start/end indexes of the monotone chains for the given CoordinateSequence.

The last entry in the array points to the end point of the point array, for use as a sentinel.


The documentation for this class was generated from the following file: