Returns an unmodifiable view of the specified IDictionary.
This method allows modules to provide users with "read-only" access to internal dictionary.
Query operations on the returned dictionary "read through" to the specified dictionary,
and attempts to modify the returned dictionary,
whether direct or via its collection views, result in an NotSupportedException.
Namespace: NHibernate.UtilAssembly: NHibernate (in NHibernate.dll) Version: 3.2.0.4000 (3.2.0.4000)
Syntax
C# |
---|
[SerializableAttribute] public class UnmodifiableDictionary<TKey, TValue> : IDictionary<TKey, TValue>, ICollection<KeyValuePair<TKey, TValue>>, IEnumerable<KeyValuePair<TKey, TValue>>, IEnumerable |
Visual Basic |
---|
<SerializableAttribute> _ Public Class UnmodifiableDictionary(Of TKey, TValue) _ Implements IDictionary(Of TKey, TValue), ICollection(Of KeyValuePair(Of TKey, TValue)), _ IEnumerable(Of KeyValuePair(Of TKey, TValue)), IEnumerable |
Visual C++ |
---|
[SerializableAttribute] generic<typename TKey, typename TValue> public ref class UnmodifiableDictionary : IDictionary<TKey, TValue>, ICollection<KeyValuePair<TKey, TValue>>, IEnumerable<KeyValuePair<TKey, TValue>>, IEnumerable |
Type Parameters
- TKey
- The type of keys in the dictionary.
- TValue
- The type of values in the dictionary.