Class ReadOnlyPart
Represents an single part of an multipart geometry (polygon or polyline).
Inheritance
Implements
Namespace: Esri.ArcGISRuntime.Geometry
Assembly: Esri.ArcGISRuntime.dll
Syntax
public class ReadOnlyPart : IReadOnlyList<Segment>, IReadOnlyCollection<Segment>, IEnumerable<Segment>, IEnumerable
Remarks
A collection of Segment objects that together represent a part in a Multipart geometry. You can also access the MapPoint objects that represent the vertices of the geometry (that is, the ends of each segment), using point-based helpers such as Points.
Prior to v100.12, the only supported segment type was LineSegment. If the underlying geometry contained curve segments (HasCurves is true) then the curve information was lost when iterating through the segments in that part.
From v100.12, curve segments may be returned from Esri.ArcGISRuntime.Geometry.ReadOnlyPart.Segments. A part may contain a mix of linear and curve segments.
Properties
Name | Description |
---|---|
Count | Gets the count of segments in the part. |
EndPoint | Gets the end point of the last segment in the part, or |
HasCurves | Gets a value indicating whether the part has any curves. |
IsEmpty | Gets a value indicating whether the part contains no segments. |
Item[Int32] | Gets or sets the element at the specified index. |
PointCount | Gets the count of points in the part. |
Points | Gets a collection of all points that are vertexes of the part. |
SegmentCount | Gets the count of segments in the part. |
SpatialReference | Gets the spatial reference for the immutable part, or |
StartPoint | Gets the start point of the first segment in the part, or |
Methods
Name | Description |
---|---|
GetEndPointIndexFromSegmentIndex(Int32) | For a segment at a specified segment_index the method returns the point index of the segment's end point. |
GetEnumerator() | Returns an enumerator that iterates through the collection. |
GetSegmentIndexFromEndPointIndex(Int32) | Converts from a point index to a segment index that uses the given point as an end point. If the point is not an end point then a value equivalent to -1 value is returned. |
GetSegmentIndexFromPointIndex(Int32, out Int32, out Int32) | Converts from a point index to a segment index of the start point and another segment index containing the end point. If the point is not a start or end point a value equivalent to -1 is set. |
GetSegmentIndexFromStartPointIndex(Int32) | Converts from a point index to a segment index that uses the given point as a start point. If the point is not a start point then a value equivalent to -1 value is returned. |
GetStartPointIndexFromSegmentIndex(Int32) | For a segment at a specified segment_index the method returns the point index of the segment's start point. |
Name | Description |
---|---|
IEnumerable.GetEnumerator() | Returns an enumerator that iterates through a collection. |
Applies to
Target | Versions |
---|---|
.NET Standard 2.0 | 100.3 - 200.5 |
.NET | 100.13 - 200.5 |
.NET Windows | 100.13 - 200.5 |
.NET Android | 200.0 - 200.5 |
.NET iOS | 200.0 - 200.5 |
.NET Framework | 100.0 - 200.5 |
Xamarin.Android | 100.0 - 100.15 |
Xamarin.iOS | 100.0 - 100.15 |
UWP | 100.0 - 200.5 |