PHP Класс Gush\Helper\DownloadHelper

Some parts were borrowed from the symfony-installer.
Наследование: extends Symfony\Component\Console\Helper\Helper, implements Gush\Helper\OutputAwareInterface
Показать файл Открыть проект

Открытые методы

Метод Описание
__construct ( FilesystemHelper $filesystemHelper )
downloadFile ( string $url, boolean $progress = true ) Download a file from the URL to the destination.
getName ( )
setOutput ( Symfony\Component\Console\Output\OutputInterface $output )

Защищенные методы

Метод Описание
getGuzzleClient ( ) : Client Returns the Guzzle client configured according to the system environment (e.g. it takes into account whether it should use a proxy server or not).

Приватные методы

Метод Описание
formatSize ( integer $bytes ) : string Utility method to show the number of bytes in a readable format.

Описание методов

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

public __construct ( FilesystemHelper $filesystemHelper )
$filesystemHelper FilesystemHelper

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

Download a file from the URL to the destination.
public downloadFile ( string $url, boolean $progress = true )
$url string Fully qualified URL to the file.
$progress boolean Show the progressbar when downloading.

getGuzzleClient() защищенный Метод

Returns the Guzzle client configured according to the system environment (e.g. it takes into account whether it should use a proxy server or not).
protected getGuzzleClient ( ) : Client
Результат GuzzleHttp\Client

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

public getName ( )

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

public setOutput ( Symfony\Component\Console\Output\OutputInterface $output )
$output Symfony\Component\Console\Output\OutputInterface