ProyectoEjeFormacion.php 2.92 KB
<?php

namespace UBV\SurUbvBundle\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * UBV\SurUbvBundle\Entity\ProyectoEjeFormacion
 *
 * @ORM\Entity(repositoryClass="UBV\SurUbvBundle\Repository\ProyectoEjeFormacionRepository")
 * @ORM\Table(name="proyecto_eje_formacion", indexes={@ORM\Index(name="fk_proyecto_eje_formacion_proyecto_detalle1_idx", columns={"proyecto_detalle_id"}), @ORM\Index(name="fk_proyecto_eje_formacion_eje_formacion1_idx", columns={"eje_formacion_id"})}, uniqueConstraints={@ORM\UniqueConstraint(name="id_proyecto_eje_formacion_UNIQUE", columns={"id"})})
 */
class ProyectoEjeFormacion
{
    /**
     * @ORM\Id
     * @ORM\Column(type="integer")
     * @ORM\GeneratedValue(strategy="AUTO")
     * @ORM\SequenceGenerator(sequenceName="proyecto_eje_formacion_id_seq", allocationSize=1, initialValue=1)
     */
    protected $id;

    /**
     * @ORM\ManyToOne(targetEntity="ProyectoDetalle", inversedBy="proyectoEjeFormacions")
     * @ORM\JoinColumn(name="proyecto_detalle_id", referencedColumnName="id", nullable=false)
     */
    protected $proyectoDetalle;

    /**
     * @ORM\ManyToOne(targetEntity="EjeFormacion", inversedBy="proyectoEjeFormacions")
     * @ORM\JoinColumn(name="eje_formacion_id", referencedColumnName="id", nullable=false)
     */
    protected $ejeFormacion;

    public function __construct()
    {
    }

    /**
     * Set the value of id.
     *
     * @param integer $id
     * @return \UBV\SurUbvBundle\Entity\ProyectoEjeFormacion
     */
    public function setId($id)
    {
        $this->id = $id;

        return $this;
    }

    /**
     * Get the value of id.
     *
     * @return integer
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Set ProyectoDetalle entity (many to one).
     *
     * @param \UBV\SurUbvBundle\Entity\ProyectoDetalle $proyectoDetalle
     * @return \UBV\SurUbvBundle\Entity\ProyectoEjeFormacion
     */
    public function setProyectoDetalle(ProyectoDetalle $proyectoDetalle = null)
    {
        $this->proyectoDetalle = $proyectoDetalle;

        return $this;
    }

    /**
     * Get ProyectoDetalle entity (many to one).
     *
     * @return \UBV\SurUbvBundle\Entity\ProyectoDetalle
     */
    public function getProyectoDetalle()
    {
        return $this->proyectoDetalle;
    }

    /**
     * Set EjeFormacion entity (many to one).
     *
     * @param \UBV\SurUbvBundle\Entity\EjeFormacion $ejeFormacion
     * @return \UBV\SurUbvBundle\Entity\ProyectoEjeFormacion
     */
    public function setEjeFormacion(EjeFormacion $ejeFormacion = null)
    {
        $this->ejeFormacion = $ejeFormacion;

        return $this;
    }

    /**
     * Get EjeFormacion entity (many to one).
     *
     * @return \UBV\SurUbvBundle\Entity\EjeFormacion
     */
    public function getEjeFormacion()
    {
        return $this->ejeFormacion;
    }

    public function __sleep()
    {
        return array('id', 'proyecto_detalle_id', 'eje_formacion_id');
    }
}