Class LoggingValidationHandler
java.lang.Object
gov.nist.secauto.metaschema.cli.util.LoggingValidationHandler
-
Method Summary
Modifier and TypeMethodDescriptionvoid
handleValidationFindings
(List<? extends gov.nist.secauto.metaschema.core.model.validation.IValidationFinding> findings) Handle the provided collection of validation findings.boolean
handleValidationResults
(gov.nist.secauto.metaschema.core.model.validation.IValidationResult result) Handle the provided collection of validation results.static LoggingValidationHandler
instance()
Get a singleton instance of the logging validation handler.static LoggingValidationHandler
instance
(boolean logExceptions) Get a singleton instance of the logging validation handler.boolean
Determine if exceptions should be logged.
-
Method Details
-
instance
Get a singleton instance of the logging validation handler.This instance will not log exceptions.
- Returns:
- the instance
-
instance
Get a singleton instance of the logging validation handler.- Parameters:
logExceptions
-true
if this instance will log exceptions orfalse
otherwise- Returns:
- the instance
-
isLogExceptions
Determine if exceptions should be logged.- Returns:
true
if exceptions are logged orfalse
otherwise
-
handleValidationResults
public boolean handleValidationResults(gov.nist.secauto.metaschema.core.model.validation.IValidationResult result) Handle the provided collection of validation results.- Parameters:
result
- the validation results- Returns:
true
if the result is passing orfalse
otherwise
-
handleValidationFindings
public void handleValidationFindings(@NonNull List<? extends gov.nist.secauto.metaschema.core.model.validation.IValidationFinding> findings) Handle the provided collection of validation findings.- Parameters:
findings
- the findings to process
-