| 1 | <?php |
||
| 13 | class Event |
||
| 14 | { |
||
| 15 | use ORMBehaviors\Timestampable\Timestampable; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * @var int |
||
| 19 | * |
||
| 20 | * @ORM\Id |
||
| 21 | * @ORM\Column(name="id", type="integer") |
||
| 22 | * @ORM\GeneratedValue(strategy="AUTO") |
||
| 23 | */ |
||
| 24 | protected $id; |
||
| 25 | |||
| 26 | /** |
||
| 27 | * @var string |
||
| 28 | * |
||
| 29 | * @Assert\NotBlank() |
||
| 30 | * @Assert\Length(max="191") |
||
| 31 | * |
||
| 32 | * @ORM\Column(type="string", length=191) |
||
| 33 | */ |
||
| 34 | protected $name; |
||
| 35 | |||
| 36 | /** |
||
| 37 | * @var string |
||
| 38 | * |
||
| 39 | * @Assert\NotBlank() |
||
| 40 | * |
||
| 41 | * @ORM\Column(type="text") |
||
| 42 | */ |
||
| 43 | protected $body; |
||
| 44 | |||
| 45 | public function __construct(string $name, string $body) |
||
| 50 | |||
| 51 | /** |
||
| 52 | * @return int |
||
| 53 | */ |
||
| 54 | public function getId(): ?int |
||
| 58 | |||
| 59 | /** |
||
| 60 | * @param int $id |
||
| 61 | * |
||
| 62 | * @return Event |
||
| 63 | */ |
||
| 64 | public function setId(int $id): self |
||
| 70 | |||
| 71 | /** |
||
| 72 | * @return string |
||
| 73 | */ |
||
| 74 | public function getName(): string |
||
| 78 | |||
| 79 | /** |
||
| 80 | * @param string $name |
||
| 81 | * |
||
| 82 | * @return Event |
||
| 83 | */ |
||
| 84 | public function setName(string $name): self |
||
| 90 | |||
| 91 | /** |
||
| 92 | * @return string |
||
| 93 | */ |
||
| 94 | public function getBody(): string |
||
| 98 | |||
| 99 | /** |
||
| 100 | * @param string $body |
||
| 101 | * |
||
| 102 | * @return Event |
||
| 103 | */ |
||
| 104 | public function setBody(string $body): self |
||
| 110 | } |
||
| 111 |