public boolean evaluate ( T t ) { // Start by assuming that the candidate will be a member of the predicate. boolean passed = true ; // Loop through all predicates and fail if any one of them does. for ( UnaryPredicate < T > predicate : chain ) { if ( ! predicate . evaluate ( t ) ) { passed = false ; break ; } } return passed ; }
Evaluates a logical predicate .