You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

69 satır
1.2KB

  1. <?php
  2. namespace Lc\CaracoleBundle\Model\Distribution;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use Lc\SovBundle\Doctrine\EntityInterface;
  5. /**
  6. * @ORM\MappedSuperclass()
  7. */
  8. abstract class DistributionModel implements DistributionInterface, EntityInterface
  9. {
  10. /**
  11. * @ORM\Column(type="integer")
  12. */
  13. protected $cycleNumber;
  14. /**
  15. * @ORM\Column(type="integer")
  16. */
  17. protected $year;
  18. /**
  19. * @ORM\Column(type="string", length=32)
  20. */
  21. protected $cycleType;
  22. public function __toString()
  23. {
  24. return $this->getCycleNumber() . '/' . $this->getYear();
  25. }
  26. public function getCycleNumber(): ?int
  27. {
  28. return $this->cycleNumber;
  29. }
  30. public function setCycleNumber(int $cycleNumber): self
  31. {
  32. $this->cycleNumber = $cycleNumber;
  33. return $this;
  34. }
  35. public function getYear(): ?int
  36. {
  37. return $this->year;
  38. }
  39. public function setYear(int $year): self
  40. {
  41. $this->year = $year;
  42. return $this;
  43. }
  44. public function getCycleType(): ?string
  45. {
  46. return $this->cycleType;
  47. }
  48. public function setCycleType(string $cycleType): self
  49. {
  50. $this->cycleType = $cycleType;
  51. return $this;
  52. }
  53. }