<?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\MaxDepth;
use DateTimeInterface;
/**
* GwocDomain
*
* @ORM\Table(name="gwoc_domains", uniqueConstraints={@ORM\UniqueConstraint(name="domain", columns={"domain", "status", "ip_address"})})
* @ORM\Entity
*/
class GwocDomain extends Entity
{
/**
* @var int
*
* @ORM\Column(name="id", type="bigint", nullable=false, options={"unsigned"=true})
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* @var \Account
*
* @MaxDepth(1)
* @ORM\ManyToOne(targetEntity="Account", fetch="EAGER")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="account_id", referencedColumnName="id")
* })
*/
private $account;
/**
* @var \Zone
*
* @MaxDepth(1)
* @ORM\ManyToOne(targetEntity="Zone")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="zone_id", referencedColumnName="id")
* })
*/
private $zone;
/**
* @var \DateTime
*
* @ORM\Column(name="created", type="datetime", nullable=false, options={"default"="CURRENT_TIMESTAMP"})
*/
private $created = 'CURRENT_TIMESTAMP';
/**
* @var string
*
* @ORM\Column(name="domain", type="string", length=255, nullable=false)
*/
private $domain;
/**
* @var string
*
* @ORM\Column(name="ip_address", type="ipv4", nullable=false)
*/
private $ipAddress;
/**
* @var string
*
* @ORM\Column(name="status", type="string", length=0, nullable=false, options={"default"="pending"})
*/
private $status = 'pending';
/**
* @var array
*
* @ORM\Column(name="expect", type="numeric_array", length=0, nullable=false, options={"default"="0,3,6,9","comment"="Specifies results forwarded to origin"})
*/
private $expect = '0,3,6,9';
/**
* @var array
*
* @ORM\Column(name="flags", type="simple_array", length=0, nullable=false, options={"comment"="Additional configuration flags"})
*/
private $flags;
/**
* @var string|null
*
*
* @ORM\Column(name="protocol", type="string", length=0, nullable=true)
*/
private $protocol;
public function getId(): ?int
{
return $this->id;
}
public function getAccount(): ?Account
{
return $this->account;
}
public function setAccount(?Account $account): self
{
$this->account = $account;
return $this;
}
public function getZone(): ?Zone
{
return $this->zone;
}
public function setZone(?Zone $zone): self
{
$this->zone = $zone;
return $this;
}
public function getCreated(): ?\DateTimeInterface
{
return $this->created;
}
public function setCreated(\DateTimeInterface $created): self
{
$this->created = $created;
return $this;
}
public function getDomain(): ?string
{
return $this->domain;
}
public function setDomain(string $domain): self
{
$this->domain = $domain;
return $this;
}
public function getIpAddress(): ?string
{
return $this->ipAddress;
}
public function setIpAddress(string $ipAddress): self
{
$this->ipAddress = $ipAddress;
return $this;
}
public function getStatus(): ?string
{
return $this->status;
}
public function setStatus(string $status): self
{
$this->status = $status;
return $this;
}
public function getExpect(): ?array
{
return $this->expect;
}
public function setExpect(array $expect): self
{
$this->expect = $expect;
return $this;
}
public function getFlags(): ?array
{
return $this->flags;
}
public function setFlags(array $flags): self
{
$this->flags = $flags;
return $this;
}
public function getProtocol(): ?string
{
return $this->protocol;
}
public function setProtocol(?string $protocol): self
{
$this->protocol = $protocol;
return $this;
}
}