ArcObjects Library Reference (Geometry)  

IEnumSegment Interface

Provides access to members that iterate over collections of segments (obtained from the EnumSegments property on the ISegmentCollection interface).

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Description

The methods on IEnumSegment interface can be used to access segments of a segment collection. Those methods are more efficient than the ISegmentCollection methods to access a large number of segments in a sequential order for polyline and polygon. The collection methods transform absolute segment index into a part relative index, enumerators don't.

Members

Description
Method Clone Returns a copy of this enumerator positioned at the same segment.
Method IsLastInPart Indicates if the current segment is last in the current part.
Read-only property IsRecycling Indicates if this enumerator re-uses the same segment each time next is called.
Method Next Returns the next segment, and its location in the collection. If the location does not have parts (i.e. a path or ring) then the part index will always be zero.
Method NextEx Populates a segment info structure with information on the next segment in the collection.
Method NextInPart Returns the next segment in current part, goes back to first segment after last segment in part is encountered.
Method NextInPartEx Returns the next segment info structure in current part, goes back to first segment after last segment in part is encountered.
Method Previous Returns the previous segment in this segment collection.
Method Reset Starts from the beginning of the segment collection the next time Next is called.
Method ResetToEnd Starts from the end of the path, ring, polyline or polygon the next time Previous is called.
Method SetAt Resets enumerator to specific location.
Method Skip Skips forward or backward over a specified number of segments.

.NET Related Topics

How to add point IDs to a polyline | How to create a multipart polyline | How to use the IEnumSegment methods