3 // src/Rapsys/AirBundle/Entity/User.php
4 namespace Rapsys\AirBundle\Entity
;
6 use Rapsys\AirBundle\Entity\Application
;
7 use Rapsys\AirBundle\Entity\Group
;
8 use Rapsys\AirBundle\Entity\Link
;
9 use Rapsys\AirBundle\Entity\Snippet
;
10 use Rapsys\UserBundle\Entity\User
as BaseUser
;
12 class User
extends BaseUser
{
19 * @var \Doctrine\Common\Collections\Collection
21 private $applications;
24 * @var \Doctrine\Common\Collections\Collection
29 * @var \Doctrine\Common\Collections\Collection
34 * @var \Doctrine\Common\Collections\Collection
39 * @var \Doctrine\Common\Collections\Collection
41 private $subscriptions;
46 public function __construct() {
47 //Call parent constructor
48 parent
::__construct();
51 $this->applications
= new \Doctrine\Common\Collections\
ArrayCollection();
52 $this->locations
= new \Doctrine\Common\Collections\
ArrayCollection();
53 $this->snippets
= new \Doctrine\Common\Collections\
ArrayCollection();
54 $this->subscribers
= new \Doctrine\Common\Collections\
ArrayCollection();
55 $this->subscriptions
= new \Doctrine\Common\Collections\
ArrayCollection();
61 * @param string $phone
65 public function setPhone($phone) {
66 $this->phone
= $phone;
76 public function getPhone() {
83 * @param string $donation
87 public function setDonation($donation) {
88 $this->donation
= $donation;
98 public function getDonation() {
99 return $this->donation
;
105 * @param string $site
109 public function setSite($site) {
120 public function getSite() {
127 * @param \Rapsys\AirBundle\Entity\Application $application
131 public function addApplication(Application
$application) {
132 $this->applications
[] = $application;
140 * @param \Rapsys\AirBundle\Entity\Application $application
142 public function removeApplication(Application
$application) {
143 $this->applications
->removeElement($application);
149 * @return \Doctrine\Common\Collections\Collection
151 public function getApplications() {
152 return $this->applications
;
158 * @param \Rapsys\AirBundle\Entity\Snippet $snippet
162 public function addSnippet(Snippet
$snippet) {
163 $this->snippets
[] = $snippet;
171 * @param \Rapsys\AirBundle\Entity\Snippet $snippet
173 public function removeSnippet(Snippet
$snippet) {
174 $this->snippets
->removeElement($snippet);
180 * @return \Doctrine\Common\Collections\Collection
182 public function getSnippets() {
183 return $this->snippets
;
189 * @param \Rapsys\AirBundle\Entity\Location $location
193 public function addLocation(Location
$location) {
194 $this->locations
[] = $location;
202 * @param \Rapsys\AirBundle\Entity\Location $location
204 public function removeLocation(Location
$location) {
205 $this->locations
->removeElement($location);
211 * @return \Doctrine\Common\Collections\Collection
213 public function getLocations() {
214 return $this->locations
;
220 * @param \Rapsys\AirBundle\Entity\User $subscriber
224 public function addSubscriber(User
$subscriber) {
225 $this->subscribers
[] = $subscriber;
233 * @param \Rapsys\AirBundle\Entity\User $subscriber
235 public function removeSubscriber(User
$subscriber) {
236 $this->subscribers
->removeElement($subscriber);
242 * @return \Doctrine\Common\Collections\Collection
244 public function getSubscribers() {
245 return $this->subscribers
;
251 * @param \Rapsys\AirBundle\Entity\User $subscription
255 public function addSubscription(User
$subscription) {
256 $this->subscriptions
[] = $subscription;
262 * Remove subscription
264 * @param \Rapsys\AirBundle\Entity\User $subscription
266 public function removeSubscription(User
$subscription) {
267 $this->subscriptions
->removeElement($subscription);
273 * @return \Doctrine\Common\Collections\Collection
275 public function getSubscriptions() {
276 return $this->subscriptions
;