<?php
namespace App\Core\Entity\InformacionPerfil;
use App\Core\Entity\InformacionPerfil;
use App\Core\Repository\InformacionPerfil\ProfesionPerfilRepository;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\Groups;
/**
* @ORM\Entity(repositoryClass=ProfesionPerfilRepository::class)
*/
class ProfesionPerfil
{
const JSON_FIELDS = ['id', 'profesion' => Profesion::JSON_FIELDS, 'perfil' => ['id']];
/**
* @ORM\Id
* @ORM\GeneratedValue
* @ORM\Column(type="integer")
* @Groups("profesionPerfil")
*/
private $id;
/**
* @ORM\ManyToOne(targetEntity=Profesion::class)
* @ORM\JoinColumn(nullable=false)
* @Groups("profesionPerfil")
*/
private $profesion;
/**
* @ORM\ManyToOne(targetEntity=InformacionPerfil::class, inversedBy="profesionPerfil")
* @ORM\JoinColumn(nullable=false)
*/
private $perfil;
public function getId(): ?int
{
return $this->id;
}
public function getProfesion(): ?Profesion
{
return $this->profesion;
}
public function setProfesion(?Profesion $profesion): self
{
$this->profesion = $profesion;
return $this;
}
public function getPerfil(): ?InformacionPerfil
{
return $this->perfil;
}
public function setPerfil(?InformacionPerfil $perfil): self
{
$this->perfil = $perfil;
return $this;
}
}