1
0
mirror of synced 2024-12-05 03:06:05 +03:00

Cleaning up description of the BC Break

This commit is contained in:
Marco Pivetta 2012-07-08 16:49:54 +02:00
parent 7c2e5ae5b2
commit b67140f73c

View File

@ -1,11 +1,32 @@
# Upgrade to 2.3
## Configuration
## Configuration *BC Break*
`Doctrine\ORM\Configuration#newDefaultAnnotationDriver` has been changed to reflect latest changes in Doctrine\Common.
If you use it to have an AnnotationDriver configured with a SimpleAnnotationReader in your projects, you should from now
on call `newDefaultAnnotationDriver` with its second parameter set to `true`. Otherwise, the default consumed reader
will be the AnnotationReader, which uses the `@Namespace\AnnotationName` syntax.
The default annotation syntax has been changed from `@Entity` to `@ORM\Entity`. If you still want to use the simplified
version, you should use `Doctrine\Common\Annotations\SimpleAnnotationReader` for your AnnotationDriver or call
`Doctrine\ORM\Configuration#newDefaultAnnotationDriver` with its second parameter set to `true`.
* before:
```php
<?php
/** @Entity */
class MyEntity
{
}
```
* after:
```php
<?php
use Doctrine\ORM\Mapping as ORM;
/** @ORM\Entity */
class MyEntity
{
}
```
## EntityGenerator add*() method generation