GEOS  3.14.0dev
Public Member Functions | Static Public Member Functions | List of all members
geos::geom::util::PolygonExtracter Class Reference

#include <PolygonExtracter.h>

Inheritance diagram for geos::geom::util::PolygonExtracter:
geos::geom::GeometryFilter

Public Member Functions

 PolygonExtracter (std::vector< const Polygon * > &newComps)
 
void filter_rw (Geometry *geom) override
 
void filter_ro (const Geometry *geom) override
 

Static Public Member Functions

static void getPolygons (const Geometry &geom, std::vector< const Polygon * > &ret)
 

Detailed Description

Extracts all the 2-dimensional (Polygon) components from a Geometry.

Constructor & Destructor Documentation

◆ PolygonExtracter()

geos::geom::util::PolygonExtracter::PolygonExtracter ( std::vector< const Polygon * > &  newComps)

Constructs a PolygonExtracterFilter with a list in which to store Polygons found.

Member Function Documentation

◆ getPolygons()

static void geos::geom::util::PolygonExtracter::getPolygons ( const Geometry geom,
std::vector< const Polygon * > &  ret 
)
static

Pushes the Polygon components from a single geometry into the provided vector. If more than one geometry is to be processed, it is more efficient to create a single PolygonExtracterFilter instance and pass it to multiple geometries.


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