NameObjectCollection Class

Similarly to a NameValueCollection, this class represents a collection of associated String keys and Object values that can be accessed either with the name or with the index.

Definition

Namespace: DevCase.Runtime.Collections
Assembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[SerializableAttribute]
public class NameObjectCollection : NameObjectCollectionBase
Inheritance
Object    NameObjectCollectionBase    NameObjectCollection

Constructors

NameObjectCollection Initializes a new instance of the NameObjectCollection class that is empty, has the default initial capacity and uses the default case-insensitive hash code provider and the default case-insensitive comparer.
NameObjectCollection(IEqualityComparer) Initializes a new instance of the NameObjectCollection class that is empty, has the default initial capacity, and uses the specified IEqualityComparer object.
NameObjectCollection(Int32) Initializes a new instance of the NameObjectCollection class that is empty, has the specified initial capacity and uses the default case-insensitive hash code provider and the default case-insensitive comparer.
NameObjectCollection(IHashCodeProvider, IComparer) Initializes a new instance of the NameObjectCollection class that is empty, has the specified initial capacity and uses the specified hash code provider and the specified comparer.
Obsolete.
NameObjectCollection(Int32, NameObjectCollection) Copies the entries from the specified NameObjectCollection to a new NameObjectCollection with the specified initial capacity or the same initial capacity as the number of entries copied, whichever is greater, and using the default case-insensitive hash code provider and the default case-insensitive comparer.
NameObjectCollection(Int32, IEqualityComparer) Initializes a new instance of the NameObjectCollection class that is empty, has the specified initial capacity, and uses the specified IEqualityComparer object.
NameObjectCollection(Int32, IHashCodeProvider, IComparer) Initializes a new instance of the NameObjectCollection class that is empty, has the specified initial capacity and uses the specified hash code provider and the specified comparer.
Obsolete.

Properties

AllKeys Gets all the keys in this NameObjectCollection.
Count Gets the number of key/value pairs contained in the NameObjectCollectionBase instance.
(Inherited from NameObjectCollectionBase)
ItemInt32 Gets the entry at the specified index of this NameObjectCollection.
ItemString Gets or sets the entry with the specified key in this NameObjectCollection.
Keys Gets a NameObjectCollectionBaseKeysCollection instance that contains all the keys in the NameObjectCollectionBase instance.
(Inherited from NameObjectCollectionBase)

Methods

Add(NameObjectCollection) Copies the entries in the specified NameObjectCollection to the current NameObjectCollection.
Add(String, Object) Adds an entry with the specified name and value to this NameObjectCollection.
Clear Invalidates the cached arrays and removes all entries from this NameObjectCollection.
CopyTo Copies the entire NameObjectCollection to a compatible one-dimensional Array, starting at the specified index of the target array.
Equals Determines whether the specified object is equal to the current object.
(Inherited from Object)
Get(Int32) Gets the values at the specified index of this NameObjectCollection combined into one comma-separated list.
Get(String) Gets the values associated with the specified key from this NameObjectCollection combined into one comma-separated list.
GetEnumerator Returns an enumerator that iterates through the NameObjectCollectionBase.
(Inherited from NameObjectCollectionBase)
GetHashCode Serves as the default hash function.
(Inherited from Object)
GetKey Gets the key at the specified index of this NameObjectCollection.
GetObjectData Implements the ISerializable interface and returns the data needed to serialize the NameObjectCollectionBase instance.
(Inherited from NameObjectCollectionBase)
GetType Gets the Type of the current instance.
(Inherited from Object)
GetValues(Int32) Gets the values at the specified index of this NameObjectCollection.
GetValues(String) Gets the values associated with the specified key from this NameObjectCollection.
HasKeys Gets a value indicating whether this NameObjectCollection contains keys that are not null.
OnDeserialization Implements the ISerializable interface and raises the deserialization event when the deserialization is complete.
(Inherited from NameObjectCollectionBase)
Remove Removes the entries with the specified key from this NameObjectCollection instance.
Set Sets the value of an entry in this NameObjectCollection.
ToString Returns a string that represents the current object.
(Inherited from Object)

Extension Methods

CanConvertTo Determines whether the source object can be converted to the specified target type.
(Defined by ObjectExtensions)
CanConvertToT Determines whether the source object can be converted to the specified target type.
(Defined by ObjectExtensions)
ConvertToT Converts an object to the specified target type.

If the conversion fails, an exception is thrown.
(Defined by ObjectExtensions)

ConvertToT Converts an object to the specified target type.

If the conversion fails, returns the specified default value.
(Defined by ObjectExtensions)

IsDisposable Determines whether the specified object is a disposable type (i.e., it implements IDisposable interface).
(Defined by ObjectExtensions)
Speak Speaks the string representation of the source object by using the operating system integrated text-to-speech synthesizer.
(Defined by ObjectExtensions)
Speak Speaks the string representation of the source object by using the operating system integrated text-to-speech synthesizer.
(Defined by ObjectExtensions)
ThrowIfNullTException Throws the specified exception if the source object is null.
(Defined by ObjectExtensions)

See Also