AnnotationLoader
in package
implements
LoaderInterface
Loader for Doctrine annotations and PHP 8 attributes.
Tags
Table of Contents
Interfaces
- LoaderInterface
- Loads {@link ClassMetadataInterface}.
Constants
- KNOWN_ANNOTATIONS = [\Symfony\Component\Serializer\Annotation\DiscriminatorMap::class, \Symfony\Component\Serializer\Annotation\Groups::class, \Symfony\Component\Serializer\Annotation\Ignore::class, \Symfony\Component\Serializer\Annotation\MaxDepth::class, \Symfony\Component\Serializer\Annotation\SerializedName::class, \Symfony\Component\Serializer\Annotation\Context::class]
Properties
- $reader : mixed
Methods
- __construct() : mixed
- loadAnnotations() : iterable<string|int, mixed>
- loadClassMetadata() : bool
- isKnownAttribute() : bool
- setAttributeContextsForGroups() : void
Constants
KNOWN_ANNOTATIONS
private
mixed
KNOWN_ANNOTATIONS
= [\Symfony\Component\Serializer\Annotation\DiscriminatorMap::class, \Symfony\Component\Serializer\Annotation\Groups::class, \Symfony\Component\Serializer\Annotation\Ignore::class, \Symfony\Component\Serializer\Annotation\MaxDepth::class, \Symfony\Component\Serializer\Annotation\SerializedName::class, \Symfony\Component\Serializer\Annotation\Context::class]
Properties
$reader
private
mixed
$reader
Methods
__construct()
public
__construct([Reader $reader = null ]) : mixed
Parameters
- $reader : Reader = null
loadAnnotations()
public
loadAnnotations(ReflectionClass|ReflectionMethod|ReflectionProperty $reflector) : iterable<string|int, mixed>
Parameters
- $reflector : ReflectionClass|ReflectionMethod|ReflectionProperty
Return values
iterable<string|int, mixed>loadClassMetadata()
public
loadClassMetadata(ClassMetadataInterface $classMetadata) : bool
Parameters
- $classMetadata : ClassMetadataInterface
Return values
boolisKnownAttribute()
private
isKnownAttribute(string $attributeName) : bool
Parameters
- $attributeName : string
Return values
boolsetAttributeContextsForGroups()
private
setAttributeContextsForGroups(Context $annotation, AttributeMetadataInterface $attributeMetadata) : void
Parameters
- $annotation : Context
- $attributeMetadata : AttributeMetadataInterface