Cut a geometry along a polyline.

Use case
You might cut a polygon representing a large parcel to subdivide it into smaller parcels.
How to use the sample
Tap the button to cut the polygon with the polyline and see the resulting parts (shaded in different colors).
How it works
- Pass a
Geometryand aPolylineto thestatic GeometryEngine.cut(_:usingCutter:)method to cut the geometry along the given polyline. - Loop through the returned list of part geometries. Some geometries may be multi-part.
- Create a
Graphicinstance from the part and add it to aGraphicsOverlay.
Relevant API
- Geometry
- GeometryEngine
- Graphic
- GraphicsOverlay
- Polygon
- Polyline
- static GeometryEngine.cut(_:usingCutter:)
Tags
cut, geometry, split