[DDC-1024] the EntityGenerator generate getters and setters for properties of the parent class Created: 09/Feb/11 Updated: 04/Jan/12 Resolved: 12/Feb/11 |
|
| Status: | Resolved |
| Project: | Doctrine 2 - ORM |
| Component/s: | Tools |
| Affects Version/s: | Git Master |
| Fix Version/s: | 2.0.2, 2.1 |
| Security Level: | All |
| Type: | Bug | Priority: | Major |
| Reporter: | Christophe Coevoet | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
when using the EntityGenerator to generate getters and setters of two classes mapped with annotations, one inheriting from the other, the EntityGenerator generates getters and setters for the properties of the parent class in the child class too. This occurs since the recent EntityGenerator changes (as it did not care about inheritance before). I haven't try if it works well when using XML or YAML for the mapping. |
| Comments |
| Comment by Benjamin Eberlei [ 12/Feb/11 ] |
|
How do you define inheritance? |
| Comment by Christophe Coevoet [ 12/Feb/11 ] |
|
In my case, it was inheritance using a Single Table Inheritance. Both entities were in the same Symfony2 Bundle so the getters and setters were generated by the same command. |
| Comment by Benjamin Eberlei [ 12/Feb/11 ] |
|
fixed |
| Comment by yakobe [ 01/Nov/11 ] |
|
I am still having this problem with the 2.1 branch. Should it not happen anymore? |
| Comment by Albert Brand [ 04/Jan/12 ] |
|
I'm also still seeing this in 2.1 (bundled with Symfony2). |