public function FileCacheReader::getPropertyAnnotation in Service Container 7
Same name and namespace in other branches
- 7.2 modules/providers/service_container_annotation_discovery/lib/Doctrine/annotations/lib/Doctrine/Common/Annotations/FileCacheReader.php \Doctrine\Common\Annotations\FileCacheReader::getPropertyAnnotation()
Gets a property annotation.
Parameters
\ReflectionProperty $property The ReflectionProperty to read the annotations from.:
string $annotationName The name of the annotation.:
Return value
object|null The Annotation or NULL, if the requested annotation does not exist.
Overrides Reader::getPropertyAnnotation
File
- modules/
providers/ service_container_annotation_discovery/ lib/ Doctrine/ annotations/ lib/ Doctrine/ Common/ Annotations/ FileCacheReader.php, line 230
Class
- FileCacheReader
- File cache reader for annotations.
Namespace
Doctrine\Common\AnnotationsCode
public function getPropertyAnnotation(\ReflectionProperty $property, $annotationName) {
$annotations = $this
->getPropertyAnnotations($property);
foreach ($annotations as $annotation) {
if ($annotation instanceof $annotationName) {
return $annotation;
}
}
return null;
}