/** * @return <code>true</code> if there any global errors related to this form. */ public boolean hasGlobalErrors() { return !globalErrors().isEmpty(); }
/** * @return <code>true</code> if there any global errors related to this form. */ public boolean hasGlobalErrors() { return !globalErrors().isEmpty(); }
/** * @return <code>true</code> if there any global errors related to this form. */ public boolean hasGlobalErrors() { return !globalErrors().isEmpty(); }
/** * Retrieves the first global error (an error without any key), if it exists. * * @return An error. */ public Optional<ValidationError> globalError() { return globalErrors().stream().findFirst(); }
/** * Retrieves the first global error (an error without any key), if it exists. * * @return An error. */ public Optional<ValidationError> globalError() { return globalErrors().stream().findFirst(); }
/** * Retrieves the first global error (an error without any key), if it exists. * * @return An error. */ public Optional<ValidationError> globalError() { return globalErrors().stream().findFirst(); }
/** * Retrieves the first global error (an error without any key), if it exists. * * @return An error or <code>null</code>. */ public ValidationError globalError() { List<ValidationError> errors = globalErrors(); if(errors.isEmpty()) { return null; } else { return errors.get(0); } }
/** * Retrieves the first global error (an error without any key), if it exists. * * @return An error or <code>null</code>. */ public ValidationError globalError() { List<ValidationError> errors = globalErrors(); if(errors.isEmpty()) { return null; } else { return errors.get(0); } }