AppBundle\Entity\Post::removeComment PHP Method

removeComment() public method

public removeComment ( Comment $comment )
$comment Comment
    public function removeComment(Comment $comment)
    {
        $this->comments->removeElement($comment);
        $comment->setPost(null);
    }

Usage Example

 /**
  * {@inheritDoc}
  */
 public function removeComment(\AppBundle\Entity\Comment $comments)
 {
     $this->__initializer__ && $this->__initializer__->__invoke($this, 'removeComment', array($comments));
     return parent::removeComment($comments);
 }