Elastica\QueryBuilder\Facade::__call PHP Method

__call() public method

Executes DSL methods.
public __call ( string $name, array $arguments ) : mixed
$name string
$arguments array
return mixed
    public function __call($name, array $arguments)
    {
        // defined check
        if (false === method_exists($this->_dsl, $name)) {
            throw new QueryBuilderException('undefined ' . $this->_dsl->getType() . ' "' . $name . '"');
        }
        // version support check
        if (false === $this->_version->supports($name, $this->_dsl->getType())) {
            $reflection = new \ReflectionClass($this->_version);
            throw new QueryBuilderException($this->_dsl->getType() . ' "' . $name . '" in ' . $reflection->getShortName() . ' not supported');
        }
        return call_user_func_array([$this->_dsl, $name], $arguments);
    }