diff --git a/src/Composer/Installer/MetapackageInstaller.php b/src/Composer/Installer/MetapackageInstaller.php index f5a2a43b6..936f72536 100644 --- a/src/Composer/Installer/MetapackageInstaller.php +++ b/src/Composer/Installer/MetapackageInstaller.php @@ -26,6 +26,7 @@ use Composer\DependencyResolver\Operation\UninstallOperation; */ class MetapackageInstaller implements InstallerInterface { + /** @var IOInterface */ private $io; public function __construct(IOInterface $io) diff --git a/src/Composer/Installer/ProjectInstaller.php b/src/Composer/Installer/ProjectInstaller.php index 5bae889dc..d03e97521 100644 --- a/src/Composer/Installer/ProjectInstaller.php +++ b/src/Composer/Installer/ProjectInstaller.php @@ -25,8 +25,11 @@ use Composer\Util\Filesystem; */ class ProjectInstaller implements InstallerInterface { + /** @var string */ private $installPath; + /** @var DownloadManager */ private $downloadManager; + /** @var Filesystem */ private $filesystem; public function __construct($installPath, DownloadManager $dm, Filesystem $fs) diff --git a/src/Composer/Installer/SuggestedPackagesReporter.php b/src/Composer/Installer/SuggestedPackagesReporter.php index 0e28e9d50..4db5931d3 100644 --- a/src/Composer/Installer/SuggestedPackagesReporter.php +++ b/src/Composer/Installer/SuggestedPackagesReporter.php @@ -29,7 +29,7 @@ class SuggestedPackagesReporter const MODE_BY_SUGGESTION = 4; /** - * @var array + * @var array */ protected $suggestedPackages = array(); diff --git a/src/Composer/Package/Version/StabilityFilter.php b/src/Composer/Package/Version/StabilityFilter.php index d502da257..8eda2033b 100644 --- a/src/Composer/Package/Version/StabilityFilter.php +++ b/src/Composer/Package/Version/StabilityFilter.php @@ -30,7 +30,7 @@ class StabilityFilter * @param string $stability one of 'stable', 'RC', 'beta', 'alpha' or 'dev' * @return bool true if any package name is acceptable */ - public static function isPackageAcceptable(array $acceptableStabilities, array $stabilityFlags, $names, $stability) + public static function isPackageAcceptable(array $acceptableStabilities, array $stabilityFlags, array $names, $stability) { foreach ($names as $name) { // allow if package matches the package-specific stability flag diff --git a/src/Composer/Platform/HhvmDetector.php b/src/Composer/Platform/HhvmDetector.php index a13559e0d..7bf1beb2c 100644 --- a/src/Composer/Platform/HhvmDetector.php +++ b/src/Composer/Platform/HhvmDetector.php @@ -18,11 +18,14 @@ use Symfony\Component\Process\ExecutableFinder; class HhvmDetector { - private static $hhvmVersion; + /** @var string|false|null */ + private static $hhvmVersion = null; + /** @var ?ExecutableFinder */ private $executableFinder; + /** @var ?ProcessExecutor */ private $processExecutor; - public function __construct(ExecutableFinder $executableFinder = null, ProcessExecutor $processExecutor = null) + public function __construct(ExecutableFinder $executableFinder = null, ProcessExecutor $processExecutor = null) { $this->executableFinder = $executableFinder; $this->processExecutor = $processExecutor; diff --git a/src/Composer/Platform/Runtime.php b/src/Composer/Platform/Runtime.php index 1cb09e4b1..4e9caff57 100644 --- a/src/Composer/Platform/Runtime.php +++ b/src/Composer/Platform/Runtime.php @@ -25,7 +25,7 @@ class Runtime } /** - * @param bool $constant + * @param string $constant * @param class-string $class * @return mixed */ diff --git a/src/Composer/Plugin/PreFileDownloadEvent.php b/src/Composer/Plugin/PreFileDownloadEvent.php index e4921621e..1c07d5ca6 100644 --- a/src/Composer/Plugin/PreFileDownloadEvent.php +++ b/src/Composer/Plugin/PreFileDownloadEvent.php @@ -48,7 +48,7 @@ class PreFileDownloadEvent extends Event private $context; /** - * @var array + * @var mixed[] */ private $transportOptions = array(); diff --git a/src/Composer/Plugin/PrePoolCreateEvent.php b/src/Composer/Plugin/PrePoolCreateEvent.php index e5e46e708..baa4bc985 100644 --- a/src/Composer/Plugin/PrePoolCreateEvent.php +++ b/src/Composer/Plugin/PrePoolCreateEvent.php @@ -16,6 +16,7 @@ use Composer\EventDispatcher\Event; use Composer\Repository\RepositoryInterface; use Composer\DependencyResolver\Request; use Composer\Package\PackageInterface; +use Composer\Package\BasePackage; /** * The pre command run event. @@ -33,19 +34,23 @@ class PrePoolCreateEvent extends Event */ private $request; /** - * @var array + * @var int[] array of stability => BasePackage::STABILITY_* value + * @phpstan-var array */ private $acceptableStabilities; /** - * @var array + * @var int[] array of package name => BasePackage::STABILITY_* value + * @phpstan-var array */ private $stabilityFlags; /** - * @var array + * @var array[] of package => version => [alias, alias_normalized] + * @phpstan-var array> */ private $rootAliases; /** - * @var array + * @var string[] + * @phpstan-var array */ private $rootReferences; /** @@ -58,8 +63,17 @@ class PrePoolCreateEvent extends Event private $unacceptableFixedPackages; /** - * @param string $name The event name + * @param string $name The event name * @param RepositoryInterface[] $repositories + * @param int[] $acceptableStabilities array of stability => BasePackage::STABILITY_* value + * @param int[] $stabilityFlags array of package name => BasePackage::STABILITY_* value + * @param array[] $rootAliases array of package => version => [alias, alias_normalized] + * @param string[] $rootReferences + * + * @phpstan-param array $acceptableStabilities + * @phpstan-param array $stabilityFlags + * @phpstan-param array> $rootAliases + * @phpstan-param array $rootReferences */ public function __construct($name, array $repositories, Request $request, array $acceptableStabilities, array $stabilityFlags, array $rootAliases, array $rootReferences, array $packages, array $unacceptableFixedPackages) { @@ -92,7 +106,8 @@ class PrePoolCreateEvent extends Event } /** - * @return array + * @return int[] array of stability => BasePackage::STABILITY_* value + * @phpstan-return array */ public function getAcceptableStabilities() { @@ -100,7 +115,8 @@ class PrePoolCreateEvent extends Event } /** - * @return array + * @return int[] array of package name => BasePackage::STABILITY_* value + * @phpstan-return array */ public function getStabilityFlags() { @@ -117,7 +133,8 @@ class PrePoolCreateEvent extends Event } /** - * @return array + * @return string[] + * @phpstan-return array */ public function getRootReferences() { diff --git a/src/Composer/Repository/ArtifactRepository.php b/src/Composer/Repository/ArtifactRepository.php index 0ea1ef71c..02b593a0b 100644 --- a/src/Composer/Repository/ArtifactRepository.php +++ b/src/Composer/Repository/ArtifactRepository.php @@ -27,8 +27,11 @@ class ArtifactRepository extends ArrayRepository implements ConfigurableReposito /** @var LoaderInterface */ protected $loader; + /** @var string */ protected $lookup; + /** @var mixed[] */ protected $repoConfig; + /** @var IOInterface */ private $io; public function __construct(array $repoConfig, IOInterface $io) diff --git a/src/Composer/Repository/ComposerRepository.php b/src/Composer/Repository/ComposerRepository.php index 0aaf458db..930c4553d 100644 --- a/src/Composer/Repository/ComposerRepository.php +++ b/src/Composer/Repository/ComposerRepository.php @@ -44,43 +44,72 @@ use Composer\Util\Url; */ class ComposerRepository extends ArrayRepository implements ConfigurableRepositoryInterface { + /** + * @var mixed[] + * @phpstan-var array{url: string, options?: mixed[], type?: 'composer', allow_ssl_downgrade?: bool} + */ private $repoConfig; + /** @var mixed[] */ private $options; + /** @var string */ private $url; + /** @var string */ private $baseUrl; + /** @var IOInterface */ private $io; /** @var HttpDownloader */ private $httpDownloader; + /** @var Loop */ private $loop; + /** @var Cache */ protected $cache; - protected $notifyUrl; - protected $searchUrl; - /** @var string|null a URL containing %package% which can be queried to get providers of a given name */ - protected $providersApiUrl; + /** @var ?string */ + protected $notifyUrl = null; + /** @var ?string */ + protected $searchUrl = null; + /** @var ?string a URL containing %package% which can be queried to get providers of a given name */ + protected $providersApiUrl = null; + /** @var bool */ protected $hasProviders = false; - protected $providersUrl; - protected $listUrl; + /** @var ?string */ + protected $providersUrl = null; + /** @var ?string */ + protected $listUrl = null; /** @var bool Indicates whether a comprehensive list of packages this repository might provide is expressed in the repository root. **/ protected $hasAvailablePackageList = false; - protected $availablePackages; - protected $availablePackagePatterns; - protected $lazyProvidersUrl; + /** @var ?array */ + protected $availablePackages = null; + /** @var ?array */ + protected $availablePackagePatterns = null; + /** @var ?string */ + protected $lazyProvidersUrl = null; + /** @var ?array */ protected $providerListing; + /** @var ArrayLoader */ protected $loader; + /** @var bool */ private $allowSslDowngrade = false; + /** @var ?EventDispatcher */ private $eventDispatcher; + /** @var ?array */ private $sourceMirrors; + /** @var ?array */ private $distMirrors; + /** @var bool */ private $degradedMode = false; + /** @var mixed[]|true */ private $rootData; - private $hasPartialPackages; - private $partialPackagesByName; + /** @var bool */ + private $hasPartialPackages = false; + /** @var ?array */ + private $partialPackagesByName = null; /** * TODO v3 should make this private once we can drop PHP 5.3 support * @private * @var array list of package names which are fresh and can be loaded from the cache directly in case loadPackage is called several times * useful for v2 metadata repositories with lazy providers + * @phpstan-var array */ public $freshMetadataUrls = array(); @@ -89,11 +118,13 @@ class ComposerRepository extends ArrayRepository implements ConfigurableReposito * @private * @var array list of package names which returned a 404 and should not be re-fetched in case loadPackage is called several times * useful for v2 metadata repositories with lazy providers + * @phpstan-var array */ public $packagesNotFoundCache = array(); /** * TODO v3 should make this private once we can drop PHP 5.3 support * @private + * @var VersionParser */ public $versionParser; diff --git a/src/Composer/Repository/CompositeRepository.php b/src/Composer/Repository/CompositeRepository.php index ac1f2e149..8426364a5 100644 --- a/src/Composer/Repository/CompositeRepository.php +++ b/src/Composer/Repository/CompositeRepository.php @@ -23,13 +23,13 @@ class CompositeRepository implements RepositoryInterface { /** * List of repositories - * @var array + * @var RepositoryInterface[] */ private $repositories; /** * Constructor - * @param array $repositories + * @param RepositoryInterface[] $repositories */ public function __construct(array $repositories) { @@ -169,8 +169,9 @@ class CompositeRepository implements RepositoryInterface public function removePackage(PackageInterface $package) { foreach ($this->repositories as $repository) { - /* @var $repository RepositoryInterface */ - $repository->removePackage($package); + if ($repository instanceof WritableRepositoryInterface) { + $repository->removePackage($package); + } } } diff --git a/src/Composer/Repository/FilesystemRepository.php b/src/Composer/Repository/FilesystemRepository.php index 976eb957d..debdb7a89 100644 --- a/src/Composer/Repository/FilesystemRepository.php +++ b/src/Composer/Repository/FilesystemRepository.php @@ -28,9 +28,13 @@ use Composer\Util\Filesystem; */ class FilesystemRepository extends WritableArrayRepository { + /** @var JsonFile */ protected $file; + /** @var bool */ private $dumpVersions; + /** @var ?RootPackageInterface */ private $rootPackage; + /** @var Filesystem */ private $filesystem; /** diff --git a/src/Composer/Repository/FilterRepository.php b/src/Composer/Repository/FilterRepository.php index 0582a0f54..8ce7be05f 100644 --- a/src/Composer/Repository/FilterRepository.php +++ b/src/Composer/Repository/FilterRepository.php @@ -22,9 +22,13 @@ use Composer\Package\BasePackage; */ class FilterRepository implements RepositoryInterface { - private $only = array(); - private $exclude = array(); + /** @var ?string */ + private $only = null; + /** @var ?string */ + private $exclude = null; + /** @var bool */ private $canonical = true; + /** @var RepositoryInterface */ private $repo; public function __construct(RepositoryInterface $repo, array $options) @@ -174,14 +178,6 @@ class FilterRepository implements RepositoryInterface return $result; } - /** - * {@inheritdoc} - */ - public function removePackage(PackageInterface $package) - { - return $this->repo->removePackage($package); - } - /** * {@inheritdoc} */ diff --git a/src/Composer/Repository/PackageRepository.php b/src/Composer/Repository/PackageRepository.php index de6d31d4d..c5576cf7e 100644 --- a/src/Composer/Repository/PackageRepository.php +++ b/src/Composer/Repository/PackageRepository.php @@ -22,6 +22,7 @@ use Composer\Package\Loader\ValidatingArrayLoader; */ class PackageRepository extends ArrayRepository { + /** @var mixed[] */ private $config; /** diff --git a/src/Composer/Repository/PathRepository.php b/src/Composer/Repository/PathRepository.php index c1fc632da..7232e0368 100644 --- a/src/Composer/Repository/PathRepository.php +++ b/src/Composer/Repository/PathRepository.php @@ -77,7 +77,8 @@ class PathRepository extends ArrayRepository implements ConfigurableRepositoryIn private $url; /** - * @var array + * @var mixed[] + * @phpstan-var array{url: string, options?: array{symlink?: bool, relative?: bool, versions?: array}} */ private $repoConfig; @@ -87,7 +88,7 @@ class PathRepository extends ArrayRepository implements ConfigurableRepositoryIn private $process; /** - * @var array + * @var array{symlink?: bool, relative?: bool, versions?: array} */ private $options; diff --git a/src/Composer/Repository/PlatformRepository.php b/src/Composer/Repository/PlatformRepository.php index 095c86a8a..5cd1ae27c 100644 --- a/src/Composer/Repository/PlatformRepository.php +++ b/src/Composer/Repository/PlatformRepository.php @@ -46,13 +46,15 @@ class PlatformRepository extends ArrayRepository /** * Defines overrides so that the platform can be mocked * - * Should be an array of package name => version number mappings + * Keyed by package name (lowercased) * - * @var array + * @var array */ private $overrides = array(); + /** @var Runtime */ private $runtime; + /** @var HhvmDetector */ private $hhvmDetector; public function __construct(array $packages = array(), array $overrides = array(), Runtime $runtime = null, HhvmDetector $hhvmDetector = null) diff --git a/src/Composer/Repository/RepositorySet.php b/src/Composer/Repository/RepositorySet.php index ae7e2cba8..d87a334b3 100644 --- a/src/Composer/Repository/RepositorySet.php +++ b/src/Composer/Repository/RepositorySet.php @@ -67,6 +67,10 @@ class RepositorySet */ private $stabilityFlags; + /** + * @var ConstraintInterface[] + * @phpstan-var array + */ private $rootRequires; /** @var bool */ @@ -86,6 +90,8 @@ class RepositorySet * @phpstan-param list $rootAliases * @param string[] $rootReferences an array of package name => source reference * @phpstan-param array $rootReferences + * @param ConstraintInterface[] $rootRequires an array of package name => constraint from the root package + * @phpstan-param array $rootRequires */ public function __construct($minimumStability = 'stable', array $stabilityFlags = array(), array $rootAliases = array(), array $rootReferences = array(), array $rootRequires = array()) { @@ -112,6 +118,10 @@ class RepositorySet $this->allowInstalledRepositories = $allow; } + /** + * @return ConstraintInterface[] an array of package name => constraint from the root package, platform requirements excluded + * @phpstan-return array + */ public function getRootRequires() { return $this->rootRequires; @@ -193,6 +203,12 @@ class RepositorySet return $result; } + /** + * @param string $packageName + * + * @return array[] an array with the provider name as key and value of array('name' => '...', 'description' => '...', 'type' => '...') + * @phpstan-return array + */ public function getProviders($packageName) { $providers = array(); @@ -205,6 +221,13 @@ class RepositorySet return $providers; } + /** + * Check for each given package name whether it would be accepted by this RepositorySet in the given $stability + * + * @param string[] $names + * @param string $stability one of 'stable', 'RC', 'beta', 'alpha' or 'dev' + * @return bool + */ public function isPackageAcceptable($names, $stability) { return StabilityFilter::isPackageAcceptable($this->acceptableStabilities, $this->stabilityFlags, $names, $stability); diff --git a/src/Composer/Repository/Vcs/BitbucketDriver.php b/src/Composer/Repository/Vcs/BitbucketDriver.php index 96b4c3298..8bd47a7a2 100644 --- a/src/Composer/Repository/Vcs/BitbucketDriver.php +++ b/src/Composer/Repository/Vcs/BitbucketDriver.php @@ -20,16 +20,27 @@ use Composer\Util\Http\Response; abstract class BitbucketDriver extends VcsDriver { + /** @var string */ protected $owner; + /** @var string */ protected $repository; - protected $hasIssues; + /** @var bool */ + protected $hasIssues = false; + /** @var ?string */ protected $rootIdentifier; + /** @var array Map of tag name to identifier */ protected $tags; + /** @var array Map of branch name to identifier */ protected $branches; + /** @var string */ protected $branchesUrl = ''; + /** @var string */ protected $tagsUrl = ''; + /** @var string */ protected $homeUrl = ''; + /** @var string */ protected $website = ''; + /** @var string */ protected $cloneHttpsUrl = ''; /** diff --git a/src/Composer/Repository/Vcs/FossilDriver.php b/src/Composer/Repository/Vcs/FossilDriver.php index 8f73ffb5e..c4c468f40 100644 --- a/src/Composer/Repository/Vcs/FossilDriver.php +++ b/src/Composer/Repository/Vcs/FossilDriver.php @@ -23,10 +23,15 @@ use Composer\IO\IOInterface; */ class FossilDriver extends VcsDriver { + /** @var array Map of tag name to identifier */ protected $tags; + /** @var array Map of branch name to identifier */ protected $branches; - protected $rootIdentifier; - protected $repoFile; + /** @var ?string */ + protected $rootIdentifier = null; + /** @var ?string */ + protected $repoFile = null; + /** @var string */ protected $checkoutDir; /** diff --git a/src/Composer/Repository/Vcs/GitDriver.php b/src/Composer/Repository/Vcs/GitDriver.php index ea7803631..4fef3f702 100644 --- a/src/Composer/Repository/Vcs/GitDriver.php +++ b/src/Composer/Repository/Vcs/GitDriver.php @@ -25,9 +25,13 @@ use Composer\Config; */ class GitDriver extends VcsDriver { + /** @var array Map of tag name to identifier */ protected $tags; + /** @var array Map of branch name to identifier */ protected $branches; + /** @var string */ protected $rootIdentifier; + /** @var string */ protected $repoDir; /** diff --git a/src/Composer/Repository/Vcs/GitHubDriver.php b/src/Composer/Repository/Vcs/GitHubDriver.php index b312edeac..e7d84a078 100644 --- a/src/Composer/Repository/Vcs/GitHubDriver.php +++ b/src/Composer/Repository/Vcs/GitHubDriver.php @@ -25,15 +25,25 @@ use Composer\Util\Http\Response; */ class GitHubDriver extends VcsDriver { + /** @var string */ protected $owner; + /** @var string */ protected $repository; + /** @var array Map of tag name to identifier */ protected $tags; + /** @var array Map of branch name to identifier */ protected $branches; + /** @var string */ protected $rootIdentifier; + /** @var mixed[] */ protected $repoData; - protected $hasIssues; + /** @var bool */ + protected $hasIssues = false; + /** @var bool */ protected $isPrivate = false; + /** @var bool */ private $isArchived = false; + /** @var array|false|null */ private $fundingInfo; /** diff --git a/src/Composer/Repository/Vcs/GitLabDriver.php b/src/Composer/Repository/Vcs/GitLabDriver.php index 2bc0cf61c..8e9d9059d 100644 --- a/src/Composer/Repository/Vcs/GitLabDriver.php +++ b/src/Composer/Repository/Vcs/GitLabDriver.php @@ -29,28 +29,30 @@ use Composer\Util\Http\Response; */ class GitLabDriver extends VcsDriver { + /** + * @var string + * @phpstan-var 'https'|'http' + */ private $scheme; + /** @var string */ private $namespace; + /** @var string */ private $repository; /** - * @var array Project data returned by GitLab API + * @var mixed[] Project data returned by GitLab API */ private $project; /** - * @var array Keeps commits returned by GitLab API + * @var array Keeps commits returned by GitLab API */ private $commits = array(); - /** - * @var array List of tag => reference - */ + /** @var array Map of tag name to identifier */ private $tags; - /** - * @var array List of branch => reference - */ + /** @var array Map of branch name to identifier */ private $branches; /** diff --git a/src/Composer/Repository/Vcs/HgDriver.php b/src/Composer/Repository/Vcs/HgDriver.php index 9b6b68803..56e35ea30 100644 --- a/src/Composer/Repository/Vcs/HgDriver.php +++ b/src/Composer/Repository/Vcs/HgDriver.php @@ -24,9 +24,13 @@ use Composer\IO\IOInterface; */ class HgDriver extends VcsDriver { + /** @var array Map of tag name to identifier */ protected $tags; + /** @var array Map of branch name to identifier */ protected $branches; + /** @var string */ protected $rootIdentifier; + /** @var string */ protected $repoDir; /** diff --git a/src/Composer/Repository/Vcs/PerforceDriver.php b/src/Composer/Repository/Vcs/PerforceDriver.php index 861b67038..76249fd54 100644 --- a/src/Composer/Repository/Vcs/PerforceDriver.php +++ b/src/Composer/Repository/Vcs/PerforceDriver.php @@ -23,7 +23,9 @@ use Composer\Util\Perforce; */ class PerforceDriver extends VcsDriver { + /** @var string */ protected $depot; + /** @var string */ protected $branch; /** @var ?Perforce */ protected $perforce = null; diff --git a/src/Composer/Repository/Vcs/SvnDriver.php b/src/Composer/Repository/Vcs/SvnDriver.php index ab3f95f16..9ea596115 100644 --- a/src/Composer/Repository/Vcs/SvnDriver.php +++ b/src/Composer/Repository/Vcs/SvnDriver.php @@ -28,15 +28,24 @@ use Composer\Downloader\TransportException; */ class SvnDriver extends VcsDriver { + /** @var string */ protected $baseUrl; + /** @var array Map of tag name to identifier */ protected $tags; + /** @var array Map of branch name to identifier */ protected $branches; + /** @var ?string */ protected $rootIdentifier; + /** @var string|false */ protected $trunkPath = 'trunk'; + /** @var string */ protected $branchesPath = 'branches'; + /** @var string */ protected $tagsPath = 'tags'; + /** @var string */ protected $packagePath = ''; + /** @var bool */ protected $cacheCredentials = true; /** diff --git a/src/Composer/Repository/Vcs/VcsDriver.php b/src/Composer/Repository/Vcs/VcsDriver.php index ae86e44a7..7e287e33c 100644 --- a/src/Composer/Repository/Vcs/VcsDriver.php +++ b/src/Composer/Repository/Vcs/VcsDriver.php @@ -33,7 +33,7 @@ abstract class VcsDriver implements VcsDriverInterface protected $url; /** @var string */ protected $originUrl; - /** @var array */ + /** @var array */ protected $repoConfig; /** @var IOInterface */ protected $io; @@ -43,7 +43,7 @@ abstract class VcsDriver implements VcsDriverInterface protected $process; /** @var HttpDownloader */ protected $httpDownloader; - /** @var array */ + /** @var array */ protected $infoCache = array(); /** @var ?Cache */ protected $cache; diff --git a/src/Composer/Repository/VcsRepository.php b/src/Composer/Repository/VcsRepository.php index 2456baaea..2740bb603 100644 --- a/src/Composer/Repository/VcsRepository.php +++ b/src/Composer/Repository/VcsRepository.php @@ -32,25 +32,41 @@ use Composer\Config; */ class VcsRepository extends ArrayRepository implements ConfigurableRepositoryInterface { + /** @var string */ protected $url; + /** @var ?string */ protected $packageName; + /** @var bool */ protected $isVerbose; + /** @var bool */ protected $isVeryVerbose; + /** @var IOInterface */ protected $io; + /** @var Config */ protected $config; + /** @var VersionParser */ protected $versionParser; + /** @var string */ protected $type; + /** @var ?LoaderInterface */ protected $loader; + /** @var array */ protected $repoConfig; + /** @var HttpDownloader */ protected $httpDownloader; + /** @var ProcessExecutor */ protected $processExecutor; + /** @var bool */ protected $branchErrorOccurred = false; + /** @var array */ private $drivers; /** @var ?VcsDriverInterface */ private $driver; /** @var ?VersionCacheInterface */ private $versionCache; + /** @var string[] */ private $emptyReferences = array(); + /** @var array<'tags'|'branches', array> */ private $versionTransportExceptions = array(); public function __construct(array $repoConfig, IOInterface $io, Config $config, HttpDownloader $httpDownloader, EventDispatcher $dispatcher = null, ProcessExecutor $process = null, array $drivers = null, VersionCacheInterface $versionCache = null)