1
0
mirror of synced 2024-12-14 07:06:04 +03:00
doctrine2/tests/Doctrine/Tests/Models/Forum/ForumUser.php

32 lines
868 B
PHP

<?php
namespace Doctrine\Tests\Models\Forum;
/**
* @DoctrineEntity
* @DoctrineTable(name="forum_users")
* @DoctrineInheritanceType("joined")
* @DoctrineDiscriminatorColumn(name="dtype", type="varchar", length=20)
* @DoctrineDiscriminatorMap({
"user" = "Doctrine\Tests\Models\Forum\ForumUser",
"admin" = "Doctrine\Tests\Models\Forum\ForumAdministrator"})
* @DoctrineSubclasses({"Doctrine\Tests\Models\Forum\ForumAdministrator"})
*/
class ForumUser
{
/**
* @DoctrineColumn(type="integer")
* @DoctrineId
* @DoctrineIdGenerator("auto")
*/
public $id;
/**
* @DoctrineColumn(type="varchar", length=50)
*/
public $username;
/**
* @DoctrineOneToOne(targetEntity="ForumAvatar", cascade={"save"})
* @DoctrineJoinColumn(name="avatar_id", referencedColumnName="id")
*/
public $avatar;
}