Class NonGenericDictionary
Namespace: Aspose.Imaging
Assembly: Aspose.Imaging.dll (25.2.0)
Represents a non generic dictionary.
public class NonGenericDictionary : IDictionary, ICollection, IEnumerable
Inheritance
Implements
IDictionary, ICollection, IEnumerable
Inherited Members
object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Constructors
NonGenericDictionary(IDictionary)
Initializes a new instance of the Aspose.Imaging.NonGenericDictionary class.
public NonGenericDictionary(IDictionary dictionary)
Parameters
dictionary
IDictionary
The dictionary to use.
Fields
Dictionary
The actual dictionary used.
protected readonly IDictionary Dictionary
Field Value
Properties
Count
Gets the number of elements contained in the System.Collections.ICollection.
public int Count { get; }
Property Value
IsFixedSize
Gets a value indicating whether the System.Collections.IDictionary object has a fixed size.
public bool IsFixedSize { get; }
Property Value
IsReadOnly
Gets a value indicating whether the System.Collections.IDictionary object is read-only.
public bool IsReadOnly { get; }
Property Value
IsSynchronized
Gets a value indicating whether access to the System.Collections.ICollection is synchronized (thread safe).
public bool IsSynchronized { get; }
Property Value
Keys
Gets an System.Collections.ICollection object containing the keys of the System.Collections.IDictionary object.
public ICollection Keys { get; }
Property Value
SyncRoot
Gets an object that can be used to synchronize access to the System.Collections.ICollection.
public object SyncRoot { get; }
Property Value
Values
Gets an System.Collections.ICollection object containing the values in the System.Collections.IDictionary object.
public ICollection Values { get; }
Property Value
this[object]
Gets or sets the element with the specified key.
public object this[object key] { get; set; }
Property Value
Methods
Add(object, object)
Adds an element with the provided key and value to the System.Collections.IDictionary object.
public void Add(object key, object value)
Parameters
key
object
The System.Object to use as the key of the element to add.
value
object
The System.Object to use as the value of the element to add.
Clear()
Removes all elements from the System.Collections.IDictionary object.
public void Clear()
Contains(object)
Determines whether the System.Collections.IDictionary object contains an element with the specified key.
public bool Contains(object key)
Parameters
key
object
The key to locate in the System.Collections.IDictionary object.
Returns
true if the System.Collections.IDictionary contains an element with the key; otherwise, false.
CopyTo(Array, int)
Copies the elements of the System.Collections.ICollection to an System.Array, starting at a particular System.Array index.
public void CopyTo(Array array, int index)
Parameters
array
Array
The one-dimensional System.Array that is the destination of the elements copied from System.Collections.ICollection. The System.Array must have zero-based indexing.
index
int
The zero-based index in
array
at which copying begins.
GetEnumerator()
Gets the enumerator.
public IDictionaryEnumerator GetEnumerator()
Returns
The dictionary enumerator
Remove(object)
Removes the element with the specified key from the System.Collections.IDictionary object.
public void Remove(object key)
Parameters
key
object
The key of the element to remove.