src/Entity/GwocDomain.php line 15

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use Symfony\Component\Serializer\Annotation\MaxDepth;
  5. use DateTimeInterface;
  6. /**
  7.  * GwocDomain
  8.  *
  9.  * @ORM\Table(name="gwoc_domains", uniqueConstraints={@ORM\UniqueConstraint(name="domain", columns={"domain", "status", "ip_address"})})
  10.  * @ORM\Entity
  11.  */
  12. class GwocDomain extends Entity
  13. {
  14.     /**
  15.      * @var int
  16.      *
  17.      * @ORM\Column(name="id", type="bigint", nullable=false, options={"unsigned"=true})
  18.      * @ORM\Id
  19.      * @ORM\GeneratedValue(strategy="IDENTITY")
  20.      */
  21.     private $id;
  22.     /**
  23.      * @var \Account
  24.      *
  25.      * @MaxDepth(1)
  26.      * @ORM\ManyToOne(targetEntity="Account", fetch="EAGER")
  27.      * @ORM\JoinColumns({
  28.      *   @ORM\JoinColumn(name="account_id", referencedColumnName="id")
  29.      * })
  30.      */
  31.     private $account;
  32.     /**
  33.      * @var \Zone
  34.      *
  35.      * @MaxDepth(1)
  36.      * @ORM\ManyToOne(targetEntity="Zone")
  37.      * @ORM\JoinColumns({
  38.      *   @ORM\JoinColumn(name="zone_id", referencedColumnName="id")
  39.      * })
  40.      */
  41.     private $zone;
  42.     /**
  43.      * @var \DateTime
  44.      *
  45.      * @ORM\Column(name="created", type="datetime", nullable=false, options={"default"="CURRENT_TIMESTAMP"})
  46.      */
  47.     private $created 'CURRENT_TIMESTAMP';
  48.     /**
  49.      * @var string
  50.      *
  51.      * @ORM\Column(name="domain", type="string", length=255, nullable=false)
  52.      */
  53.     private $domain;
  54.     /**
  55.      * @var string
  56.      *
  57.      * @ORM\Column(name="ip_address", type="ipv4", nullable=false)
  58.      */
  59.     private $ipAddress;
  60.     /**
  61.      * @var string
  62.      *
  63.      * @ORM\Column(name="status", type="string", length=0, nullable=false, options={"default"="pending"})
  64.      */
  65.     private $status 'pending';
  66.     /**
  67.      * @var array
  68.      *
  69.      * @ORM\Column(name="expect", type="numeric_array", length=0, nullable=false, options={"default"="0,3,6,9","comment"="Specifies results forwarded to origin"})
  70.      */
  71.     private $expect '0,3,6,9';
  72.     /**
  73.      * @var array
  74.      *
  75.      * @ORM\Column(name="flags", type="simple_array", length=0, nullable=false, options={"comment"="Additional configuration flags"})
  76.      */
  77.     private $flags;
  78.     /**
  79.      * @var string|null
  80.      *
  81.      * 
  82.      * @ORM\Column(name="protocol", type="string", length=0, nullable=true)
  83.      */
  84.     private $protocol;
  85.     public function getId(): ?int
  86.     {
  87.         return $this->id;
  88.     }
  89.     public function getAccount(): ?Account
  90.     {
  91.         return $this->account;
  92.     }
  93.     public function setAccount(?Account $account): self
  94.     {
  95.         $this->account $account;
  96.         return $this;
  97.     }
  98.     public function getZone(): ?Zone
  99.     {
  100.         return $this->zone;
  101.     }
  102.     public function setZone(?Zone $zone): self
  103.     {
  104.         $this->zone $zone;
  105.         return $this;
  106.     }
  107.     public function getCreated(): ?\DateTimeInterface
  108.     {
  109.         return $this->created;
  110.     }
  111.     public function setCreated(\DateTimeInterface $created): self
  112.     {
  113.         $this->created $created;
  114.         return $this;
  115.     }
  116.     public function getDomain(): ?string
  117.     {
  118.         return $this->domain;
  119.     }
  120.     public function setDomain(string $domain): self
  121.     {
  122.         $this->domain $domain;
  123.         return $this;
  124.     }
  125.     public function getIpAddress(): ?string
  126.     {
  127.         return $this->ipAddress;
  128.     }
  129.     public function setIpAddress(string $ipAddress): self
  130.     {
  131.         $this->ipAddress $ipAddress;
  132.         return $this;
  133.     }
  134.     public function getStatus(): ?string
  135.     {
  136.         return $this->status;
  137.     }
  138.     public function setStatus(string $status): self
  139.     {
  140.         $this->status $status;
  141.         return $this;
  142.     }
  143.     public function getExpect(): ?array
  144.     {
  145.         return $this->expect;
  146.     }
  147.     public function setExpect(array $expect): self
  148.     {
  149.         $this->expect $expect;
  150.         return $this;
  151.     }
  152.     public function getFlags(): ?array
  153.     {
  154.         return $this->flags;
  155.     }
  156.     public function setFlags(array $flags): self
  157.     {
  158.         $this->flags $flags;
  159.         return $this;
  160.     }
  161.     public function getProtocol(): ?string
  162.     {
  163.         return $this->protocol;
  164.     }
  165.     public function setProtocol(?string $protocol): self
  166.     {
  167.         $this->protocol $protocol;
  168.         return $this;
  169.     }
  170. }