A parser for docblock annotations that utilizes the annotation parser from Doctrine\Common.

Consumes Doctrine\Common\Annotations\DocParser, and responds to events from AnnotationManager. If the annotation examined is in the list of classes we are interested in, the raw annotation is passed to the DocParser in order to retrieve the annotation object instance. Otherwise, it is skipped.

package Zend_Code
subpackage Annotation

 Methods

__construct()

__construct() 

Retrieve the DocParser instance

getDocParser() : \Doctrine\Common\Annotations\DocParser

If none is registered, lazy-loads a new instance.

Returns

\Doctrine\Common\Annotations\DocParser

Handle annotation creation

onCreateAnnotation(\Zend\EventManager\EventInterface $e) : false | \stdClass

Parameters

Returns

false\stdClass

Specify an allowed annotation class

registerAnnotation(string $annotation) : \Zend\Code\Annotation\Parser\DoctrineAnnotationParser

Parameters

$annotation

string

Returns

Set many allowed annotations at once

registerAnnotations(array | \Traversable $annotations) : \Zend\Code\Annotation\Parser\DoctrineAnnotationParser

Parameters

$annotations

array\Traversable

Array or traversable object of annotation class names

Exceptions

\Zend\Code\Exception\InvalidArgumentException

Returns

Set the DocParser instance

setDocParser(\Doctrine\Common\Annotations\DocParser $docParser) : \Zend\Code\Annotation\Parser\DoctrineAnnotationParser

Parameters

$docParser

\Doctrine\Common\Annotations\DocParser

Returns

 Properties

 

<p>Annotation classes we support on this iteration</p>

$allowedAnnotations : array

 

$docParser

$docParser : \Doctrine\Common\Annotations\DocParser