<?php
namespace App\Entity;
use App\Entity\GroundCarrier\ContactPerson;
use App\Repository\GroundCarrierRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass=GroundCarrierRepository::class)
*/
class GroundCarrier
{
/**
* @ORM\Id
* @ORM\GeneratedValue
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\Column(type="string", length=255)
*/
private $name;
/**
* @ORM\Column(type="boolean")
*/
private $isProsecutor;
/**
* @ORM\Column(type="boolean")
*/
private $isLastMile;
/**
* @ORM\Column(type="string", length=255)
*/
private $catNumber;
/**
* @ORM\Column(type="string", length=255)
*/
private $rfc;
/**
* @ORM\Column(type="string", length=1024)
*/
private $street;
/**
* @ORM\Column(type="string", length=255)
*/
private $exteriorNumber;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $interiorNumber;
/**
* @ORM\Column(type="string", length=255)
*/
private $suburb;
/**
* @ORM\Column(type="string", length=255)
*/
private $delegation;
/**
* @ORM\Column(type="string", length=255)
*/
private $postalCode;
/**
* @ORM\Column(type="string", length=255)
*/
private $estate;
/**
* @ORM\Column(type="string", length=255)
*/
private $managerName;
/**
* @ORM\Column(type="string", length=255)
*/
private $managerRange;
/**
* @ORM\Column(type="string", length=255)
*/
private $managerLastName;
/**
* @ORM\Column(type="string", length=255)
*/
private $managerSecondLastName;
/**
* @ORM\Column(type="string", length=255)
*/
private $managerPhone;
/**
* @ORM\Column(type="string", length=255)
*/
private $managerEmail;
/**
* @ORM\OneToMany(targetEntity=ContactPerson::class, mappedBy="groundCarrier", cascade={"persist"})
*/
private $contactPeople;
public function __construct()
{
$this->contactPeople = new ArrayCollection();
}
public function getId(): ?int
{
return $this->id;
}
public function getName(): ?string
{
return $this->name;
}
public function setName(string $name): self
{
$this->name = $name;
return $this;
}
public function isIsProsecutor(): ?bool
{
return $this->isProsecutor;
}
public function setIsProsecutor(bool $isProsecutor): self
{
$this->isProsecutor = $isProsecutor;
return $this;
}
public function isIsLastMile(): ?bool
{
return $this->isLastMile;
}
public function setIsLastMile(bool $isLastMile): self
{
$this->isLastMile = $isLastMile;
return $this;
}
public function getCatNumber(): ?string
{
return $this->catNumber;
}
public function setCatNumber(string $catNumber): self
{
$this->catNumber = $catNumber;
return $this;
}
public function getRfc(): ?string
{
return $this->rfc;
}
public function setRfc(string $rfc): self
{
$this->rfc = $rfc;
return $this;
}
public function getStreet(): ?string
{
return $this->street;
}
public function setStreet(string $street): self
{
$this->street = $street;
return $this;
}
public function getExteriorNumber(): ?string
{
return $this->exteriorNumber;
}
public function setExteriorNumber(string $exteriorNumber): self
{
$this->exteriorNumber = $exteriorNumber;
return $this;
}
public function getInteriorNumber(): ?string
{
return $this->interiorNumber;
}
public function setInteriorNumber(?string $interiorNumber): self
{
$this->interiorNumber = $interiorNumber;
return $this;
}
public function getSuburb(): ?string
{
return $this->suburb;
}
public function setSuburb(string $suburb): self
{
$this->suburb = $suburb;
return $this;
}
public function getDelegation(): ?string
{
return $this->delegation;
}
public function setDelegation(string $delegation): self
{
$this->delegation = $delegation;
return $this;
}
public function getPostalCode(): ?string
{
return $this->postalCode;
}
public function setPostalCode(string $postalCode): self
{
$this->postalCode = $postalCode;
return $this;
}
public function getEstate(): ?string
{
return $this->estate;
}
public function setEstate(string $estate): self
{
$this->estate = $estate;
return $this;
}
public function getManagerName(): ?string
{
return $this->managerName;
}
public function setManagerName(string $managerName): self
{
$this->managerName = $managerName;
return $this;
}
public function getManagerRange(): ?string
{
return $this->managerRange;
}
public function setManagerRange(string $managerRange): self
{
$this->managerRange = $managerRange;
return $this;
}
public function getManagerLastName(): ?string
{
return $this->managerLastName;
}
public function setManagerLastName(string $managerLastName): self
{
$this->managerLastName = $managerLastName;
return $this;
}
public function getManagerSecondLastName(): ?string
{
return $this->managerSecondLastName;
}
public function setManagerSecondLastName(string $managerSecondLastName): self
{
$this->managerSecondLastName = $managerSecondLastName;
return $this;
}
public function getManagerPhone(): ?string
{
return $this->managerPhone;
}
public function setManagerPhone(string $managerPhone): self
{
$this->managerPhone = $managerPhone;
return $this;
}
public function getManagerEmail(): ?string
{
return $this->managerEmail;
}
public function setManagerEmail(string $managerEmail): self
{
$this->managerEmail = $managerEmail;
return $this;
}
/**
* @return Collection<int, ContactPerson>
*/
public function getContactPeople(): Collection
{
return $this->contactPeople;
}
public function addContactPerson(ContactPerson $contactPerson): self
{
if (!$this->contactPeople->contains($contactPerson)) {
$this->contactPeople[] = $contactPerson;
$contactPerson->setGroundCarrier($this);
}
return $this;
}
public function removeContactPerson(ContactPerson $contactPerson): self
{
if ($this->contactPeople->removeElement($contactPerson)) {
// set the owning side to null (unless already changed)
if ($contactPerson->getGroundCarrier() === $this) {
$contactPerson->setGroundCarrier(null);
}
}
return $this;
}
}