2018-09-06 12:58:36 +02:00
|
|
|
<?php
|
2018-09-12 22:25:22 +02:00
|
|
|
|
2018-09-06 13:52:34 +02:00
|
|
|
namespace App\Entity\Attribut;
|
2018-09-06 12:58:36 +02:00
|
|
|
|
2018-10-03 15:50:46 +02:00
|
|
|
use App\Entity\SourceInterface;
|
2018-09-06 12:58:36 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @author kevinfrantz
|
|
|
|
*/
|
2018-09-12 22:25:22 +02:00
|
|
|
trait SourceAttribut
|
|
|
|
{
|
2018-09-06 12:58:36 +02:00
|
|
|
/**
|
2018-09-06 14:52:01 +02:00
|
|
|
* @ORM\OneToOne(targetEntity="AbstractSource")
|
|
|
|
* @ORM\JoinColumn(name="source_id", referencedColumnName="id")
|
2018-09-12 22:25:22 +02:00
|
|
|
*
|
2018-09-06 12:58:36 +02:00
|
|
|
* @var SourceInterface
|
|
|
|
*/
|
|
|
|
protected $source;
|
2018-09-12 22:25:22 +02:00
|
|
|
|
|
|
|
public function getSource(): SourceInterface
|
|
|
|
{
|
2018-09-06 12:58:36 +02:00
|
|
|
return $this->source;
|
|
|
|
}
|
2018-09-12 22:25:22 +02:00
|
|
|
|
|
|
|
public function setSource(SourceInterface $source): void
|
|
|
|
{
|
2018-09-06 12:58:36 +02:00
|
|
|
$this->source = $source;
|
|
|
|
}
|
|
|
|
}
|