vendor/fourtwosix/status-bundle/src/Entity/SchedulingEntity.php line 12

Open in your IDE?
  1. <?php
  2. namespace Fourtwosix\StatusBundle\Entity;
  3. use DateTime;
  4. use Doctrine\ORM\Mapping\Column;
  5. use Doctrine\ORM\Mapping\Entity;
  6. use Doctrine\ORM\Mapping\GeneratedValue;
  7. use Doctrine\ORM\Mapping\Id;
  8. #[Entity()]
  9. class SchedulingEntity
  10. {
  11.     #[Id]
  12.     #[GeneratedValue]
  13.     #[Column]
  14.     private int $id;
  15.     #[Column(length255)]
  16.     private string $name;
  17.     #[Column]
  18.     private int $maxHoursLastExecution;
  19.     #[Column]
  20.     private DateTime $lastStarted;
  21.     #[Column(nullabletrue)]
  22.     private ?DateTime $lastFinished;
  23.     /**
  24.      * @return int
  25.      */
  26.     public function getId(): int
  27.     {
  28.         return $this->id;
  29.     }
  30.     /**
  31.      * @param int $id
  32.      * @return SchedulingEntity
  33.      */
  34.     public function setId(int $id): SchedulingEntity
  35.     {
  36.         $this->id $id;
  37.         return $this;
  38.     }
  39.     /**
  40.      * @return string
  41.      */
  42.     public function getName(): string
  43.     {
  44.         return $this->name;
  45.     }
  46.     /**
  47.      * @param string $name
  48.      * @return SchedulingEntity
  49.      */
  50.     public function setName(string $name): SchedulingEntity
  51.     {
  52.         $this->name $name;
  53.         return $this;
  54.     }
  55.     /**
  56.      * @return int
  57.      */
  58.     public function getMaxHoursLastExecution(): int
  59.     {
  60.         return $this->maxHoursLastExecution;
  61.     }
  62.     /**
  63.      * @param int $maxHoursLastExecution
  64.      * @return SchedulingEntity
  65.      */
  66.     public function setMaxHoursLastExecution(int $maxHoursLastExecution): SchedulingEntity
  67.     {
  68.         $this->maxHoursLastExecution $maxHoursLastExecution;
  69.         return $this;
  70.     }
  71.     /**
  72.      * @return DateTime
  73.      */
  74.     public function getLastStarted(): DateTime
  75.     {
  76.         return $this->lastStarted;
  77.     }
  78.     /**
  79.      * @param DateTime $lastStarted
  80.      * @return SchedulingEntity
  81.      */
  82.     public function setLastStarted(DateTime $lastStarted): SchedulingEntity
  83.     {
  84.         $this->lastStarted $lastStarted;
  85.         return $this;
  86.     }
  87.     /**
  88.      * @return ?DateTime
  89.      */
  90.     public function getLastFinished(): ?DateTime
  91.     {
  92.         return $this->lastFinished;
  93.     }
  94.     /**
  95.      * @param ?DateTime $lastFinished
  96.      * @return SchedulingEntity
  97.      */
  98.     public function setLastFinished(?DateTime $lastFinished): SchedulingEntity
  99.     {
  100.         $this->lastFinished $lastFinished;
  101.         return $this;
  102.     }
  103. }