Gc\Component\IterableInterface::getIcon PHP Method

getIcon() public method

Get Icon
public getIcon ( ) : string
return string
    public function getIcon();

Usage Example

Beispiel #1
0
 /**
  * Render Icon
  *
  * @param IterableInterface $iterator Document
  *
  * @return string
  */
 protected static function renderIcon(IterableInterface $iterator)
 {
     if ($iterator->getIcon() == 'folder') {
         $html = '<ins
             style="background:url(/media/icons/folder.gif) no-repeat scroll 0 0;"
             class="jstree-icon">&nbsp;</ins>';
     } else {
         $html = '<ins
             style="background:url(' . $iterator->getIcon() . ') no-repeat scroll 0 0;"
             class="jstree-icon">&nbsp;</ins>';
     }
     return $html;
 }