/** * @param Tag $tag * @return bool */ public function removeTag(Tag $tag) { if ($this->hasTag($tag)) { return $this->tags->removeElement($tag); } return false; }
/** * Remove tags * @param Collection|Tag[] $tags * @return self */ public function removeTags(Collection $tags) { foreach ($tags as $tag) { $this->tags->removeElement($tag); } return $this; }
/** * @param Article $article * @return bool */ public function removeArticle(Article $article) { if ($this->hasArticle($article)) { return $this->articles->removeElement($article); } return false; }
/** * @param Tag $tag */ public function removeTag(Tag $tag) { $tag->setNews(null); $this->tags->removeElement($tag); }
/** * @param Tag $tag */ public function removeTag(Tag $tag) { $this->tags->removeElement($tag); }