Represents a subset of features. A FeatureCursor can be used to enumerate through
features in turn.
Syntax
| Visual Basic (Declaration) | |
|---|
<ComVisibleAttribute(False)>
Public NotInheritable Class FeatureCursor |
| C# | |
|---|
[ComVisibleAttribute(false)]
public sealed class FeatureCursor |
Example
An example of enumerating the features in a
LocalVectorLayer with a
FeatureCursor. This example assumes there is a variable MyLocalVectorLayer pointing to a
LocalVectorLayer (e.g. Shapefile).
| C# | Copy Code |
|---|
ESRI.ArcGIS.E2API.FeatureCursor MyFeatureCursor = MyLocalVectorLayer.SearchFeatures(null, string.Empty, esriE2SpatialRelationship.Undefined); ESRI.ArcGIS.E2API.Feature MyFeature = MyFeatureCursor.NextFeature(); do { System.Diagnostics.Debug.WriteLine(MyFeature.GetValueAsString(0)); MyFeature = MyFeatureCursor.NextFeature (); } while (MyFeature != null); |
| Visual Basic | Copy Code |
|---|
ESRI.ArcGIS.E2API.FeatureCursor MyFeatureCursor = MyLocalVectorLayer.SearchFeatures(Nothing,
String.Empty, esriE2SpatialRelationship.Undefined)
Dim MyFeature As ESRI.ArcGIS.E2API.Feature = MyFeatureCursor.NextFeature()
Do
System.Diagnostics.Debug.WriteLine(MyFeature.GetValueAsString(0))
MyFeature = MyFeatureCursor.NextFeature ()
Loop While Not MyFeature Is Nothing |
Inheritance Hierarchy
System.Object
ESRI.ArcGIS.E2API.FeatureCursor
Platforms
Version Information
This class was added to the E2API at version 1.0.0.348.
See Also