<?php
namespace AdminBundle\Entity;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\ORM\Mapping as ORM;
/**
* Objectives
*/
#[ORM\Table(name: 'objectives')]
#[ORM\Entity(repositoryClass: \AdminBundle\Repository\ObjectivesRepository::class)]
class Objectives
{
/**
* @var int
*/
#[ORM\Column(name: 'id', type: 'integer')]
#[ORM\Id]
#[ORM\GeneratedValue(strategy: 'AUTO')]
private $id;
/**
* @var string
*/
#[ORM\Column(name: 'title', type: 'string', length: 255)]
private $title;
/**
* @var string
*/
#[ORM\Column(name: 'description', type: 'text', length: 4294967295, nullable: true)]
private $description;
/**
* @var float
*/
#[ORM\Column(name: 'price', type: 'float', scale: 2, nullable: true)]
private $price;
/**
* @var string
*/
#[ORM\Column(name: 'important_details', type: 'text', length: 4294967295, nullable: true)]
private $importantDetails;
#[ORM\OneToMany(targetEntity: \Images::class, mappedBy: 'objectives')]
private $images;
#[ORM\ManyToMany(targetEntity: \Tours::class, mappedBy: 'objectives', cascade: ['persist', 'remove'])]
private $tours;
/**
* Constructor
*/
public function __construct()
{
$this->images = new ArrayCollection();
$this->tours = new ArrayCollection();
}
/**
* Get id
*
* @return int
*/
public function getId()
{
return $this->id;
}
/**
* Set title
*
* @param string $title
*
* @return Objectives
*/
public function setTitle($title)
{
$this->title = $title;
return $this;
}
/**
* Get title
*
* @return string
*/
public function getTitle()
{
return $this->title;
}
/**
* Set description
*
* @param string $description
*
* @return Objectives
*/
public function setDescription($description)
{
$this->description = $description;
return $this;
}
/**
* Get description
*
* @return string
*/
public function getDescription()
{
return $this->description;
}
/**
* Set importantDetails
*
* @param string $importantDetails
*
* @return Objectives
*/
public function setImportantDetails($importantDetails)
{
$this->importantDetails = $importantDetails;
return $this;
}
/**
* Get importantDetails
*
* @return string
*/
public function getImportantDetails()
{
return $this->importantDetails;
}
/**
* Add image
*
* @param \AdminBundle\Entity\Images $image
*
* @return Objectives
*/
public function addImage(Images $image)
{
$this->images[] = $image;
return $this;
}
/**
* Remove image
*
* @param \AdminBundle\Entity\Images $image
*/
public function removeImage(Images $image)
{
$this->images->removeElement($image);
}
/**
* Get images
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getImages()
{
return $this->images;
}
/**
* Add tour
*
* @param \AdminBundle\Entity\Tours $tour
*
* @return Objectives
*/
public function addTour(Tours $tour)
{
$this->tours[] = $tour;
return $this;
}
/**
* Remove tour
*
* @param \AdminBundle\Entity\Objectives $tour
*/
public function removeTour(Objectives $tour)
{
$this->tours->removeElement($tour);
}
/**
* Get tour
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getTours()
{
return $this->tours;
}
/**
* @return float
*/
public function getPrice()
{
return $this->price;
}
/**
* @param float $price
*/
public function setPrice($price)
{
$this->price = $price;
}
}