@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | } |
35 | 35 | |
36 | 36 | /** |
37 | - * @param $dir |
|
37 | + * @param string $dir |
|
38 | 38 | */ |
39 | 39 | public static function reformFiles($dir) |
40 | 40 | { |
@@ -159,8 +159,8 @@ discard block |
||
159 | 159 | } |
160 | 160 | |
161 | 161 | /** |
162 | - * @param $name |
|
163 | - * @return bool |
|
162 | + * @param string $name |
|
163 | + * @return string|false |
|
164 | 164 | */ |
165 | 165 | public static function extractYear($name) |
166 | 166 | { |
@@ -175,8 +175,8 @@ discard block |
||
175 | 175 | } |
176 | 176 | |
177 | 177 | /** |
178 | - * @param null $season |
|
179 | - * @param null $episode |
|
178 | + * @param integer|null $season |
|
179 | + * @param integer|null $episode |
|
180 | 180 | * @return string |
181 | 181 | */ |
182 | 182 | public static function getEpisodeName($season = null, $episode = null) |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | |
38 | 38 | /** |
39 | 39 | * @param $name |
40 | - * @return null |
|
40 | + * @return string |
|
41 | 41 | */ |
42 | 42 | public function getOptionDefaultValue($name) |
43 | 43 | { |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | |
50 | 50 | /** |
51 | 51 | * @param $name |
52 | - * @return null |
|
52 | + * @return string |
|
53 | 53 | */ |
54 | 54 | public function getOptionDescription($name) |
55 | 55 | { |
@@ -60,8 +60,8 @@ discard block |
||
60 | 60 | } |
61 | 61 | |
62 | 62 | /** |
63 | - * @param $name |
|
64 | - * @return array|false|null|string |
|
63 | + * @param string $name |
|
64 | + * @return null|string |
|
65 | 65 | */ |
66 | 66 | public function getOption($name) |
67 | 67 | { |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | } |
93 | 93 | |
94 | 94 | /** |
95 | - * @param $request |
|
95 | + * @param string $request |
|
96 | 96 | * @param $data |
97 | 97 | */ |
98 | 98 | public static function setCacheValue($request, $data) |
@@ -103,8 +103,8 @@ discard block |
||
103 | 103 | } |
104 | 104 | |
105 | 105 | /** |
106 | - * @param $request |
|
107 | - * @return mixed |
|
106 | + * @param string $request |
|
107 | + * @return string |
|
108 | 108 | */ |
109 | 109 | public static function getCacheValue($request) |
110 | 110 | { |
@@ -117,7 +117,7 @@ discard block |
||
117 | 117 | } |
118 | 118 | |
119 | 119 | /** |
120 | - * @param $text |
|
120 | + * @param string $text |
|
121 | 121 | * @return int|null |
122 | 122 | */ |
123 | 123 | public function parseSerialSeason($text) |
@@ -136,7 +136,7 @@ discard block |
||
136 | 136 | } |
137 | 137 | |
138 | 138 | /** |
139 | - * @param $text |
|
139 | + * @param string $text |
|
140 | 140 | * @return int|null |
141 | 141 | */ |
142 | 142 | public function parseSerialEpisodeNumber($text) |
@@ -212,12 +212,18 @@ |
||
212 | 212 | return $this->engine->parseSerialSeason($this->filePath) ?: $this->engine->parseSerialSeason($this->getFolder()); |
213 | 213 | } |
214 | 214 | |
215 | + /** |
|
216 | + * @param string $key |
|
217 | + */ |
|
215 | 218 | protected function setCacheValue($key, $data) |
216 | 219 | { |
217 | 220 | $class = $this->engine; |
218 | 221 | $class::setCacheValue($key, $data); |
219 | 222 | } |
220 | 223 | |
224 | + /** |
|
225 | + * @param string $key |
|
226 | + */ |
|
221 | 227 | protected function getCacheValue($key) |
222 | 228 | { |
223 | 229 | $class = $this->engine; |
@@ -22,7 +22,7 @@ |
||
22 | 22 | * @param array $a array to be merged to |
23 | 23 | * @param array $b array to be merged from. You can specify additional |
24 | 24 | * arrays via third argument, fourth argument etc. |
25 | - * @return array the merged array (the original arrays are not changed.) |
|
25 | + * @return string the merged array (the original arrays are not changed.) |
|
26 | 26 | */ |
27 | 27 | public static function merge($a, $b) |
28 | 28 | { |
@@ -454,7 +454,7 @@ discard block |
||
454 | 454 | * - windows without ansicon |
455 | 455 | * - not tty consoles |
456 | 456 | * |
457 | - * @param mixed $stream |
|
457 | + * @param string $stream |
|
458 | 458 | * @return bool true if the stream supports ANSI colors, otherwise false. |
459 | 459 | */ |
460 | 460 | public static function streamSupportsAnsiColors($stream) |
@@ -486,7 +486,7 @@ discard block |
||
486 | 486 | * @param bool $refresh whether to force checking and not re-use cached size value. |
487 | 487 | * This is useful to detect changing window size while the application is running but may |
488 | 488 | * not get up to date values on every terminal. |
489 | - * @return array|bool An array of ($width, $height) or false when it was not able to determine size. |
|
489 | + * @return string An array of ($width, $height) or false when it was not able to determine size. |
|
490 | 490 | */ |
491 | 491 | public static function getScreenSize($refresh = false) |
492 | 492 | { |
@@ -715,7 +715,7 @@ discard block |
||
715 | 715 | * |
716 | 716 | * @param string $message to print out before waiting for user input |
717 | 717 | * @param bool $default this value is returned if no selection is made. |
718 | - * @return bool whether user confirmed |
|
718 | + * @return boolean|null whether user confirmed |
|
719 | 719 | */ |
720 | 720 | public static function confirm($message, $default = false) |
721 | 721 | { |
@@ -737,6 +737,9 @@ discard block |
||
737 | 737 | } |
738 | 738 | } |
739 | 739 | |
740 | + /** |
|
741 | + * @param string $prompt |
|
742 | + */ |
|
740 | 743 | public static function selectBox($prompt, $items = [], $selected = []) |
741 | 744 | { |
742 | 745 | echo "\n" . $prompt . "\n\n"; |
@@ -420,7 +420,7 @@ discard block |
||
420 | 420 | |
421 | 421 | |
422 | 422 | /** |
423 | - * @param $name |
|
423 | + * @param string $name |
|
424 | 424 | * @return string |
425 | 425 | */ |
426 | 426 | public static function prepareFileName($name) |
@@ -634,7 +634,7 @@ discard block |
||
634 | 634 | * @param string $pattern |
635 | 635 | * @param bool $caseSensitive |
636 | 636 | * @throws InvalidArgumentException |
637 | - * @return array with keys: (string) pattern, (int) flags, (int|bool) firstWildcard |
|
637 | + * @return string with keys: (string) pattern, (int) flags, (int|bool) firstWildcard |
|
638 | 638 | */ |
639 | 639 | private static function parseExcludePattern($pattern, $caseSensitive) |
640 | 640 | { |
@@ -54,6 +54,9 @@ |
||
54 | 54 | $options->registerCommand(static::CMD_RESET_ENV, 'Reset env options'); |
55 | 55 | } |
56 | 56 | |
57 | + /** |
|
58 | + * @param string $value |
|
59 | + */ |
|
57 | 60 | protected function setEnvOption($option, $value) |
58 | 61 | { |
59 | 62 | $value = addcslashes($value, '"\\'); |