protected function getAnnotations(Reflector $reflector): array
    {
        switch (true) {
            case ($reflector instanceof ReflectionClass):
                return $this->annotationReader->getClassAnnotations($reflector);

            case ($reflector instanceof ReflectionMethod):
                return $this->annotationReader->getMethodAnnotations($reflector);

            case ($reflector instanceof ReflectionProperty):
                return $this->annotationReader->getPropertyAnnotations($reflector);

            default:
                throw new InvalidArgumentException('Unsupported reflection point ' . get_class($reflector));
        }
    }