src/Entity/OperationCode/DrawCode.php line 14

Open in your IDE?
  1. <?php
  2. namespace App\Entity\OperationCode;
  3. use App\Entity\Operation\Draw as OperationDraw;
  4. use App\Entity\Participation\Draw as ParticipationDraw;
  5. use App\Repository\OperationCode\DrawCodeRepository;
  6. use Doctrine\ORM\Mapping as ORM;
  7. use Symfony\Component\Serializer\Annotation\SerializedName;
  8. /**
  9.  * @ORM\Entity(repositoryClass=DrawCodeRepository::class)
  10.  */
  11. class DrawCode extends OperationCode
  12. {
  13.     /**
  14.      * @ORM\ManyToOne(targetEntity=OperationDraw::class)
  15.      * @ORM\JoinColumn(name="operation_id")
  16.      * @SerializedName("operation")
  17.      */
  18.     private OperationDraw $operation;
  19.     /**
  20.      * @ORM\ManyToOne(targetEntity=ParticipationDraw::class, inversedBy="operationCodes")
  21.      * @ORM\JoinColumn(name="participation_id", nullable=true)
  22.      * @SerializedName("participation")
  23.      */
  24.     private ?ParticipationDraw $participation;
  25.     public function getOperation(): OperationDraw
  26.     {
  27.         return $this->operation;
  28.     }
  29.     public function setOperation(OperationDraw $operation): DrawCode
  30.     {
  31.         $this->operation $operation;
  32.         return $this;
  33.     }
  34.     public function getParticipation(): ?ParticipationDraw
  35.     {
  36.         return $this->participation;
  37.     }
  38.     public function setParticipation(ParticipationDraw $participation): self
  39.     {
  40.         $this->participation $participation;
  41.         return $this;
  42.     }
  43. }