src/Entity/Analytics/ServersUsage.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity\Analytics;
  3. use App\Entity\BaseEntity;
  4. use App\Repository\Analytics\ServersUsageRepository;
  5. use Doctrine\DBAL\Types\Types;
  6. use Doctrine\ORM\Mapping as ORM;
  7. use Symfony\Bridge\Doctrine\IdGenerator\UuidGenerator;
  8. #[ORM\Entity(repositoryClassServersUsageRepository::class)]
  9. class ServersUsage  extends BaseEntity
  10. {
  11.     #[ORM\Id]
  12.     #[ORM\Column(type'guid'uniquetrue)]
  13.     #[ORM\GeneratedValue(strategy'CUSTOM')]
  14.     #[ORM\CustomIdGenerator(class: UuidGenerator::class)]
  15.     private ?string $id null;
  16.     #[ORM\Column(typeTypes::DATE_MUTABLE)]
  17.     private ?\DateTimeInterface $date null;
  18.     #[ORM\Column(length255)]
  19.     private ?string $ip null;
  20.     #[ORM\Column(typeTypes::BIGINT)]
  21.     private ?string $totalUsage null;
  22.     public function __construct()
  23.     {
  24.         parent::__construct();
  25.         $this->setTotalUsage(0);
  26.     }
  27.     public function getId(): ?string
  28.     {
  29.         return $this->id;
  30.     }
  31.     public function getDate(): ?\DateTimeInterface
  32.     {
  33.         return $this->date;
  34.     }
  35.     public function setDate(\DateTimeInterface $date): static
  36.     {
  37.         $this->date $date;
  38.         return $this;
  39.     }
  40.     public function getIp(): ?string
  41.     {
  42.         return $this->ip;
  43.     }
  44.     public function setIp(string $ip): static
  45.     {
  46.         $this->ip $ip;
  47.         return $this;
  48.     }
  49.     public function getTotalUsage(): ?string
  50.     {
  51.         return $this->totalUsage;
  52.     }
  53.     public function setTotalUsage(string $totalUsage): static
  54.     {
  55.         $this->totalUsage $totalUsage;
  56.         return $this;
  57.     }
  58. }