Interface ValidationResults
- All Known Implementing Classes:
ModelValidationResultsImpl
public interface ValidationResults
Object in which the results of a model validation are collected.
See:
ModelInstance.validate(java.util.Collection).- Since:
- 7.6
- Author:
- Daniel Meyer
-
Method Summary
Modifier and TypeMethodDescriptionintintbooleanvoidwrite(StringWriter writer, ValidationResultFormatter formatter) Utility method to print out a summary of the validation results.voidwrite(StringWriter writer, ValidationResultFormatter formatter, int maxSize) Utility method to print out a summary of the validation results.
-
Method Details
-
hasErrors
boolean hasErrors()- Returns:
- true if there are
ValidationResultof typeValidationResultType.ERROR
-
getErrorCount
int getErrorCount()- Returns:
- the count of
ValidationResultof typeValidationResultType.ERROR
-
getWarinigCount
int getWarinigCount()- Returns:
- the count of
ValidationResultof typeValidationResultType.WARNING
-
getResults
Map<ModelElementInstance,List<ValidationResult>> getResults()- Returns:
- the individual results of the validation grouped by element.
-
write
Utility method to print out a summary of the validation results.- Parameters:
writer- aStringWriterto which the result should be printedformatter- formatter for printing elements and validation results
-
write
Utility method to print out a summary of the validation results.- Parameters:
writer- aStringWriterto which the result should be printedformatter- formatter for printing elements and validation resultsmaxSize- the maximum size (in bytes) that is allowed to be written to the writer
-