public final class ImmutableMultipleValidationResult extends Object implements MultipleValidationResult
MultipleValidationResult.
Instances are to be created using the of(Iterable) factory method| Modifier and Type | Method and Description |
|---|---|
ValidationErrorType |
getErrorType()
Returns the error type associated to the result, if
ValidationResult.isError() is true. |
List<ValidationResult> |
getFailedValidationResults()
|
String |
getMessage()
Returns all the messages from the
MultipleValidationResult.getFailedValidationResults() which failed separated by a \n character |
boolean |
isError()
Whether the validation has failed or not
|
static MultipleValidationResult |
of(Iterable<ValidationResult> results)
A
Iterable with all the ValidationResult that were generated together, both failed and successful alike. |
public static MultipleValidationResult of(Iterable<ValidationResult> results)
Iterable with all the ValidationResult that were generated together, both failed and successful alike.results - the obtained ValidationResult objectsMultipleValidationResultpublic boolean isError()
isError in interface MultipleValidationResultisError in interface ValidationResulttrue if at least one of the MultipleValidationResult.getFailedValidationResults() is not empty. false otherwisepublic String getMessage()
MultipleValidationResult.getFailedValidationResults() which failed separated by a \n charactergetMessage in interface MultipleValidationResultgetMessage in interface ValidationResultString or nullpublic ValidationErrorType getErrorType()
ValidationResult.isError() is true.getErrorType in interface ValidationResultValidationErrorType or null if there was no errorpublic List<ValidationResult> getFailedValidationResults()
getFailedValidationResults in interface MultipleValidationResultValidationResultCopyright © 2017 MuleSoft, Inc.. All rights reserved.