@@ -1083,6 +1083,9 @@ |
||
| 1083 | 1083 | return $this; |
| 1084 | 1084 | } |
| 1085 | 1085 | |
| 1086 | + /** |
|
| 1087 | + * @param integer $width |
|
| 1088 | + */ |
|
| 1086 | 1089 | private function splitStringByWidth($string, $width) |
| 1087 | 1090 | { |
| 1088 | 1091 | // str_split is not suitable for multi-byte characters, we should use preg_split to get char array properly. |
@@ -383,7 +383,7 @@ discard block |
||
| 383 | 383 | * @param string|array $shortcut The shortcuts, can be null, a string of shortcuts delimited by | or an array of shortcuts |
| 384 | 384 | * @param int|null $mode The option mode: One of the VALUE_* constants |
| 385 | 385 | * @param string $description A description text |
| 386 | - * @param string|string[]|bool|null $default The default value (must be null for self::VALUE_NONE) |
|
| 386 | + * @param string $default The default value (must be null for self::VALUE_NONE) |
|
| 387 | 387 | * |
| 388 | 388 | * @throws InvalidArgumentException If option mode is invalid or incompatible |
| 389 | 389 | * |
@@ -623,7 +623,7 @@ discard block |
||
| 623 | 623 | * |
| 624 | 624 | * @param string $name The helper name |
| 625 | 625 | * |
| 626 | - * @return mixed The helper value |
|
| 626 | + * @return \Symfony\Component\Console\Helper\HelperInterface The helper value |
|
| 627 | 627 | * |
| 628 | 628 | * @throws LogicException if no HelperSet is defined |
| 629 | 629 | * @throws InvalidArgumentException if the helper is not defined |
@@ -26,6 +26,7 @@ |
||
| 26 | 26 | * @param OutputInterface $output |
| 27 | 27 | * @param object $object |
| 28 | 28 | * @param array $options |
| 29 | + * @return void |
|
| 29 | 30 | */ |
| 30 | 31 | public function describe(OutputInterface $output, $object, array $options = array()); |
| 31 | 32 | } |
@@ -298,7 +298,7 @@ |
||
| 298 | 298 | } |
| 299 | 299 | |
| 300 | 300 | /** |
| 301 | - * @param (Command|string)[] $commands |
|
| 301 | + * @param Command[] $commands |
|
| 302 | 302 | */ |
| 303 | 303 | private function getColumnWidth(array $commands): int |
| 304 | 304 | { |
@@ -186,7 +186,7 @@ |
||
| 186 | 186 | /** |
| 187 | 187 | * Tries to create new style instance from string. |
| 188 | 188 | * |
| 189 | - * @return OutputFormatterStyle|false False if string is not format string |
|
| 189 | + * @return OutputFormatterStyleInterface|null False if string is not format string |
|
| 190 | 190 | */ |
| 191 | 191 | private function createStyleFromString(string $string) |
| 192 | 192 | { |
@@ -22,6 +22,7 @@ discard block |
||
| 22 | 22 | * Sets the decorated flag. |
| 23 | 23 | * |
| 24 | 24 | * @param bool $decorated Whether to decorate the messages or not |
| 25 | + * @return void |
|
| 25 | 26 | */ |
| 26 | 27 | public function setDecorated($decorated); |
| 27 | 28 | |
@@ -37,6 +38,7 @@ discard block |
||
| 37 | 38 | * |
| 38 | 39 | * @param string $name The style name |
| 39 | 40 | * @param OutputFormatterStyleInterface $style The style instance |
| 41 | + * @return void |
|
| 40 | 42 | */ |
| 41 | 43 | public function setStyle($name, OutputFormatterStyleInterface $style); |
| 42 | 44 | |
@@ -59,7 +59,7 @@ |
||
| 59 | 59 | * |
| 60 | 60 | * @param string|null $foreground The style foreground color name |
| 61 | 61 | * @param string|null $background The style background color name |
| 62 | - * @param array $options The style options |
|
| 62 | + * @param string[] $options The style options |
|
| 63 | 63 | */ |
| 64 | 64 | public function __construct(string $foreground = null, string $background = null, array $options = array()) |
| 65 | 65 | { |
@@ -22,6 +22,7 @@ discard block |
||
| 22 | 22 | * Sets style foreground color. |
| 23 | 23 | * |
| 24 | 24 | * @param string $color The color name |
| 25 | + * @return void |
|
| 25 | 26 | */ |
| 26 | 27 | public function setForeground($color = null); |
| 27 | 28 | |
@@ -29,6 +30,7 @@ discard block |
||
| 29 | 30 | * Sets style background color. |
| 30 | 31 | * |
| 31 | 32 | * @param string $color The color name |
| 33 | + * @return void |
|
| 32 | 34 | */ |
| 33 | 35 | public function setBackground($color = null); |
| 34 | 36 | |
@@ -36,6 +38,7 @@ discard block |
||
| 36 | 38 | * Sets some specific style option. |
| 37 | 39 | * |
| 38 | 40 | * @param string $option The option name |
| 41 | + * @return void |
|
| 39 | 42 | */ |
| 40 | 43 | public function setOption($option); |
| 41 | 44 | |
@@ -43,11 +46,13 @@ discard block |
||
| 43 | 46 | * Unsets some specific style option. |
| 44 | 47 | * |
| 45 | 48 | * @param string $option The option name |
| 49 | + * @return void |
|
| 46 | 50 | */ |
| 47 | 51 | public function unsetOption($option); |
| 48 | 52 | |
| 49 | 53 | /** |
| 50 | 54 | * Sets multiple style options at once. |
| 55 | + * @return void |
|
| 51 | 56 | */ |
| 52 | 57 | public function setOptions(array $options); |
| 53 | 58 | |
@@ -101,6 +101,9 @@ |
||
| 101 | 101 | } |
| 102 | 102 | } |
| 103 | 103 | |
| 104 | + /** |
|
| 105 | + * @param integer $memory |
|
| 106 | + */ |
|
| 104 | 107 | public static function formatMemory($memory) |
| 105 | 108 | { |
| 106 | 109 | if ($memory >= 1024 * 1024 * 1024) { |