ArcGIS Pro 2.8 API Reference Guide
Reshape Method (IGeometryEngine)
Example 

ArcGIS.Core.Geometry Namespace > IGeometryEngine Interface : Reshape Method
The geometry to be reshaped.
The reshaper.
Reshapes a polygon or polyline with a single path polyline.
Syntax

Parameters

multipart
The geometry to be reshaped.
reshaper
The reshaper.

Return Value

The reshaped multipart geometry.
Exceptions
ExceptionDescription
Either multipartor reshaperor both are null or empty.
Incompatible spatial references between the input geometries.
The reshaper polyline must have exactly one part.
Remarks
The output geometry takes the shape of the input multipart where it first intersects the reshaper to the last intersection. The first and last intersection points of the reshaper are chosen closest to the end points of the reshaper in the case that multiple intersections are found. The output geometry may not be simple. If the geometry cannot be reshaped by the input reshaper, then null will be returned.
Example
List<Coordinate2D> polygon1Coords = new List<Coordinate2D>()
{
  new Coordinate2D(0, -11000),
  new Coordinate2D(1000, -11000),
  new Coordinate2D(1000, -12000),
  new Coordinate2D(0, -12000),
  new Coordinate2D(0, -11000)
};

// reshaper coordinates intersect the polygon
List<Coordinate2D> reshaperCoords = new List<Coordinate2D>()
{
  new Coordinate2D(1500, -11800),
  new Coordinate2D(-2600, -11800)
};

SpatialReference sr = SpatialReferenceBuilder.CreateSpatialReference(102010);
Polygon polygon1 = PolygonBuilder.CreatePolygon(polygon1Coords, sr);
Polyline reshaper = PolylineBuilder.CreatePolyline(reshaperCoords, sr);

Polygon outPolygon = GeometryEngine.Instance.Reshape(polygon1, reshaper) as Polygon;
// outPolygon.PartCount = 1

ReadOnlySegmentCollection segments = outPolygon.Parts[0];
// segments.Count = 4
// outPolygon.PointCount = 5

string json = GeometryEngine.Instance.ExportToJSON(JSONExportFlags.jsonExportSkipCRS, outPolygon);
// json = "{\"rings\":[[[0,-11800],[0,-11000],[1000,-11000],[1000,-11800],[0,-11800]]]}";


// example where the Reshaper polyline doesn't intersect the input

reshaperCoords.Clear();
reshaperCoords.Add(new Coordinate2D(1000, 1000));
reshaperCoords.Add(new Coordinate2D(2000, 1000));

reshaper = PolylineBuilder.CreatePolyline(reshaperCoords, sr);

outPolygon = GeometryEngine.Instance.Reshape(polygon1, reshaper) as Polygon;
// outPolygon = null
Requirements

Target Platforms: Windows 10, Windows 8.1

See Also

Reference

IGeometryEngine Interface
IGeometryEngine Members