Class ValidationEngine

java.lang.Object
com.aquima.interactions.rule.validation.ValidationEngine

public class ValidationEngine extends Object
This class contains the logic that is responsible for the validation.
Since:
5.0
Author:
O. Kerpershoek
  • Constructor Details

    • ValidationEngine

      public ValidationEngine(IRuleGraph graph)
      Constructs a validation engine for the specified rule graph.
      Parameters:
      graph - The rule graph containing the validation rules.
  • Method Details

    • validate

      public ValidationResult validate(IProfile profile, ValueReference reference)
      This method performs a validation for the attribute specified by the reference.
      Parameters:
      profile - The current profile state.
      reference - A reference to the attribute value that should be validated.
      Returns:
      Object containing the results of the validation action.
      Throws:
      UnknownEntityException - This exception is thrown when the reference of a rule attempt to use an unknown entity.
      UnknownAttributeException - This exception is thrown when the reference of a rule attempt to use an unknown attribute.
      UnknownInstanceException - This exception is thrown when the reference of a rule attempt to use an unknown instance.
      InstanceCastException - This exception is thrown when an instance cannot be converted to the expected type.
    • getAttribute

      protected IAttributeNode getAttribute(ValueReference reference)