Go\Core\AspectLoader::getAnnotations PHP Méthode

getAnnotations() protected méthode

Return list of annotations for reflection point
protected getAnnotations ( ReflectionClass | ReflectionMethod | ReflectionProperty $refPoint ) : array
$refPoint ReflectionClass | ReflectionMethod | ReflectionProperty Reflection instance
Résultat array list of annotations
    protected function getAnnotations($refPoint)
    {
        switch (true) {
            case $refPoint instanceof \ReflectionClass:
                return $this->annotationReader->getClassAnnotations($refPoint);
            case $refPoint instanceof \ReflectionMethod:
                return $this->annotationReader->getMethodAnnotations($refPoint);
            case $refPoint instanceof \ReflectionProperty:
                return $this->annotationReader->getPropertyAnnotations($refPoint);
            default:
                throw new \InvalidArgumentException("Unsupported reflection point " . get_class($refPoint));
        }
    }