Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- namespace Tracker\MembersBundle\Entity;
- use FOS\UserBundle\Entity\User as BaseUser;
- use Doctrine\ORM\Mapping as ORM;
- use Doctrine\Common\Collections\ArrayCollection;
- /**
- * @ORM\Entity
- * @ORM\Table(name="fos_user")
- */
- class User extends BaseUser
- {
- /**
- * @ORM\Id
- * @ORM\Column(type="integer")
- * @ORM\GeneratedValue(strategy="AUTO")
- */
- protected $id;
- /**
- * @ORM\ManyToMany(targetEntity="Tracker\MembersBundle\Entity\Group")
- * @ORM\JoinTable(name="fos_user_user_group",
- * joinColumns={@ORM\JoinColumn(name="user_id", referencedColumnName="id")},
- * inverseJoinColumns={@ORM\JoinColumn(name="group_id", referencedColumnName="id")}
- * )
- */
- protected $groups;
- /**
- * @var integer $torrentPassVersion
- *
- * @ORM\Column(name="torrent_pass_version", type="integer", nullable=false)
- */
- private $torrentPassVersion = 0;
- /**
- * @var string $torrentPass
- *
- * @ORM\Column(name="torrent_pass", type="string", nullable=false)
- */
- private $torrentPass;
- /**
- * @var bigint $downloaded
- *
- * @ORM\Column(name="downloaded", type="bigint", nullable=false)
- */
- private $downloaded = 0;
- /**
- * @var bigint $uploaded
- *
- * @ORM\Column(name="uploaded", type="bigint", nullable=false)
- */
- private $uploaded = 0;
- /**
- * @ORM\OneToMany(targetEntity="XbtFiles", mappedBy="uploader")
- */
- protected $uploads;
- /**
- * @ORM\OneToMany(targetEntity="Comment", mappedBy="user")
- */
- protected $comments;
- public function __construct()
- {
- parent::__construct();
- $this->uploads = new ArrayCollection();
- $this->comments = new ArrayCollection();
- //$this->groups = new ArrayCollection();
- }
- /**
- * Get id
- *
- * @return integer
- */
- public function getId()
- {
- return $this->id;
- }
- /**
- * Set torrentPassVersion
- *
- * @param integer $torrentPassVersion
- */
- public function setTorrentPassVersion($torrentPassVersion)
- {
- $this->torrentPassVersion = $torrentPassVersion;
- }
- /**
- * Get torrentPassVersion
- *
- * @return integer
- */
- public function getTorrentPassVersion()
- {
- return $this->torrentPassVersion;
- }
- /**
- * Set torrentPass
- *
- * @param string $torrentPass
- */
- public function setTorrentPass($torrentPass)
- {
- $this->torrentPass = $torrentPass;
- }
- /**
- * Get torrentPass
- *
- * @return string
- */
- public function getTorrentPass()
- {
- return $this->torrentPass;
- }
- /**
- * Set downloaded
- *
- * @param bigint $downloaded
- */
- public function setDownloaded($downloaded)
- {
- $this->downloaded = $downloaded;
- }
- /**
- * Get downloaded
- *
- * @return bigint
- */
- public function getDownloaded()
- {
- return $this->downloaded;
- }
- /**
- * Set uploaded
- *
- * @param bigint $uploaded
- */
- public function setUploaded($uploaded)
- {
- $this->uploaded = $uploaded;
- }
- /**
- * Get uploaded
- *
- * @return bigint
- */
- public function getUploaded()
- {
- return $this->uploaded;
- }
- /**
- * Add uploads
- *
- * @param Tracker\MembersBundle\Entity\XbtFiles $uploads
- */
- public function addXbtFiles(\Tracker\MembersBundle\Entity\XbtFiles $uploads)
- {
- $this->uploads[] = $uploads;
- }
- /**
- * Get uploads
- *
- * @return Doctrine\Common\Collections\Collection
- */
- public function getUploads()
- {
- return $this->uploads;
- }
- /**
- * Add comments
- *
- * @param Tracker\MembersBundle\Entity\Comment $comments
- */
- public function addComment(\Tracker\MembersBundle\Entity\Comment $comments)
- {
- $this->comments[] = $comments;
- }
- /**
- * Get comments
- *
- * @return Doctrine\Common\Collections\Collection
- */
- public function getComments()
- {
- return $this->comments;
- }
- /**
- * Get groups
- *
- * @return Doctrine\Common\Collections\Collection
- */
- public function getGroups()
- {
- return $this->groups;
- }
- /**
- * Add groups
- *
- * @param Tracker\MembersBundle\Entity\Group $groups
- */
- public function addGroup(\Tracker\MembersBundle\Entity\Group $groups)
- {
- $this->groups[] = $groups;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment