Class ValidationEngine

    • Constructor Detail

      • ValidationEngine

        protected ValidationEngine​(ViatraQueryEngine engine,
                                   org.apache.log4j.Logger logger)
    • Method Detail

      • getConstraints

        public java.util.Set<IConstraint> getConstraints()
        Description copied from interface: IValidationEngine
        Returns the constraints to the registered constraint specifications.
        Specified by:
        getConstraints in interface IValidationEngine
        Returns:
        The Collection of constraints in the validation engine.
      • addConstraintSpecification

        public IConstraint addConstraintSpecification​(IConstraintSpecification constraintSpecification)
        Description copied from interface: IValidationEngine
        Adds the given constraint specification to the validation engine and returns the created constraint.
        Specified by:
        addConstraintSpecification in interface IValidationEngine
        Parameters:
        constraintSpecification - The constraint specification instance to be registered.
        Returns:
        The created corresponding constraint instance.
      • removeConstraintSpecification

        public IConstraint removeConstraintSpecification​(IConstraintSpecification constraintSpecification)
        Description copied from interface: IValidationEngine
        Removes the given constraint specification from the validation engine and returns the corresponding constraint.
        Specified by:
        removeConstraintSpecification in interface IValidationEngine
        Parameters:
        constraintSpecification - The constraint specification to be deregistered.
        Returns:
        The removed corresponding constraint instance.
      • addRuleSpecificationToExecutionSchema

        protected boolean addRuleSpecificationToExecutionSchema​(Constraint constraint)
      • removeRuleSpecificationFromExecutionSchema

        protected boolean removeRuleSpecificationFromExecutionSchema​(Constraint constraint)
      • addListener

        public boolean addListener​(ValidationEngineListener listener)
        Description copied from interface: IValidationEngine
        Adds the given listener to the list of listeners to be notified on specific events regarding the validation engine.
        Specified by:
        addListener in interface IValidationEngine
        Parameters:
        listener - The listener to be registered.
        Returns:
        true if the listener was not registered before.
      • removeListener

        public boolean removeListener​(ValidationEngineListener listener)
        Description copied from interface: IValidationEngine
        Removes the given listener from the list of listeners to be notified on specific events regarding the validation engine.
        Specified by:
        removeListener in interface IValidationEngine
        Parameters:
        listener - The listener to be deregistered.
        Returns:
        true if the listener was in fact registered.
      • notifyListenersConstraintRegistered

        protected void notifyListenersConstraintRegistered​(Constraint constraint)
      • notifyListenersConstraintDeregistered

        protected void notifyListenersConstraintDeregistered​(Constraint constraint)