Package ddf.catalog.validation
Class ValidationException
java.lang.Object
java.lang.Throwable
java.lang.Exception
ddf.catalog.validation.ValidationException
- All Implemented Interfaces:
Serializable
Thrown to indicate that a validation operation could not be completed. Provides information in
the form of a summary message, a list of error messages, and a list of warnings.
- Author:
- Michael Menousek, Shaun Morris, Ashraf Barakat
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs aValidationExceptionwith no detailed message.ValidationException(String summaryMessage) Constructs aValidationExceptionwith a specified summary message of the failure.ValidationException(String summaryMessage, Throwable cause) Constructs aValidationExceptionwith a specified summary message and cause of the failure.ValidationException(Throwable cause) Constructs aValidationExceptionwith a cause of the failure. -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
Constructor Details
-
ValidationException
public ValidationException()Constructs aValidationExceptionwith no detailed message. -
ValidationException
Constructs aValidationExceptionwith a specified summary message of the failure.- Parameters:
summaryMessage- summarizes why the validation operation failed
-
ValidationException
Constructs aValidationExceptionwith a cause of the failure.- Parameters:
cause- the cause of why the validation operation failed
-
ValidationException
Constructs aValidationExceptionwith a specified summary message and cause of the failure.- Parameters:
summaryMessage- summarizes why the validation operation failedcause- the cause of why the validation operation failed
-
-
Method Details
-
getErrors
- Returns:
- a list of all error messages that have caused validation to fail. The error message should be human-readable plain text.
-
getWarnings
- Returns:
- a list of warning messages. Warning messages are issues that arose during validation but did not cause validation to fail. A warning message should be human-readable plain text.
-
toString
Converts this exception into a String representation.
-