Interface for rule providers that can resolve a validation rule's method to an alternate object and method name.
Rule providers implementing this interface allow validators to invoke a rule's method on another object, e.g. ORM tables resolving rule methods provided by behaviors. Resolving the provider and method before the rule's callable is created ensures the method's signature can be correctly reflected for passing the validation context.
Provides methods for managing multiple validators.
Validation Class. Used for validation of model data
Offers different validation methods.
ValidationRule object. Represents a validation method, error message and rules for applying such method to a field.
ValidationSet object. Holds all validation rules for a field and exposes methods to dynamically add or remove validation rules
Validator object encapsulates all methods related to data validations for a model It also provides an API to dynamically change validation rules for each model field.
Implements ArrayAccess to easily modify rules in the set
A trait that provides methods for building and interacting with Validators.
This trait is useful when building ORM like features where the implementing class wants to build and customize a variety of validator instances.
Classes using this trait can declare these constants:
DEFAULT_VALIDATOR - Override the interface default validator name if required.VALIDATOR_PROVIDER_NAME - The provider name the including class is assigned
in validators.BUILD_VALIDATOR_EVENT - The name of the event to be triggered when validators
are built.If the including class also implements events the Model.buildValidator event
will be triggered when validators are created.