Skip to content

Commit

Permalink
Cleaning up description of the BC Break
Browse files Browse the repository at this point in the history
  • Loading branch information
Ocramius committed Jul 8, 2012
1 parent 7c2e5ae commit b67140f
Showing 1 changed file with 26 additions and 5 deletions.
31 changes: 26 additions & 5 deletions UPGRADE.md
@@ -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

Expand Down

0 comments on commit b67140f

Please sign in to comment.