Zend\Code\Annotation\AnnotationManager
Pluggable annotation manager
Simply composes an EventManager. When createAnnotation() is called, it fires
off an event of the same name, passing it the resolved annotation class, the
annotation content, and the raw annotation string; the first listener to
return an object will halt execution of the event, and that object will be
returned as the annotation.
Synopsis
class AnnotationManager
implements
EventManagerAwareInterface
{
- // constants
- const EVENT_CREATE_ANNOTATION = 'createAnnotation';
- // members
- protected EventManagerInterface $events;
- // methods
- public AnnotationManager setEventManager()
- public EventManagerInterface getEventManager()
- public AnnotationManager attach()
- public stdClass createAnnotation()
Hierarchy
Implements
Constants
Name | Value |
---|---|
EVENT_CREATE_ANNOTATION | 'createAnnotation' |
Members
protected
- $events — Zend\EventManager\EventManagerInterface
Methods
public
- attach() — Attach a parser to listen to the createAnnotation event
- createAnnotation() — Create Annotation
- getEventManager() — Retrieve event manager
- setEventManager() — Set the event manager instance