1
0
Fork 0

Ton of phpDoc fixes.

pull/5162/head
Niels Keurentjes 2016-04-07 01:12:30 +02:00
parent e6f21137ad
commit 818c3e707a
13 changed files with 47 additions and 22 deletions

View File

@ -209,8 +209,9 @@ class BaseDependencyCommand extends BaseCommand
/**
* Recursively prints a tree of the selected results.
*
* @param array $results
* @param string $prefix
* @param array $results Results to be printed at this level.
* @param string $prefix Prefix of the current tree level.
* @param int $level Current level of recursion.
*/
protected function printTree($results, $prefix = '', $level = 1)
{

View File

@ -362,6 +362,7 @@ EOT
* @param InputInterface $input
* @param bool $preferSource
* @param bool $preferDist
* @param bool $keepVcsRequiresPreferSource
*/
protected function updatePreferredOptions(Config $config, InputInterface $input, &$preferSource, &$preferDist, $keepVcsRequiresPreferSource = false)
{

View File

@ -114,6 +114,8 @@ EOT
*
* @param RepositoryInterface $repo
* @param PackageInterface $package
* @param array $bucket
* @return array
*/
private function filterRequiredPackages(RepositoryInterface $repo, PackageInterface $package, $bucket = array())
{

View File

@ -305,6 +305,8 @@ TAGSPUBKEY
* @param string $localFilename
* @param string $newFilename
* @param string $backupTarget
* @return \Exception|null
* @throws \Exception
*/
protected function setLocalPhar($localFilename, $newFilename, $backupTarget = null)
{
@ -323,6 +325,7 @@ TAGSPUBKEY
}
rename($newFilename, $localFilename);
return null;
} catch (\Exception $e) {
if (!$e instanceof \UnexpectedValueException && !$e instanceof \PharException) {
throw $e;

View File

@ -332,7 +332,11 @@ EOT
}
/**
* prints package meta data
* Prints package metadata.
*
* @param CompletePackageInterface $package
* @param array $versions
* @param RepositoryInterface $installedRepo
*/
protected function printMeta(CompletePackageInterface $package, array $versions, RepositoryInterface $installedRepo)
{
@ -389,7 +393,11 @@ EOT
}
/**
* prints all available versions of this package and highlights the installed one if any
* Prints all available versions of this package and highlights the installed one if any.
*
* @param CompletePackageInterface $package
* @param array $versions
* @param RepositoryInterface $installedRepo
*/
protected function printVersions(CompletePackageInterface $package, array $versions, RepositoryInterface $installedRepo)
{

View File

@ -45,6 +45,9 @@ class Request
* Mark an existing package as being installed and having to remain installed
*
* These jobs will not be tempered with by the solver
*
* @param string $packageName
* @param ConstraintInterface|null $constraint
*/
public function fix($packageName, ConstraintInterface $constraint = null)
{

View File

@ -137,11 +137,9 @@ class EventDispatcher
* Triggers the listeners of an event.
*
* @param Event $event The event object to pass to the event handlers/listeners.
* @param string $additionalArgs
* @throws \RuntimeException
* @throws \Exception
* @return int return code of the executed script if any, for php scripts a false return
* value is changed to 1, anything else to 0
* @throws \RuntimeException|\Exception
*/
protected function doDispatch(Event $event)
{

View File

@ -23,15 +23,12 @@ use Symfony\Component\Console\Helper\HelperSet;
class BufferIO extends ConsoleIO
{
/**
* @param string $input
* @param int $verbosity
* @param OutputFormatterInterface $formatter
* @param string $input
* @param int $verbosity
* @param OutputFormatterInterface|null $formatter
*/
public function __construct(
$input = '',
$verbosity = StreamOutput::VERBOSITY_NORMAL,
OutputFormatterInterface $formatter = null
) {
public function __construct($input = '', $verbosity = StreamOutput::VERBOSITY_NORMAL, OutputFormatterInterface $formatter = null)
{
$input = new StringInput($input);
$input->setInteractive(false);

View File

@ -30,10 +30,12 @@ class PearBinaryInstaller extends BinaryInstaller
private $vendorDir;
/**
* @param IOInterface $io
* @param string $binDir
* @param string $binCompat
* @param Filesystem $filesystem
* @param IOInterface $io
* @param string $binDir
* @param string $vendorDir
* @param string $binCompat
* @param Filesystem $filesystem
* @param PearInstaller $installer
*/
public function __construct(IOInterface $io, $binDir, $vendorDir, $binCompat, Filesystem $filesystem, PearInstaller $installer)
{

View File

@ -29,7 +29,7 @@ class SuggestedPackagesReporter
protected $suggestedPackages = array();
/**
* @var Composer\IO\IOInterface
* @var \Composer\IO\IOInterface
*/
private $io;

View File

@ -43,6 +43,7 @@ class JsonFile
*
* @param string $path path to a lockfile
* @param RemoteFilesystem $rfs required for loading http/https json files
* @param IOInterface $io
* @throws \InvalidArgumentException
*/
public function __construct($path, RemoteFilesystem $rfs = null, IOInterface $io = null)
@ -105,7 +106,7 @@ class JsonFile
*
* @param array $hash writes hash into json file
* @param int $options json_encode options (defaults to JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE)
* @throws \UnexpectedValueException
* @throws \UnexpectedValueException|\Exception
*/
public function write(array $hash, $options = 448)
{

View File

@ -272,6 +272,7 @@ class ComposerRepository extends ArrayRepository implements ConfigurableReposito
* @param Pool $pool
* @param string $name package name
* @param bool $bypassFilters If set to true, this bypasses the stability filtering, and forces a recompute without cache
* @return array|mixed
*/
public function whatProvides(Pool $pool, $name, $bypassFilters = false)
{

View File

@ -25,7 +25,11 @@ use Composer\Json\JsonFile;
class RepositoryFactory
{
/**
* @return array
* @param IOInterface $io
* @param Config $config
* @param string $repository
* @param bool $allowFilesystem
* @return array|mixed
*/
public static function configFromString(IOInterface $io, Config $config, $repository, $allowFilesystem = false)
{
@ -52,6 +56,10 @@ class RepositoryFactory
}
/**
* @param IOInterface $io
* @param Config $config
* @param string $repository
* @param bool $allowFilesystem
* @return RepositoryInterface
*/
public static function fromString(IOInterface $io, Config $config, $repository, $allowFilesystem = false)