[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]
Determines if the list contains any item that compares equal to item.
The implementation simply checks whether IndexOf(item) returns a non-negative value.
Namespace: Wintellect.PowerCollections
Assembly:
PowerCollections (in PowerCollections.dll)
Syntax
C# |
---|
public override bool Contains( T item ) |
Visual Basic (Declaration) |
---|
Public Overrides Function Contains ( _ item As T _ ) As Boolean |
Visual C++ |
---|
public: virtual bool Contains ( T item ) override |
Parameters
- item
- T
The item to search for.
Return Value
True if the list contains an item that compares equal to item.Remarks
Equality in the list is determined by the default sense of
equality for T. If T implements IComparable<T>, the
Equals method of that interface is used to determine equality. Otherwise,
Object.Equals is used to determine equality.
See Also
ListBase<(Of <T>)> Class
Wintellect.PowerCollections Namespace