Interface Validator

All Superinterfaces:
CanCopy<Validator>, HasId<String>, HasParent<Validator,Model<?,?>>, Model<Validator,String>, Validatable

public interface Validator extends Model<Validator,String>, HasParent<Validator,Model<?,?>>
Represents a validator that can verify workflow inputs or state. Validator provides a way to validate data before it's processed by the workflow engine, ensuring data integrity and business rule compliance.

Validators are used throughout the workflow system to validate inputs, state transitions, and business rules. They can be attached to various workflow elements to ensure that only valid data is processed.

Since:
1.0
See Also:
  • Method Details

    • verify

      void verify(WorkflowExecutionContext context) throws WorkflowException
      Verifies the given attributes against this validator's rules.
      Parameters:
      context - the execution context
      Throws:
      WorkflowException - if validation fails
    • getType

      String getType()
      Gets the type of validator to use.
      Returns:
      the validator type
    • getValue

      String getValue()
      Gets the value or identifier for the validator.
      Returns:
      the validator value
    • getArgs

      Attributes getArgs()
      Gets the arguments to pass to the validator.
      Returns:
      the arguments for the validator
    • getName

      String getName()
      Gets the name of this validator.
      Returns:
      the validator name