@ Override public boolean evaluate ( FieldManager fieldManager , IndentPrinter printer ) { Comparable fieldValue = fieldManager . getValue ( fieldName ) ; for ( ConditionalTest test : conditionalTests ) { boolean result = test . operator . apply ( fieldValue , test . parameter ) ; printer . print ( "- %s => %b" , test . operator . description ( fieldManager . getDescription ( fieldName ) , fieldValue , test . parameter ) , result ) ; if ( ! result ) { return false ; } } return true ; }
The test in this conditional clause are implicitly ANDed together so return false if any of them is false and continue the loop for each test that is true ;