Skip to content

Commit 2ac1a61

Browse files
committed
Added missing @throws tags to PHPDoc.
1 parent 4795af1 commit 2ac1a61

3 files changed

Lines changed: 15 additions & 3 deletions

File tree

src/CLI.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,8 @@ public function __construct($autocatch = true)
5656
*
5757
* @param Options $options
5858
* @return void
59+
*
60+
* @throws Exception
5961
*/
6062
abstract protected function setup(Options $options);
6163

@@ -66,6 +68,8 @@ abstract protected function setup(Options $options);
6668
*
6769
* @param Options $options
6870
* @return void
71+
*
72+
* @throws Exception
6973
*/
7074
abstract protected function main(Options $options);
7175

@@ -74,6 +78,8 @@ abstract protected function main(Options $options);
7478
*
7579
* Executes the setup() routine, adds default options, initiate the options parsing and argument checking
7680
* and finally executes main()
81+
*
82+
* @throws Exception
7783
*/
7884
public function run()
7985
{

src/Colors.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,9 +99,11 @@ public function isEnabled()
9999
/**
100100
* Convenience function to print a line in a given color
101101
*
102-
* @param string $line the line to print, a new line is added automatically
103-
* @param string $color one of the available color names
102+
* @param string $line the line to print, a new line is added automatically
103+
* @param string $color one of the available color names
104104
* @param resource $channel file descriptor to write to
105+
*
106+
* @throws Exception
105107
*/
106108
public function ptln($line, $color, $channel = STDOUT)
107109
{
@@ -158,6 +160,8 @@ public function set($color, $channel = STDOUT)
158160
* reset the terminal color
159161
*
160162
* @param resource $channel file descriptor to write to
163+
*
164+
* @throws Exception
161165
*/
162166
public function reset($channel = STDOUT)
163167
{

src/Options.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ public function parseOptions()
285285
*
286286
* @param mixed $option
287287
* @param bool|string $default what to return if the option was not set
288-
* @return bool|string
288+
* @return bool|string|string[]
289289
*/
290290
public function getOpt($option = null, $default = false)
291291
{
@@ -325,6 +325,8 @@ public function getArgs()
325325
* Builds a help screen from the available options. You may want to call it from -h or on error
326326
*
327327
* @return string
328+
*
329+
* @throws Exception
328330
*/
329331
public function help()
330332
{

0 commit comments

Comments
 (0)