*/ #[ORM\OneToMany(targetEntity: Sortie::class, mappedBy: 'organisateur')] private Collection $sortiesOrganisateur; /** * @var Collection */ #[ORM\ManyToMany(targetEntity: Sortie::class, inversedBy: 'participants')] #[ORM\JoinTable(name: 'participant_sortie')] #[ORM\JoinColumn(name: 'participant_id', referencedColumnName: 'id_participant')] #[ORM\InverseJoinColumn(name: 'sortie_id', referencedColumnName: 'id_sortie')] private Collection $sortiesParticipants; public function __construct() { $this->sortiesOrganisateur = new ArrayCollection(); $this->sortiesParticipants = new ArrayCollection(); } public function getIdParticipant(): ?string { return $this->idParticipant; } public function getNom(): ?string { return $this->nom; } public function setNom(string $nom): self { $this->nom = $nom; return $this; } public function getPending(): ?bool { return $this->pending; } public function setPending(?bool $pending): void { $this->pending = $pending; } public function getPseudo(): ?string { return $this->pseudo; } public function setPseudo(string $pseudo): self { $this->pseudo = $pseudo; return $this; } public function getPrenom(): ?string { return $this->prenom; } public function setPrenom(string $prenom): self { $this->prenom = $prenom; return $this; } public function getTelephone(): ?string { return $this->telephone; } public function setTelephone(?string $telephone): self { $this->telephone = $telephone; return $this; } public function getEmail(): ?string { return $this->email; } public function setEmail(string $email): static { $this->email = $email; return $this; } /** * A visual identifier that represents this user. * * @see UserInterface */ public function getUserIdentifier(): string { return (string) $this->pseudo; } /** * @see UserInterface * * @return list */ public function getRoles(): array { $roles = $this->roles; // guarantee every user at least has ROLE_USER $roles[] = 'ROLE_USER'; return array_unique($roles); } /** * @param list $roles */ public function setRoles(array $roles): static { $this->roles = $roles; return $this; } public function isAdministrateur(): ?bool { return $this->administrateur; } public function setAdministrateur(bool $administrateur): self { $this->administrateur = $administrateur; return $this; } public function isActif(): ?bool { return $this->actif; } public function setActif(bool $actif): self { $this->actif = $actif; return $this; } /** * @see PasswordAuthenticatedUserInterface */ public function getPassword(): ?string { return $this->password; } public function setPassword(string $password): static { $this->password = $password; return $this; } /** * @see UserInterface */ public function eraseCredentials(): void { // If you store any temporary, sensitive data on the user, clear it here // $this->plainPassword = null; } public function getSite(): ?Site { return $this->site; } public function setSite(?Site $site): self { $this->site = $site; return $this; } /** * @return Collection */ public function getSortiesOrganisateur(): Collection { return $this->sortiesOrganisateur; } public function addSortieOrganisateur(Sortie $sortie): self { if (!$this->sortiesOrganisateur->contains($sortie)) { $this->sortiesOrganisateur->add($sortie); $sortie->setOrganisateur($this); } return $this; } public function removeSortieOrganisateur(Sortie $sortie): self { if ($this->sortiesOrganisateur->removeElement($sortie)) { // Set the owning side to null (unless already changed) if ($sortie->getOrganisateur() === $this) { $sortie->setOrganisateur(null); } } return $this; } public function getFileName(): ?string { return $this->fileName; } public function setFileName(?string $fileName): void { $this->fileName = $fileName; } /** * @return Collection */ public function getSortiesParticipants(): Collection { return $this->sortiesParticipants; } public function addSortiesParticipant(Sortie $sortiesParticipant): static { if (!$this->sortiesParticipants->contains($sortiesParticipant)) { $this->sortiesParticipants->add($sortiesParticipant); $sortiesParticipant->addParticipant($this); } return $this; } public function removeSortiesParticipant(Sortie $sortiesParticipant): static { if ($this->sortiesParticipants->removeElement($sortiesParticipant)) { $sortiesParticipant->removeParticipant($this); } return $this; } }