Class CollectionTally
- Namespace
- NUnit.Framework.Constraints
- Assembly
- nunit.framework.dll
CollectionTally counts (tallies) the number of occurrences of each object in one or more enumerations.
public sealed class CollectionTally
- Inheritance
-
CollectionTally
- Inherited Members
Constructors
CollectionTally(NUnitEqualityComparer, IEnumerable)
Construct a CollectionTally object from a comparer and a collection.
public CollectionTally(NUnitEqualityComparer comparer, IEnumerable c)
Parameters
comparer
NUnitEqualityComparerThe comparer to use for equality.
c
IEnumerableThe expected collection to compare against.
Properties
Result
The result of the comparison between the two collections.
public CollectionTally.CollectionTallyResult Result { get; }
Property Value
Methods
TryRemove(IEnumerable)
Try to remove a set of objects from the tally.
public void TryRemove(IEnumerable c)
Parameters
c
IEnumerableThe objects to remove.
TryRemove(object)
Try to remove an object from the tally.
public void TryRemove(object o)
Parameters
o
objectThe object to remove.