X-Git-Url: https://git.rapsys.eu/airbundle/blobdiff_plain/61e51b1afe272422dd8297ec57c3db8cfb1bb441..d7a420642db08edb589e885292442e58961b19dc:/Entity/Location.php diff --git a/Entity/Location.php b/Entity/Location.php index 73fc6b9..e57f235 100644 --- a/Entity/Location.php +++ b/Entity/Location.php @@ -66,11 +66,17 @@ class Location { */ private $sessions; + /** + * @var \Doctrine\Common\Collections\Collection + */ + private $snippets; + /** * Constructor */ public function __construct() { $this->sessions = new \Doctrine\Common\Collections\ArrayCollection(); + $this->snippets = new \Doctrine\Common\Collections\ArrayCollection(); } /** @@ -333,6 +339,37 @@ class Location { return $this->sessions; } + /** + * Add snippet + * + * @param \Rapsys\AirBundle\Entity\Snippet $snippet + * + * @return Location + */ + public function addSnippet(\Rapsys\AirBundle\Entity\Snippet $snippet) { + $this->snippets[] = $snippet; + + return $this; + } + + /** + * Remove snippet + * + * @param \Rapsys\AirBundle\Entity\Snippet $snippet + */ + public function removeSnippet(\Rapsys\AirBundle\Entity\Snippet $snippet) { + $this->snippets->removeElement($snippet); + } + + /** + * Get snippets + * + * @return \Doctrine\Common\Collections\Collection + */ + public function getSnippets() { + return $this->snippets; + } + /** * Returns a string representation of the location *