Sulu\Bundle\MediaBundle\Api\Media::getTitle PHP Method

getTitle() public method

public getTitle ( ) : string
return string
    public function getTitle()
    {
        if (!$this->getLocalizedMeta()) {
            return;
        }
        return $this->getLocalizedMeta()->getTitle();
    }

Usage Example

Example #1
0
 private function serialize(Media $media)
 {
     return ['id' => $media->getId(), 'title' => $media->getTitle(), 'tags' => array_map(function ($tag) {
         return $tag->getName();
     }, $media->getTags())];
 }
All Usage Examples Of Sulu\Bundle\MediaBundle\Api\Media::getTitle