1
0
mirror of synced 2025-02-02 21:41:45 +03:00

Entity to test a mapped superclass

Backport of https://github.com/doctrine/doctrine2/pull/1377/files to branch 2.5
This commit is contained in:
neoglez 2015-09-21 09:32:54 +02:00
parent ed637e51b9
commit ef73249bc7

View File

@ -169,3 +169,21 @@ class Avatar
/** @Column(type="string", length=255) */ /** @Column(type="string", length=255) */
public $image_alt_desc; public $image_alt_desc;
} }
/** @MappedSuperclass */
abstract class Identified
{
/** @Id @Column(type="integer") @GeneratedValue */
private $id;
public function getId()
{
return $this->id;
}
}
/** @Entity */
class Banner extends Identified
{
/** @Column(type="string") */
public $name;
}