Overtrue\Validation\Validator::__call PHP Method

__call() public method

Handle dynamic calls to class methods.
public __call ( string $method, array $parameters ) : mixed
$method string
$parameters array
return mixed
    public function __call($method, $parameters)
    {
        $rule = snake_case(substr($method, 8));
        if (isset($this->extensions[$rule])) {
            return $this->callExtension($rule, $parameters);
        }
        throw new \BadMethodCallException("Method [{$method}] does not exist.");
    }
Validator