Skip to content

Commit 5dbecd0

Browse files
committed
Add throws phpdoc tag to list() methods
1 parent 98f39bf commit 5dbecd0

19 files changed

+58
-0
lines changed

src/Redmine/Api/CustomField.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Redmine\Api;
44

55
use Redmine\Exception;
6+
use Redmine\Exception\SerializerException;
67

78
/**
89
* Listing custom fields.
@@ -22,6 +23,8 @@ class CustomField extends AbstractApi
2223
*
2324
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
2425
*
26+
* @throws SerializerException if response body could not be converted into array
27+
*
2528
* @return array list of custom fields found
2629
*/
2730
final public function list(array $params = []): array

src/Redmine/Api/Group.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use Redmine\Exception;
66
use Redmine\Exception\MissingParameterException;
7+
use Redmine\Exception\SerializerException;
78
use Redmine\Serializer\PathSerializer;
89
use Redmine\Serializer\XmlSerializer;
910

@@ -25,6 +26,8 @@ class Group extends AbstractApi
2526
*
2627
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
2728
*
29+
* @throws SerializerException if response body could not be converted into array
30+
*
2831
* @return array list of groups found
2932
*/
3033
final public function list(array $params = []): array

src/Redmine/Api/Issue.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Redmine\Api;
44

55
use Redmine\Exception;
6+
use Redmine\Exception\SerializerException;
67
use Redmine\Serializer\JsonSerializer;
78
use Redmine\Serializer\PathSerializer;
89
use Redmine\Serializer\XmlSerializer;
@@ -39,6 +40,8 @@ class Issue extends AbstractApi
3940
*
4041
* @param array $params the additional parameters (cf available $params above)
4142
*
43+
* @throws SerializerException if response body could not be converted into array
44+
*
4245
* @return array list of issues found
4346
*/
4447
final public function list(array $params = []): array

src/Redmine/Api/IssueCategory.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
use Redmine\Exception;
66
use Redmine\Exception\InvalidParameterException;
77
use Redmine\Exception\MissingParameterException;
8+
use Redmine\Exception\SerializerException;
89
use Redmine\Serializer\PathSerializer;
910
use Redmine\Serializer\XmlSerializer;
1011

@@ -28,6 +29,7 @@ class IssueCategory extends AbstractApi
2829
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
2930
*
3031
* @throws InvalidParameterException if $projectIdentifier is not of type int or string
32+
* @throws SerializerException if response body could not be converted into array
3133
*
3234
* @return array list of issue categories found
3335
*/

src/Redmine/Api/IssuePriority.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Redmine\Api;
44

55
use Redmine\Exception;
6+
use Redmine\Exception\SerializerException;
67

78
/**
89
* Listing issue priorities.
@@ -22,6 +23,8 @@ class IssuePriority extends AbstractApi
2223
*
2324
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
2425
*
26+
* @throws SerializerException if response body could not be converted into array
27+
*
2528
* @return array list of issue priorities found
2629
*/
2730
final public function list(array $params = []): array

src/Redmine/Api/IssueRelation.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Redmine\Api;
44

55
use Redmine\Exception;
6+
use Redmine\Exception\SerializerException;
67
use Redmine\Serializer\JsonSerializer;
78

89
/**
@@ -24,6 +25,8 @@ class IssueRelation extends AbstractApi
2425
* @param int $issueId the issue id
2526
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
2627
*
28+
* @throws SerializerException if response body could not be converted into array
29+
*
2730
* @return array list of relations found
2831
*/
2932
final public function listByIssueId(int $issueId, array $params = []): array

src/Redmine/Api/IssueStatus.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Redmine\Api;
44

55
use Redmine\Exception;
6+
use Redmine\Exception\SerializerException;
67

78
/**
89
* Listing issue statuses.
@@ -22,6 +23,8 @@ class IssueStatus extends AbstractApi
2223
*
2324
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
2425
*
26+
* @throws SerializerException if response body could not be converted into array
27+
*
2528
* @return array list of issue statuses found
2629
*/
2730
final public function list(array $params = []): array

src/Redmine/Api/Membership.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
use Redmine\Exception;
66
use Redmine\Exception\InvalidParameterException;
77
use Redmine\Exception\MissingParameterException;
8+
use Redmine\Exception\SerializerException;
89
use Redmine\Serializer\XmlSerializer;
910

1011
/**
@@ -27,6 +28,7 @@ class Membership extends AbstractApi
2728
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
2829
*
2930
* @throws InvalidParameterException if $projectIdentifier is not of type int or string
31+
* @throws SerializerException if response body could not be converted into array
3032
*
3133
* @return array list of memberships found
3234
*/

src/Redmine/Api/News.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use Redmine\Exception;
66
use Redmine\Exception\InvalidParameterException;
7+
use Redmine\Exception\SerializerException;
78

89
/**
910
* @see http://www.redmine.org/projects/redmine/wiki/Rest_News
@@ -22,6 +23,9 @@ class News extends AbstractApi
2223
* @param string|int $projectIdentifier project id or literal identifier
2324
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
2425
*
26+
* @throws InvalidParameterException if $projectIdentifier is not of type int or string
27+
* @throws SerializerException if response body could not be converted into array
28+
*
2529
* @return array list of news found
2630
*/
2731
final public function listByProject($projectIdentifier, array $params = []): array
@@ -45,6 +49,8 @@ final public function listByProject($projectIdentifier, array $params = []): arr
4549
*
4650
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
4751
*
52+
* @throws SerializerException if response body could not be converted into array
53+
*
4854
* @return array list of news found
4955
*/
5056
final public function list(array $params = []): array

src/Redmine/Api/Project.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use Redmine\Exception;
66
use Redmine\Exception\MissingParameterException;
7+
use Redmine\Exception\SerializerException;
78
use Redmine\Serializer\PathSerializer;
89
use Redmine\Serializer\XmlSerializer;
910

@@ -25,6 +26,8 @@ class Project extends AbstractApi
2526
*
2627
* @param array $params optional parameters to be passed to the api (offset, limit, ...)
2728
*
29+
* @throws SerializerException if response body could not be converted into array
30+
*
2831
* @return array list of projects found
2932
*/
3033
final public function list(array $params = []): array

0 commit comments

Comments
 (0)