public function addArticle(Article $article) { if (!$this->articles->contains($article)) { $article->setFeed($this); $this->articles->add($article); } }
/** * @param Article $article * @return Tag */ public function addArticle(Article $article) { if (!$this->articles->contains($article)) { $this->articles->add($article); } return $this; }
/** * Remove article * * @param Article $article * @return Issue */ public function removeArticle(Article $article) { if ($this->articles->contains($article)) { $this->articles->removeElement($article); $article->setIssue(null); } }
/** * Check if an article exists in the page * * @param Article $article * * @return bool */ public function hasArticle(Article $article = null) { return $this->articles->contains($article); }