TEnumerableBase<T>.Single(TPredicate<T>) Method

Returns the only element of a sequence, and throws an exception if there is not exactly one element in the sequence.

Namespace: Spring.Collections.Base
public
 function Single(const predicate: TPredicate<T>): T; overload;

Parameters

predicate
Type: TPredicate<T>

Return Value

Type: T

 

Implements

IEnumerable<T>.Single(TPredicate<T>)