System.Collections.ObjectModel.ReadOnlyCollection<T> Class

Provides the base class for a generic read-only collection.

See Also: ReadOnlyCollection<T> Members

Syntax

[System.Diagnostics.DebuggerDisplay("Count={Count}")]
[System.Diagnostics.DebuggerTypeProxy(typeof(System.Collections.Generic.CollectionDebuggerView`1))]
[System.Runtime.InteropServices.ComVisible(false)]
public class ReadOnlyCollection<T> : ICollection<T>, IEnumerable<T>, IList<T>, IReadOnlyCollection<T>, IReadOnlyList<T>, IList

Type Parameters

T
Documentation for this section has not yet been entered.

Remarks

An instance of the System.Collections.ObjectModel.ReadOnlyCollection`1 generic class is always read-only. A collection that is read-only is simply a collection with a wrapper that prevents modifying the collection; therefore, if changes are made to the underlying collection, the read-only collection reflects those changes. See System.Collections.ObjectModel.Collection`1 for a modifiable version of this class.

Requirements

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