Newscoop\Subscription\Section::getName PHP Method

getName() public method

Get name
public getName ( ) : string
return string
    public function getName()
    {
        if ($this->subscription->getPublication() === null) {
            return '';
        }
        foreach ($this->subscription->getPublication()->getIssues() as $issue) {
            if ($this->hasLanguage() && $issue->getLanguage() !== $this->language) {
                continue;
            }
            foreach ($issue->getSections() as $section) {
                if ($section->getNumber() == $this->sectionNumber) {
                    return $section->getName();
                }
            }
        }
        return '';
    }

Usage Example

 public function getName()
 {
     $this->__load();
     return parent::getName();
 }
All Usage Examples Of Newscoop\Subscription\Section::getName