public function getIconByExtension(string $extension, bool $include_full_path = false): string
    {
        $data = $this->getData();
        $extension = strtolower($extension);
        $res = $data[$extension] ?? '';

        if (!$res) {
            $res = $this->unknown_extension_icon;
        }

        if ($include_full_path) {
            $res = $this->directory_with_icons . $res;
        }

        return $res;
    }
public function getIconByExtension(string $extension, bool $include_full_path = false): string
    {
        $data = $this->getData();
        $extension = strtolower($extension);
        $res = $data[$extension] ?? '';

        if (!$res) {
            $res = $this->unknown_extension_icon;
        }

        if ($include_full_path) {
            $res = $this->directory_with_icons . $res;
        }

        return $res;
    }
public function getIconByExtension ( string $ extension , bool $ include_full_path = false ) : string { $ data = $ this -> getData ( ) ; $ extension = strtolower ( $ extension ) ; $ res = $ data [ $ extension ] ?? '' ; if ( ! $ res ) { $ res = $ this -> unknown_extension_icon ; } if ( $ include_full_path ) { $ res = $ this -> directory_with_icons . $ res ; } return $ res ; }
Get icon for file by its extension

@param string $extension - file's extension
@param bool $include_full_path - include in result relative path to file or not

@return string
Get icon for file by its extension