mirror of
https://github.com/Respect/Validation.git
synced 2024-06-29 10:40:24 +02:00
366 B
366 B
Instance
v::instance(string $instanceName)
Validates if the input is an instance of the given class or interface.
v::instance('DateTime')->validate(new DateTime); //true
v::instance('Traversable')->validate(new ArrayObject); //true
Message template for this validator includes {{instanceName}}
.
See also: