Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- namespace TMS\OpenBundle\Entity;
- /**
- * @Doctrine\ORM\Mapping\Entity
- * @Doctrine\ORM\Mapping\Table(name="parent_table")
- * @Doctrine\ORM\Mapping\InheritanceType("JOINED")
- * @Doctrine\ORM\Mapping\DiscriminatorColumn(name="type_id", type="integer")
- * @Doctrine\ORM\Mapping\DiscriminatorMap({
- * "1" = "ChildClass",
- * })
- *
- */
- abstract class ParentClass {
- /**
- * @Doctrine\ORM\Mapping\Id
- * @Doctrine\ORM\Mapping\Column(type="integer")
- * @Doctrine\ORM\Mapping\GeneratedValue
- */
- protected $id;
- /**
- * @Doctrine\ORM\Mapping\Column(type="boolean", nullable=false, name="is_active")
- */
- protected $isActive = false;
- public function getId() {
- return $this->id;
- }
- public function getIsActive() {
- return $this->isActive;
- }
- public function setId($id) {
- $this->id = $id;
- }
- public function setIsActive($isActive) {
- $this->isActive = $isActive;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement