*/ #[ORM\OneToMany(mappedBy: 'repository', targetEntity: Client::class)] private Collection $clients; public function __construct() { parent::__construct(); $this->clients = new ArrayCollection(); } public function getIpAddress(): ?string { return $this->ipAddress; } public function setIpAddress(string $ipAddress): static { $this->ipAddress = $ipAddress; return $this; } public function getDescription(): ?string { return $this->description; } public function setDescription(?string $description): static { $this->description = $description; return $this; } /** * @return Collection */ public function getClients(): Collection { return $this->clients; } public function addClient(Client $client): static { if (!$this->clients->contains($client)) { $this->clients->add($client); $client->setRepository($this); } return $this; } public function removeClient(Client $client): static { if ($this->clients->removeElement($client)) { // set the owning side to null (unless already changed) if ($client->getRepository() === $this) { $client->setRepository(null); } } return $this; } }