Newscoop\Entity\User::getComments PHP Метод

getComments() публичный Метод

Get a User's comments which are associated with his User account.
public getComments ( ) : array
Результат array
    public function getComments()
    {
        $comments = array();
        foreach ($this->commenters as $commenter) {
            foreach ($commenter->getComments() as $comment) {
                $comments[] = $comment;
            }
        }
        return $comments;
    }

Usage Example

Пример #1
0
 public function getComments()
 {
     $this->__load();
     return parent::getComments();
 }