protected function getMethodAnnotations(ReflectionClass $class, SimpleAnnotationReader $reader) { $annotations = []; foreach ($class->getMethods() as $method) { $results = $reader->getMethodAnnotations($method); if (count($results) > 0) { $annotations[$method->name] = $results; } } return $annotations; }