public List < String > toList ( ) { List < String > errorStrings = new ArrayList < String > ( ) ; ErrorIterator errIterator = iterator ( ) ; while ( errIterator . hasNext ( ) ) { ValidationError err = errIterator . next ( ) ; errorStrings . add ( err . getMessage ( ) ) ; } return errorStrings ; }
Returns a list of errors as strings .