function GitHub::__construct
Constructor.
Parameters
IOInterface $io The IO instance:
Config $config The composer configuration:
ProcessExecutor $process Process instance, injectable for mocking:
HttpDownloader $httpDownloader Remote Filesystem, injectable for mocking:
File
-
vendor/
composer/ composer/ src/ Composer/ Util/ GitHub.php, line 43
Class
- GitHub
- @author Jordi Boggiano <j.boggiano@seld.be>
Namespace
Composer\UtilCode
public function __construct(IOInterface $io, Config $config, ?ProcessExecutor $process = null, ?HttpDownloader $httpDownloader = null) {
$this->io = $io;
$this->config = $config;
$this->process = $process ?: new ProcessExecutor($io);
$this->httpDownloader = $httpDownloader ?: Factory::createHttpDownloader($this->io, $config);
}