Class ErrorsUtil


  • public final class ErrorsUtil
    extends java.lang.Object
    Utility to build an error message from a list of validations.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.String buildErrorMessage​(java.lang.String message, java.util.List<ValidationError> errors)
      Create an error message from a message and the list of errors.
      static java.lang.String buildErrorMessage​(java.util.List<ValidationError> errors)
      build an error message from a list of validations.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • buildErrorMessage

        public static java.lang.String buildErrorMessage​(java.lang.String message,
                                                         java.util.List<ValidationError> errors)
        Create an error message from a message and the list of errors.
        Parameters:
        message - to prepend the error
        errors - list of validation errors.
        Returns:
        string of the error
      • buildErrorMessage

        public static java.lang.String buildErrorMessage​(java.util.List<ValidationError> errors)
        build an error message from a list of validations.
        Parameters:
        errors - list of validation errors.
        Returns:
        string of the error