<?phpnamespace App\Entity;use App\Repository\ParBancoRepository;use Doctrine\Common\Collections\ArrayCollection;use Doctrine\Common\Collections\Collection;use Doctrine\ORM\Mapping as ORM;#[ORM\Entity(repositoryClass: ParBancoRepository::class)]class ParBanco{ #[ORM\Id] #[ORM\GeneratedValue] #[ORM\Column] private ?int $id = null; #[ORM\Column(length: 100)] private ?string $nombre = null; #[ORM\Column(length: 20)] private ?string $nit = null; #[ORM\ManyToOne(inversedBy: 'banco')] private ?ParEstado $estado = null; #[ORM\OneToMany(mappedBy: 'banco', targetEntity: GHRetiroCesantias::class)] private Collection $retiroCesantias; public function __construct() { $this->retiroCesantias = new ArrayCollection(); } public function __toString() { return $this->getNombre(); } 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; } public function getNit(): ?string { return $this->nit; } public function setNit(string $nit): static { $this->nit = $nit; return $this; } public function getEstado(): ?ParEstado { return $this->estado; } public function setEstado(?ParEstado $estado): static { $this->estado = $estado; return $this; } /** * @return Collection<int, GHRetiroCesantias> */ public function getRetiroCesantias(): Collection { return $this->retiroCesantias; } public function addRetiroCesantia(GHRetiroCesantias $retiroCesantias): static { if (!$this->retiroCesantias->contains($retiroCesantias)) { $this->retiroCesantias->add($retiroCesantias); $retiroCesantias->setBanco($this); } return $this; } public function removeRetiroCesantia(GHRetiroCesantias $retiroCesantias): static { if ($this->retiroCesantias->removeElement($retiroCesantias)) { // set the owning side to null (unless already changed) if ($retiroCesantias->getBanco() === $this) { $retiroCesantias->setBanco(null); } } return $this; }}