tags:

views:

47

answers:

2

which is equivalent to

interface ISomeKindOfCompare<T>
{
    bool Matches(T item);
}

I know IComparer and IEqualityComparer and so on, but that's not what I am looking for.

+1  A: 

IComparable? IEquatable<T>?

Martin Harris
Is there nothing with a bool as return-type? It's not that important but I dislike the int return type for it solves my problem not as pure as possible.
Falcon
+2  A: 

IEquatable<T> looks the same as your ISomeKindOfCompare<T>. That is, it lets you ask "is this object equal to some T?".

Tim Robinson
thanks, that's it!
Falcon