123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- <?php
- namespace Base\OAuthBundle\Security\Core\User;
- use HWI\Bundle\OAuthBundle\Security\Core\User\OAuthUser;
- use Doctrine\ORM\Mapping as ORM;
- /**
- * @ORM\Entity
- */
- class CustomOAuthUser extends OAuthUser
- {
-
- /**
- * @ORM\Id
- * @ORM\Column(type="integer")
- * @ORM\GeneratedValue(strategy="AUTO")
- */
- protected $id;
- /**
- * @var array
- */
- protected $roles = array('ROLE_USER');
-
- /**
- * @return int
- */
- public function getId()
- {
- return $this->id;
- }
- /**
- * {@inheritdoc}
- */
- public function getRoles()
- {
- return $this->roles;
- }
- /**
- * @param array $roles
- */
- public function setRoles($roles)
- {
- $this->roles = $roles;
- }
- }
|