CustomOAuthUser.php 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. <?php
  2. namespace Base\OAuthClientBundle\Security\Core\User;
  3. use HWI\Bundle\OAuthBundle\Security\Core\User\OAuthUser;
  4. class CustomOAuthUser extends OAuthUser
  5. {
  6. /**
  7. * @var array
  8. */
  9. protected $roles = array('ROLE_USER');
  10. /**
  11. * @var array
  12. */
  13. protected $tenancies = array();
  14. /**
  15. * @var array
  16. */
  17. protected $tenancyCurrent = array();
  18. /**
  19. * {@inheritdoc}
  20. */
  21. public function getRoles()
  22. {
  23. return $this->roles;
  24. }
  25. /**
  26. * @param array $roles
  27. */
  28. public function setRoles($roles)
  29. {
  30. $this->roles = $roles;
  31. }
  32. /**
  33. * @return array
  34. */
  35. public function getTenancies()
  36. {
  37. return $this->tenancies;
  38. }
  39. /**
  40. * @param array $tenancies
  41. */
  42. public function setTenancies($tenancies)
  43. {
  44. $this->tenancies = $tenancies;
  45. }
  46. /**
  47. * @return array
  48. */
  49. public function getTenancyCurrent()
  50. {
  51. return $this->tenancyCurrent;
  52. }
  53. /**
  54. * @param array $tenancyCurrent
  55. */
  56. public function setTenancyCurrent($tenancyCurrent)
  57. {
  58. $this->tenancyCurrent = $tenancyCurrent;
  59. }
  60. /**
  61. * @param boolean $hasIntercom
  62. */
  63. public function setHasIntercom($hasIntercom)
  64. {
  65. $this->hasIntercom = $hasIntercom;
  66. }
  67. /**
  68. * @return boolean
  69. */
  70. public function getHasIntercom()
  71. {
  72. return $this->hasIntercom;
  73. }
  74. /**
  75. * @return boolean
  76. */
  77. public function hasIntercom()
  78. {
  79. return $this->hasIntercom;
  80. }
  81. }