IVsaItems Interface
Defines an interface for a collection of IVsaItem objects, which can be addressed either by name or by index.
public: __interface IVsaItems : IEnumerable;
public interface IVsaItems : IEnumerable;
Public Interface IVsaItems, IEnumerable
Properties
The following table shows the properties of the IVsaItems interface.
Property |
Description |
---|---|
Gets the number of items in the specified collection. |
|
Gets an item from the collection by its index value. |
|
Gets an item from the collection by its name. |
Methods
The following table shows the methods of the IVsaItems interface.
Method |
Description |
---|---|
Creates a new instance of one of the IVsaItem types, as defined in the VsaItemType enumeration. |
|
Removes an item from the collection, as specified by its index value. |
|
Removes an item from the collection, as specified by its name. |
Remarks
While not a true collection in the sense that it does not derive from the ICollection or IDictionary interfaces, the IVsaItems interface nevertheless serves functionally as a collection, while accommodating special semantic requirements for adding items.
Items in an IVsaItems collection can be addressed either by name, or by index; furthermore, they can be enumerated with constructs such as For Each...Next. As they are 0-based, valid indexes extend from 0 to n - 1, where n is the value of the IVsaItems.Count property. However, an item's index value will not necessarily remain constant; it will change as the collection itself changes. For example, an item that is at index position 3 may move to index position 2 if the item at index position 2 is removed.
The IVsaItems interface inherits from IEnumerable.
Use the IVsaItems interface when creating a collection of IVsaItem objects for a script engine.
Requirements
DLL: Microsoft.Vsa.dll