Advertisement
Guest User

Untitled

a guest
Nov 10th, 2013
373
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.28 KB | None | 0 0
  1. <?php
  2. // src/Acme/AccountBundle/Entity/UserRole.php
  3. namespace Acme\AccountBundle\Entity;
  4.  
  5. use Doctrine\ORM\Mapping as ORM;
  6. //use Symfony\Component\Security\Core\User\AdvancedUserInterface;
  7. //use Doctrine\Common\Collections\ArrayCollection;
  8.  
  9.  
  10. /**
  11.  * Acme\AccountBundle\Entity\UserRole
  12.  *@ORM\Entity()
  13.  *@ORM\Table(name="user_role")
  14.  */
  15. class UserRole
  16. {
  17.     /**
  18.      @ORM\Id
  19.      @ORM\Column(type="integer")
  20.      */
  21.     private $user_id;
  22.    
  23.     /**
  24.      ORM\Id
  25.      @ORM\Column(type="integer")
  26.      */
  27.     private $role_id;
  28.  
  29.  
  30.  
  31.     /**
  32.      * Set user_id
  33.      *
  34.      * @param integer $userId
  35.      * @return UserRole
  36.      */
  37.     public function setUserId($userId)
  38.     {
  39.         $this->user_id = $userId;
  40.    
  41.         return $this;
  42.     }
  43.  
  44.     /**
  45.      * Get user_id
  46.      *
  47.      * @return integer
  48.      */
  49.     public function getUserId()
  50.     {
  51.         return $this->user_id;
  52.     }
  53.  
  54.     /**
  55.      * Set role_id
  56.      *
  57.      * @param integer $roleId
  58.      * @return UserRole
  59.      */
  60.     public function setRoleId($roleId)
  61.     {
  62.         $this->role_id = $roleId;
  63.    
  64.         return $this;
  65.     }
  66.  
  67.     /**
  68.      * Get role_id
  69.      *
  70.      * @return integer
  71.      */
  72.     public function getRoleId()
  73.     {
  74.         return $this->role_id;
  75.     }
  76. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement