Class UserException

    • Constructor Detail

      • UserException

        public UserException​(UserException.ExceptionCategory category,
                             java.lang.String message)
        Creates a new user exception with the specified message and category.
        Parameters:
        message - the exception message
        category - the exception category
      • UserException

        public UserException​(UserException.ExceptionCategory category,
                             java.lang.Throwable cause)
        Creates a new user exception with the specified cause and category.
        Parameters:
        cause - the exception that caused this exception
        category - the exception category
      • UserException

        public UserException​(UserException.ExceptionCategory category,
                             java.lang.String message,
                             java.lang.Throwable cause)
        Creates a new user exception with the specified message, cause and category.
        Parameters:
        message - the exception message
        cause - the exception that caused this exception
        category - the exception category
      • UserException

        public UserException​(DataValidationInfo dvInfo)
        Create a new UserException (data validation).
        Parameters:
        dvInfo - the data validation info.
    • Method Detail

      • getDataValidationFeedback

        public DataValidationInfo getDataValidationFeedback()
        Returns data validation info, containing validation errors.
        Returns:
        the data validation info
      • fillInStackTrace

        public java.lang.Throwable fillInStackTrace()
        Prevents this exception from generating a stack trace. Makes the creation of this exception 10 times faster!
        Overrides:
        fillInStackTrace in class java.lang.Throwable
      • toString

        public java.lang.String toString()
        Returns ether the exception message, or data validation errors if they are present.
        Overrides:
        toString in class java.lang.Throwable
        Returns:
        data validation errors if they are present, or the exception message otherwise