1
0
Fork 0

Fix phpdoc

pull/3128/head
François Pluchino 2014-07-16 15:17:38 +02:00
parent 745dcbce33
commit 8b5c00bff0
15 changed files with 38 additions and 6 deletions

View File

@ -143,6 +143,8 @@ class ClassLoader
* @param string $prefix The prefix/namespace, with trailing '\\' * @param string $prefix The prefix/namespace, with trailing '\\'
* @param array|string $paths The PSR-0 base directories * @param array|string $paths The PSR-0 base directories
* @param bool $prepend Whether to prepend the directories * @param bool $prepend Whether to prepend the directories
*
* @throws \InvalidArgumentException
*/ */
public function addPsr4($prefix, $paths, $prepend = false) public function addPsr4($prefix, $paths, $prepend = false)
{ {
@ -204,6 +206,8 @@ class ClassLoader
* *
* @param string $prefix The prefix/namespace, with trailing '\\' * @param string $prefix The prefix/namespace, with trailing '\\'
* @param array|string $paths The PSR-4 base directories * @param array|string $paths The PSR-4 base directories
*
* @throws \InvalidArgumentException
*/ */
public function setPsr4($prefix, $paths) public function setPsr4($prefix, $paths)
{ {

View File

@ -37,6 +37,7 @@ class JsonConfigSource implements ConfigSourceInterface
* Constructor * Constructor
* *
* @param JsonFile $file * @param JsonFile $file
* @param bool $authConfig
*/ */
public function __construct(JsonFile $file, $authConfig = false) public function __construct(JsonFile $file, $authConfig = false)
{ {

View File

@ -129,6 +129,7 @@ class Application extends BaseApplication
/** /**
* @param InputInterface $input * @param InputInterface $input
* @return string
* @throws \RuntimeException * @throws \RuntimeException
*/ */
private function getNewWorkingDir(InputInterface $input) private function getNewWorkingDir(InputInterface $input)

View File

@ -132,6 +132,7 @@ abstract class ArchiveDownloader extends FileDownloader
* Returns the folder content, excluding dotfiles * Returns the folder content, excluding dotfiles
* *
* @param string $dir Directory * @param string $dir Directory
* @return \SplFileInfo[]
*/ */
private function getFolderContent($dir) private function getFolderContent($dir)
{ {

View File

@ -164,6 +164,7 @@ class DownloadManager
* @param bool $preferSource prefer installation from source * @param bool $preferSource prefer installation from source
* *
* @throws \InvalidArgumentException if package have no urls to download from * @throws \InvalidArgumentException if package have no urls to download from
* @throws \RuntimeException
*/ */
public function download(PackageInterface $package, $targetDir, $preferSource = null) public function download(PackageInterface $package, $targetDir, $preferSource = null)
{ {

View File

@ -204,8 +204,10 @@ class GitDownloader extends VcsDownloader
* @param string $path * @param string $path
* @param string $reference * @param string $reference
* @param string $branch * @param string $branch
* @param DateTime $date * @param \DateTime $date
* @return null|string if a string is returned, it is the commit reference that was checked out if the original could not be found * @return null|string if a string is returned, it is the commit reference that was checked out if the original could not be found
*
* @throws \RuntimeException
*/ */
protected function updateToCommit($path, $reference, $branch, $date) protected function updateToCommit($path, $reference, $branch, $date)
{ {

View File

@ -73,7 +73,7 @@ class EventDispatcher
* Dispatch a script event. * Dispatch a script event.
* *
* @param string $eventName The constant in ScriptEvents * @param string $eventName The constant in ScriptEvents
* @param Script\Event $event * @param bool $devMode
*/ */
public function dispatchScript($eventName, $devMode = false) public function dispatchScript($eventName, $devMode = false)
{ {

View File

@ -38,6 +38,7 @@ class Factory
{ {
/** /**
* @return string * @return string
* @throws \RuntimeException
*/ */
protected static function getHomeDir() protected static function getHomeDir()
{ {
@ -60,6 +61,8 @@ class Factory
} }
/** /**
* @param string $home
*
* @return string * @return string
*/ */
protected static function getCacheDir($home) protected static function getCacheDir($home)
@ -82,6 +85,7 @@ class Factory
} }
/** /**
* @param IOInterface|null $io
* @return Config * @return Config
*/ */
public static function createConfig(IOInterface $io = null) public static function createConfig(IOInterface $io = null)
@ -333,6 +337,7 @@ class Factory
/** /**
* @param Config $config * @param Config $config
* @param string $vendorDir * @param string $vendorDir
* @return Repository\InstalledFilesystemRepository|null
*/ */
protected function createGlobalRepository(Config $config, $vendorDir) protected function createGlobalRepository(Config $config, $vendorDir)
{ {
@ -410,6 +415,9 @@ class Factory
} }
/** /**
* @param Composer $composer
* @param IOInterface $io
* @param RepositoryInterface $globalRepository
* @return Plugin\PluginManager * @return Plugin\PluginManager
*/ */
protected function createPluginManager(Composer $composer, IOInterface $io, RepositoryInterface $globalRepository = null) protected function createPluginManager(Composer $composer, IOInterface $io, RepositoryInterface $globalRepository = null)

View File

@ -152,6 +152,8 @@ class Installer
* Run installation (or update) * Run installation (or update)
* *
* @return int 0 on success or a positive error code on failure * @return int 0 on success or a positive error code on failure
*
* @throws \Exception
*/ */
public function run() public function run()
{ {

View File

@ -495,7 +495,7 @@ class Package extends BasePackage
/** /**
* Set the dev autoload mapping * Set the dev autoload mapping
* *
* @param array $autoload Mapping of dev autoloading rules * @param array $devAutoload Mapping of dev autoloading rules
*/ */
public function setDevAutoload(array $devAutoload) public function setDevAutoload(array $devAutoload)
{ {

View File

@ -89,7 +89,7 @@ class VersionParser
* @param string $version * @param string $version
* @param string $fullVersion optional complete version string to give more context * @param string $fullVersion optional complete version string to give more context
* @throws \UnexpectedValueException * @throws \UnexpectedValueException
* @return array * @return string
*/ */
public function normalize($version, $fullVersion = null) public function normalize($version, $fullVersion = null)
{ {
@ -161,7 +161,7 @@ class VersionParser
* Normalizes a branch name to be able to perform comparisons on it * Normalizes a branch name to be able to perform comparisons on it
* *
* @param string $name * @param string $name
* @return array * @return string
*/ */
public function normalizeBranch($name) public function normalizeBranch($name)
{ {

View File

@ -103,6 +103,8 @@ class PluginManager
* call this method as early as possible. * call this method as early as possible.
* *
* @param RepositoryInterface $repo Repository to scan for plugins to install * @param RepositoryInterface $repo Repository to scan for plugins to install
*
* @throws \RuntimeException
*/ */
public function loadRepository(RepositoryInterface $repo) public function loadRepository(RepositoryInterface $repo)
{ {
@ -186,6 +188,8 @@ class PluginManager
* instead for BC * instead for BC
* *
* @param PackageInterface $package * @param PackageInterface $package
*
* @throws \UnexpectedValueException
*/ */
public function registerPackage(PackageInterface $package) public function registerPackage(PackageInterface $package)
{ {

View File

@ -90,6 +90,8 @@ class Filesystem
* *
* @param string $directory * @param string $directory
* @return bool * @return bool
*
* @throws \RuntimeException
*/ */
public function removeDirectory($directory) public function removeDirectory($directory)
{ {
@ -174,6 +176,8 @@ class Filesystem
* *
* @param string $path * @param string $path
* @return bool * @return bool
*
* @throws \RuntimeException
*/ */
public function unlink($path) public function unlink($path)
{ {
@ -198,6 +202,8 @@ class Filesystem
* *
* @param string $path * @param string $path
* @return bool * @return bool
*
* @throws \RuntimeException
*/ */
public function rmdir($path) public function rmdir($path)
{ {

View File

@ -43,6 +43,7 @@ class RemoteFilesystem
* Constructor. * Constructor.
* *
* @param IOInterface $io The IO instance * @param IOInterface $io The IO instance
* @param Config $config The config
* @param array $options The options * @param array $options The options
*/ */
public function __construct(IOInterface $io, Config $config = null, array $options = array()) public function __construct(IOInterface $io, Config $config = null, array $options = array())
@ -76,7 +77,7 @@ class RemoteFilesystem
* @param boolean $progress Display the progression * @param boolean $progress Display the progression
* @param array $options Additional context options * @param array $options Additional context options
* *
* @return string The content * @return bool|string The content
*/ */
public function getContents($originUrl, $fileUrl, $progress = true, $options = array()) public function getContents($originUrl, $fileUrl, $progress = true, $options = array())
{ {

View File

@ -66,6 +66,7 @@ class Svn
/** /**
* @param string $url * @param string $url
* @param \Composer\IO\IOInterface $io * @param \Composer\IO\IOInterface $io
* @param Config $config
* @param ProcessExecutor $process * @param ProcessExecutor $process
*/ */
public function __construct($url, IOInterface $io, Config $config, ProcessExecutor $process = null) public function __construct($url, IOInterface $io, Config $config, ProcessExecutor $process = null)