escala = new ArrayCollection(); } public function getTrabajo() { return $this->trabajo; } public function setTrabajo($trabajo) { $this->trabajo = $trabajo; return $this; } public function getPregrado() { return $this->pregrado; } public function setPregrado($pregrado) { $this->pregrado = $pregrado; return $this; } public function getPostgrado() { return $this->postgrado; } public function setPostgrado($postgrado) { $this->postgrado = $postgrado; return $this; } /** * Get id * * @return integer */ public function getId() { return $this->id; } /** * Get nombre * * @return string */ public function __toString() { return $this->trabajo; } /** * Set idRolInstitucion * * @param \AppBundle\Entity\RolInstitucion $idRolInstitucion * @return Usuarios */ public function setIdRolInstitucion(\AppBundle\Entity\RolInstitucion $idRolInstitucion = null) { $this->idRolInstitucion = $idRolInstitucion; return $this; } /** * Get idRolInstitucion * * @return \AppBundle\Entity\RolInstitucion */ public function getIdRolInstitucion() { return $this->idRolInstitucion; } /** * @ORM\PrePersist */ public function setFechaCreacion() { $this->fecha_creacion = new \DateTime(); $this->fecha_ultima_actualizacion = new \DateTime(); } /** * @ORM\PreUpdate */ public function setFechaUltimaActualizacion() { $this->fecha_utlima_actualizacion = new \DateTime(); } /** * Add escala * * @param \AppBundle\Entity\DocenteEscala $escala * @return DocenteEscala */ public function addEscala(\AppBundle\Entity\DocenteEscala $escala) { $this->escala[] = $escala; return $this; } /** * Remove escala * * @param \AppBundle\Entity\DocenteEscala $escala */ public function removeEscala(\AppBundle\Entity\DocenteEscala $escala) { $this->escala->removeElement($escala); } /** * Get Escala * * @return \Doctrine\Common\Collections\Collection */ public function getEscala() { return $this->escala; } public function getEscalafones() { return $this->escala->toArray(); /*IMPORTANTE: el mecanismo de seguridad de Sf2 requiere ésto como un array*/ } }