Click or drag to resize

UniqueList<T> Class

Provides a faster way to store individual objects both maintaining the order that they were added and providing a fast lookup. Based on code developed by ewbi at http://ewbi.blogs.com/develops/2010/10/uniquestringlis.html
Inheritance Hierarchy
System.Object
  SD.LLBLGen.Pro.ORMSupportClasses.UniqueList<T>
    SD.LLBLGen.Pro.ORMSupportClasses.UniqueValueList<T>

Namespace:  SD.LLBLGen.Pro.ORMSupportClasses
Assembly:  SD.LLBLGen.Pro.ORMSupportClasses (in SD.LLBLGen.Pro.ORMSupportClasses.dll) Version: 5.12.0.0 (5.12.0)
Syntax
[SerializableAttribute]
public class UniqueList<T> : IList<T>, 
	ICollection<T>, IEnumerable<T>, IEnumerable

Type Parameters

T
the type of the elements contained in the uniquelist.

The UniqueList<T> type exposes the following members.

Constructors
Properties
  NameDescription
Public propertyCount
Gets the number of elements contained in the ICollection<T>.
Public propertyIsReadOnly
Gets a value indicating whether the ICollection<T> is read-only.
Public propertyItem
Gets or sets the instance at the specified index.
Top
Methods
  NameDescription
Public methodAdd
Adds the specified item.
Public methodAddOrGet
Adds the item or if it's already present it gets its instance
Public methodClear
Removes all items from the ICollection<T>.
Public methodContains
Determines whether the ICollection<T> contains a specific value.
Public methodCopyTo
Copies the elements of the ICollection<T> to an Array, starting at a particular Array index.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetEnumerator
Returns an enumerator that iterates through the collection.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodIndexOf
Determines the index of a specific item in the IList<T>.
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Explicit Interface Implementations
  NameDescription
Explicit interface implementationPrivate methodICollection<T>.Add
Adds an item to the ICollection<T>.
Explicit interface implementationPrivate methodIEnumerable.GetEnumerator
Returns an enumerator that iterates through a collection.
Explicit interface implementationPrivate methodIList<T>.Insert
Inserts an item to the IList<T> at the specified index.
Explicit interface implementationPrivate methodICollection<T>.Remove
Removes the first occurrence of a specific object from the ICollection<T>.
Explicit interface implementationPrivate methodIList<T>.RemoveAt
Removes the IList<T> item at the specified index.
Top
See Also