PolyTypeObjectValidatorInterface
interface PolyTypeObjectValidatorInterface implements ObjectValidatorInterface (View source)
Contract for a poly type validator, able to act on possibly any type.
Methods
Checks if the given value is valid according to the validator, and returns the Error Messages object which occurred.
Returns the options of this validator which can be specified in the constructor
Allows to set a container to keep track of validated instances.
Checks the given target can be validated by the validator implementation.
Return the priority of this validator.
Details
Result
validate(mixed $value)
Checks if the given value is valid according to the validator, and returns the Error Messages object which occurred.
array
getOptions()
Returns the options of this validator which can be specified in the constructor
void
setValidatedInstancesContainer(SplObjectStorage $validatedInstancesContainer)
Allows to set a container to keep track of validated instances.
bool
canValidate(mixed $target)
Checks the given target can be validated by the validator implementation.
int
getPriority()
Return the priority of this validator.
Validators with a high priority are chosen before low priority and only one of multiple capable validators will be used.