src/Reflection/ReflectionClass.php
public function getMethods(?int $filter = null): array
    {
        $methods = (null === $filter)
            ? $this->reflectionClass->getMethods()
            : $this->reflectionClass->getMethods($filter);
        $return  = [];
        foreach ($methods as $key => $method) {
            $return[$key] = ReflectionMethod::constructFromReflectionMethod($method);
        }

        return $return;
    }
public function getMethods(?int $filter = null): array
    {
        $methods = (null === $filter)
            ? $this->reflectionClass->getMethods()
            : $this->reflectionClass->getMethods($filter);
        $return  = [];
        foreach ($methods as $key => $method) {
            $return[$key] = ReflectionMethod::constructFromReflectionMethod($method);
        }

        return $return;
    }
@param int|null $filter

@return array|ReflectionMethod[]
@throws \ReflectionException