Mono Class Library: System.Collections.Generic.ICollection<T> Overview | Members

System.Collections.Generic.ICollection<T>.Clear Method

Removes all items from the current collection.

public void Clear ()

Exceptions

TypeReason
NotSupportedExceptionThe current collection is read-only.

Remarks

ICollection<T>.Count is set to zero.

Requirements

Namespace: System.Collections.Generic
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0