$api
$api : \duncan3dc\GitHub\ApiInterface
$api : \duncan3dc\GitHub\ApiInterface
$repository : \duncan3dc\GitHub\RepositoryInterface
getAll(string $url, array $data = array(), callable $callback = null) : \Traversable|array<mixed,\stdClass>
Send a GET request and return the response.
This method will loop through all the pages until one returns no results
string | $url | The url to issue the request to |
array | $data | The parameters to send with the request |
callable | $callback | An optional handler to yield items via |
__construct(\duncan3dc\GitHub\RepositoryInterface $repository, integer $number, \duncan3dc\GitHub\ApiInterface $api)
Create a new instance.
\duncan3dc\GitHub\RepositoryInterface | $repository | The repository this pr is part of |
integer | $number | The unique ID of this pr |
\duncan3dc\GitHub\ApiInterface | $api | The Api instance to communicate with GitHub. |
getRepository() : \duncan3dc\GitHub\RepositoryInterface
Get the repository this pr is from.
withCommit(\duncan3dc\GitHub\string $commit) : \duncan3dc\GitHub\PullRequestInterface
Set the version of this pr we are working with.
\duncan3dc\GitHub\string | $commit | The full sha of the commit in the pr |