PHPCD\PHPCD::getFunctionInfo PHP Method

getFunctionInfo() private method

private getFunctionInfo ( $name, $pattern = null )
    private function getFunctionInfo($name, $pattern = null)
    {
        if ($pattern && strpos($name, $pattern) !== 0) {
            return null;
        }
        $reflection = new \ReflectionFunction($name);
        $params = array_map(function ($param) {
            return $param->getName();
        }, $reflection->getParameters());
        return ['word' => $name, 'abbr' => "{$name}(" . join(', ', $params) . ')', 'info' => preg_replace('#/?\\*(\\*|/)?#', '', $reflection->getDocComment()), 'kind' => 'f', 'icase' => 1];
    }