<?phpnamespace App\Entity;use App\Repository\ComTipoClienteRepository;use Doctrine\Common\Collections\ArrayCollection;use Doctrine\Common\Collections\Collection;use Doctrine\ORM\Mapping as ORM;#[ORM\Entity(repositoryClass: ComTipoClienteRepository::class)]class ComTipoCliente{ #[ORM\Id] #[ORM\GeneratedValue] #[ORM\Column] private ?int $id = null; #[ORM\Column(length: 255)] private ?string $nombre = null; #[ORM\OneToMany(mappedBy: 'tipoCliente', targetEntity: ComProspecto::class)] private Collection $comTipoCliente; #[ORM\OneToMany(mappedBy: 'tipoCliente', targetEntity: TerEmpresaCliente::class)] private Collection $terEmpresaClientes; public function __construct() { $this->comTipoCliente = new ArrayCollection(); $this->terEmpresaClientes = new ArrayCollection(); } public function getId(): ?int { return $this->id; } public function getNombre(): ?string { return $this->nombre; } public function setNombre(string $nombre): static { $this->nombre = $nombre; return $this; } /** * @return Collection<int, ComProspecto> */ public function getComTipoCliente(): Collection { return $this->comTipoCliente; } public function addComTipoCliente(ComProspecto $comTipoCliente): static { if (!$this->comTipoCliente->contains($comTipoCliente)) { $this->comTipoCliente->add($comTipoCliente); $comTipoCliente->setTipoCliente($this); } return $this; } public function removeComTipoCliente(ComProspecto $comTipoCliente): static { if ($this->comTipoCliente->removeElement($comTipoCliente)) { // set the owning side to null (unless already changed) if ($comTipoCliente->getTipoCliente() === $this) { $comTipoCliente->setTipoCliente(null); } } return $this; } /** * @return Collection<int, TerEmpresaCliente> */ public function getTerEmpresaClientes(): Collection { return $this->terEmpresaClientes; } public function addTerEmpresaCliente(TerEmpresaCliente $terEmpresaCliente): static { if (!$this->terEmpresaClientes->contains($terEmpresaCliente)) { $this->terEmpresaClientes->add($terEmpresaCliente); $terEmpresaCliente->setTipoCliente($this); } return $this; } public function removeTerEmpresaCliente(TerEmpresaCliente $terEmpresaCliente): static { if ($this->terEmpresaClientes->removeElement($terEmpresaCliente)) { // set the owning side to null (unless already changed) if ($terEmpresaCliente->getTipoCliente() === $this) { $terEmpresaCliente->setTipoCliente(null); } } return $this; }}