Collection Methods
Microsoft Silverlight will reach end of support after October 2021. Learn more.
Include Protected Members
Include Inherited Members
Include Silverlight Members
Include Silverlight for Windows Phone Members
Include XNA Framework Members
The Collection type exposes the following members.
Methods
Name | Description | |
---|---|---|
Add | Adds an element to a Collection object. | |
Clear | Deletes all elements of a Visual Basic Collection object. | |
Contains | Returns a Boolean value indicating whether a Visual Basic Collection object contains an element with a specific key. | |
Equals(Object) | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.) | |
GetEnumerator | Returns a reference to an enumerator object, which is used to iterate over a Collection object. | |
GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
Remove(Int32) | Removes an element from a Collection object. | |
Remove(String) | Removes an element from a Collection object. | |
ToString | Returns a string that represents the current object. (Inherited from Object.) |
Top
Extension Methods
Name | Description | |
---|---|---|
AsQueryable | Converts an IEnumerable to an IQueryable. (Defined by Queryable.) | |
Cast<TResult> | Converts the elements of an IEnumerable to the specified type. (Defined by Enumerable.) | |
OfType<TResult> | Filters the elements of an IEnumerable based on a specified type. (Defined by Enumerable.) |
Top
Explicit Interface Implementations
Name | Description | |
---|---|---|
ICollection.CopyTo | Copies the elements of the Collection to an Array, starting at a particular Array index. Implements the ICollection interface. | |
IEnumerable.GetEnumerator | Returns an enumerator that iterates through the collection. Implements the ICollection interface. | |
IList.Add | Adds an item to the Collection object. Implements the IList interface. | |
IList.Clear | Removes all items from the Collection object. Implements the IList interface. | |
IList.Contains | Determines whether the Collection object contains a specific value. Implements the IList interface. | |
IList.IndexOf | Determines the index of a specific item in the Collection object. Implements the IList interface. | |
IList.Insert | Inserts an item to the Collection object at the specified index. Implements the IList interface. | |
IList.Remove | Removes the first occurrence of a specific object from the Collection object. Implements the IList interface. | |
IList.RemoveAt | Removes the Collection object item at the specified index. Implements the IList interface. |
Top