public function getEventDefinitions()
{
$output = '';
$reader = $this->getReader();
foreach ($this->getClassesToScan() as $class) {
foreach ($class->getMethods() as $method) {
foreach ($reader->getMethodAnnotations($method) as $annotation) {
$output .= $this->buildListener($class->name, $method->name, $annotation->events);
}
}
}
return trim($output);
}