Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions docs/en/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,12 @@ annotations of a class. A common one is

.. code-block:: php

use Doctrine\Common\Annotations\AnnotationReader;
use Doctrine\Common\Annotations\AnnotationRegistry;

// Deprecated and will be removed in 2.0 but currently needed
AnnotationRegistry::registerLoader('class_exists');

$reflectionClass = new ReflectionClass(Foo::class);
$property = $reflectionClass->getProperty('bar');

Expand All @@ -73,6 +79,13 @@ annotations of a class. A common one is

A reader has multiple methods to access the annotations of a class.

Note that ``AnnotationRegistry::registerLoader('class_exists')`` only works
if you already have an autoloader configured (i.e. composer autoloader).
Otherwise, :ref:`please take a look to the other annotation autoload mechanisms <annotations>`.

A reader has multiple methods to access the annotations
of a class.
Comment thread
l-vo marked this conversation as resolved.

:ref:`Read more about handling annotations. <annotations>`

IDE Support
Expand Down