Class SchemaModelValidatorImpl
java.lang.Object
ch.tocco.nice2.model.entity.impl.schema.SchemaModelValidatorImpl
- All Implemented Interfaces:
SchemaModelValidator
Executes the
SchemaModelValidatorTask in the backround. If the task
is already running a reference to the future is returned.-
Nested Class Summary
Nested classes/interfaces inherited from interface ch.tocco.nice2.model.entity.api.schema.SchemaModelValidator
SchemaModelValidator.Result -
Constructor Summary
ConstructorsConstructorDescriptionSchemaModelValidatorImpl(org.slf4j.Logger log, ThreadHandlerManager threadHandlerManager, DataModel dataModel, MetaDataRegistry metaDataRegistry, Metamodel metamodel) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddProgress(ValidationProgress progress) Adds aValidationProgressto the list of global progress callbacks.voidaddReporter(Reporter reporter) Adds aReporterto the global list of reporters.com.google.common.util.concurrent.ListenableFuture<SchemaModelValidator.Result> checkDataModel(ValidationProgress validationProgress, Reporter reporter) Starts validating the entity model against the database.booleanCheck if the validation is currently in progress.voidremoveProgress(ValidationProgress progress) voidremoveReporter(Reporter reporter) voidsetEntityChecks(List<SchemaCheck> entityChecks) voidsetIgnoredTables(List<String> ignoredTables) voidsetProgresses(List<ValidationProgress> progresses) voidsetReporters(List<Reporter> reporters)
-
Constructor Details
-
SchemaModelValidatorImpl
public SchemaModelValidatorImpl(org.slf4j.Logger log, ThreadHandlerManager threadHandlerManager, DataModel dataModel, MetaDataRegistry metaDataRegistry, @Lazy Metamodel metamodel)
-
-
Method Details
-
setIgnoredTables
-
checkDataModel
public com.google.common.util.concurrent.ListenableFuture<SchemaModelValidator.Result> checkDataModel(ValidationProgress validationProgress, Reporter reporter) Description copied from interface:SchemaModelValidatorStarts validating the entity model against the database. If already running, this just returns the future representing the currently running validation task. In this case the givenprogressCallbackandadditionalReporterarguments are not taken into account.- Specified by:
checkDataModelin interfaceSchemaModelValidator
-
isRunning
public boolean isRunning()Description copied from interface:SchemaModelValidatorCheck if the validation is currently in progress.- Specified by:
isRunningin interfaceSchemaModelValidator
-
setEntityChecks
-
setReporters
-
setProgresses
-
addProgress
Description copied from interface:SchemaModelValidatorAdds aValidationProgressto the list of global progress callbacks.- Specified by:
addProgressin interfaceSchemaModelValidator
-
removeProgress
- Specified by:
removeProgressin interfaceSchemaModelValidator
-
addReporter
Description copied from interface:SchemaModelValidatorAdds aReporterto the global list of reporters.- Specified by:
addReporterin interfaceSchemaModelValidator
-
removeReporter
- Specified by:
removeReporterin interfaceSchemaModelValidator
-