Array.TrueForAll(Of T) Method
[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]
Determines whether every element in the array matches the conditions defined by the specified predicate.
Assembly: mscorlib (in mscorlib.dll)
'Declaration Public Shared Function TrueForAll(Of T) ( _ array As T(), _ match As Predicate(Of T) _ ) As Boolean
The type of the elements of the array.
The one-dimensional, zero-based Array to check against the conditions
Return ValueType: System.Boolean
true if every element in array matches the conditions defined by the specified predicate; otherwise, false. If there are no elements in the array, the return value is true.
The Predicate(Of T) is a delegate to a method that returns true if the object passed to it matches the conditions defined in the delegate. The elements of array are individually passed to the Predicate(Of T), and processing is stopped when the delegate returns false for any element.
This method is an O(n) operation, where n is the Length of array.