src/Flexy/Apps/TransportBundle/Entity/Vehicle.php line 11

  1. <?php
  2. namespace App\Flexy\Apps\TransportBundle\Entity;
  3. use ApiPlatform\Metadata\ApiResource;
  4. use App\Repository\Flexy\TransportBundle\Entity\VehicleRepository;
  5. use Doctrine\ORM\Mapping as ORM;
  6. #[ORM\Entity(repositoryClassVehicleRepository::class)]
  7. #[ApiResource]
  8. class Vehicle
  9. {
  10.     #[ORM\Id]
  11.     #[ORM\GeneratedValue]
  12.     #[ORM\Column]
  13.     private ?int $id null;
  14.     #[ORM\Column(length255nullabletrue)]
  15.     private ?string $model null;
  16.     #[ORM\Column(length255nullabletrue)]
  17.     private ?string $name null;
  18.     public function getId(): ?int
  19.     {
  20.         return $this->id;
  21.     }
  22.     public function getModel(): ?string
  23.     {
  24.         return $this->model;
  25.     }
  26.     public function setModel(?string $model): self
  27.     {
  28.         $this->model $model;
  29.         return $this;
  30.     }
  31.     public function getName(): ?string
  32.     {
  33.         return $this->name;
  34.     }
  35.     public function setName(?string $name): self
  36.     {
  37.         $this->name $name;
  38.         return $this;
  39.     }
  40. }