Inserts a new ring at the specified index containing the specified points.

Namespace:  ESRI.ArcGISExplorer.Geometry

Assembly:  ESRI.ArcGISExplorer (in ESRI.ArcGISExplorer.dll) Version: 2.0.0.1500 (2.0.0.1500)

Syntax

C#
public void InsertRing(
	int ringIndex,
	IEnumerable<Point> points
)
Visual Basic (Declaration)
Public Sub InsertRing ( _
	ringIndex As Integer, _
	points As IEnumerable(Of Point) _
)

Parameters

ringIndex
Type: System..::.Int32

The index of the new ring within the Polygon.
points
Type: System.Collections.Generic..::.IEnumerable<(Of <(Point>)>)

A generic enumerable set of Point objects to copy into the new ring within the Polygon.

Remarks

Use this method to insert a new ring containing a copy of the specified points at the specified index position in a Polygon. Any following existing rings in the Polygon will increase their index position by 1. This method can be used instead of separate calls to AddRing()()() and AddPoints(Int32, IEnumerable<(Of <(Point>)>)). If the ringIndex is equal to the number of rings, this method behaves like the AddRing(IEnumerable<(Of <(Point>)>)) method, copying the points in to a new ring after all existing rings.

Alternatively, use the [O:ESRI.ArcGISExplorer.Geometry.Polygon.InsertPoints]method to insert points in an existing ring, or [O:ESRI.ArcGISExplorer.Geometry.Polygon.AddRing] to add a new ring as the last ring in the Polygon.

Note that the CoordinateSystem property of any new points added, inserted or set into existing an existing Polygon or Polyline will be discarded, and the coordinates (X and Y properties) of the point assumed to be in the same CoordinateSystem as the Polygon or Polyline to which they are added.

Exceptions

ExceptionCondition
System..::.ArgumentOutOfRangeExceptionThe specified ringIndex must not be greater than the number of existing rings in Polygon.

See Also