Interface ISet

Namespace
ESRI.ArcGIS.esriSystem
Assembly
ESRI.Server.System.dll

Provides access to members that control a simple set of objects.

[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("33848E02-983B-11D1-8463-0000F875B9C6")]
public interface ISet

Properties

Count

The element count of the set.

int Count { get; }

Property Value

int

Methods

Add(object)

Adds an object to the set.

void Add(object unk)

Parameters

unk object

Remarks

The order in which objects are added to the Set using Add is not guaranteed to be the same order in which they are returned by the Next method.

When adding an object to a Set, you are merely adding a new reference to the object not copying it. The reference is released when the Set is destroyed or the object is removed. For example, if you add geodatabase features to a Set (or an Array) using a feature cursor, you must use a non-recycling cursor, otherwise the memory location of the previous feature is overwritten.

Find(object)

Searches for the object in the set.

bool Find(object unk)

Parameters

unk object

Returns

bool

Next()

Obtains the next object in the set.

object Next()

Returns

object

Remarks

The order that objects are returned from the Set object using the Next method is not guaranteed to be the same order as they were passed into the Add method.  However, the Next method will return the objects in the same order.

Remove(object)

Removes the object from the set.

void Remove(object unk)

Parameters

unk object

RemoveAll()

Removes all objects from the set.

void RemoveAll()

Reset()

Resets the set for enumerating through the objects with Next.

void Reset()

Remarks

The order that objects are returned from the Set object using the Next method is not guaranteed to be the same order as they were passed into the Add method.  However, the Next method will return the objects in the same order.