/** * Add tag * * @param \Perso\GalerieBundle\Entity\Tag $tag * * @return Photo */ public function addTag(\Perso\GalerieBundle\Entity\Tag $tag) { $this->tags[] = $tag; $tag->addPhoto($this); return $this; }