Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. AnnotationReader.php

function AnnotationReader::getPropertyAnnotations

Overrides Reader::getPropertyAnnotations

1 call to AnnotationReader::getPropertyAnnotations()
AnnotationReader::getPropertyAnnotation in vendor/doctrine/annotations/lib/Doctrine/Common/Annotations/AnnotationReader.php
Gets a property annotation.

File

vendor/doctrine/annotations/lib/Doctrine/Common/Annotations/AnnotationReader.php, line 171

Class

AnnotationReader
A reader for docblock annotations.

Namespace

Doctrine\Common\Annotations

Code

public function getPropertyAnnotations(ReflectionProperty $property) {
    $class = $property->getDeclaringClass();
    $context = 'property ' . $class->getName() . '::$' . $property->getName();
    $this->parser
        ->setTarget(Target::TARGET_PROPERTY);
    $this->parser
        ->setImports($this->getPropertyImports($property));
    $this->parser
        ->setIgnoredAnnotationNames($this->getIgnoredAnnotationNames($class));
    $this->parser
        ->setIgnoredAnnotationNamespaces(self::$globalIgnoredNamespaces);
    return $this->parser
        ->parse($property->getDocComment(), $context);
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal