Friday, August 27, 2010

System.Predicates

(http://msdn.microsoft.com/en-us/magazine/cc163550.aspx)
Formally, the .NET Framework documentation defines the System.Predicate delegate like this:

public delegate bool Predicate( T obj )

In real life, this definition indicates that a function that acts as a predicate must take a single value as its parameter, which must be of the same type as the data in the array or list it's working with, and must return a Boolean value. The return value indicates whether the value passed to the procedure meets your particular criteria for inclusion

Example
List.Find Method have parameter Find(Predicate)

No comments: