JGithubPackageIssues

Extends \JGithubPackage

GitHub API Issues class for the Joomla Platform.

deprecated
documentation

https://developer.github.com/v3/issues

since

1.7.3

deprecated

4.0 Use the joomla/github package via Composer instead

property-read

GitHub API object for assignees.

GitHub API object for comments.

GitHub API object for events.

GitHub API object for labels.

GitHub API object for milestones.

package

Joomla.Platform

Methods

__construct

Constructor.

__construct(\Joomla\Registry\Registry $options = null, \JGithubHttp $client = null) 
inherited
since

1.7.3

Arguments

$options

\Joomla\Registry\RegistryGitHub options object.

$client

\JGithubHttpThe HTTP client object.

__get

Magic method to lazily create API objects

__get(string $name) : \JGithubPackage
inherited
since

3.3

throws

\RuntimeException

Arguments

$name

stringName of property to retrieve

Response

\JGithubPackageGitHub API package object.

create

Method to create an issue.

create(string $user, string $repo, string $title, string $body = null, string $assignee = null, integer $milestone = null, array $labels = null) : object
throws

\DomainException

since

1.7.3

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$title

stringThe title of the new issue.

$body

stringThe body text for the new issue.

$assignee

stringThe login for the GitHub user that this issue should be assigned to.

$milestone

integerThe milestone to associate this issue with.

$labels

arrayThe labels to associate with this issue.

Response

object

createComment

Method to create a comment on an issue.

createComment(string $user, string $repo, integer $issueId, string $body) : object
deprecated
deprecated

use issues->comments->create()

since

1.7.3

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$issueId

integerThe issue number.

$body

stringThe comment body text.

Response

object

createLabel

Method to create a label on a repo.

createLabel(string $user, string $repo, string $name, string $color) : object
deprecated
deprecated

use issues->labels->create()

since

3.1.4

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$name

stringThe label name.

$color

stringThe label color.

Response

object

deleteComment

Method to delete a comment on an issue.

deleteComment(string $user, string $repo, integer $commentId) : void
deprecated
deprecated

use issues->comments->delete()

since

1.7.3

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$commentId

integerThe id of the comment to delete.

deleteLabel

Method to delete a label on a repo.

deleteLabel(string $user, string $repo, string $label) : object
deprecated
deprecated

use issues->labels->delete()

since

3.1.4

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$label

stringThe label name.

Response

object

edit

Method to update an issue.

edit(string $user, string $repo, integer $issueId, string $state = null, string $title = null, string $body = null, string $assignee = null, integer $milestone = null, array $labels = null) : object
throws

\DomainException

since

1.7.3

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$issueId

integerThe issue number.

$state

stringThe optional new state for the issue. [open, closed]

$title

stringThe title of the new issue.

$body

stringThe body text for the new issue.

$assignee

stringThe login for the GitHub user that this issue should be assigned to.

$milestone

integerThe milestone to associate this issue with.

$labels

arrayThe labels to associate with this issue.

Response

object

editComment

Method to update a comment on an issue.

editComment(string $user, string $repo, integer $commentId, string $body) : object
deprecated
deprecated

use issues->comments->edit()

since

1.7.3

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$commentId

integerThe id of the comment to update.

$body

stringThe new body text for the comment.

Response

object

editLabel

Method to update a label on a repo.

editLabel(string $user, string $repo, string $label, string $name, string $color) : object
deprecated
deprecated

use issues->labels->update()

since

3.1.4

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$label

stringThe label name.

$name

stringThe label name.

$color

stringThe label color.

Response

object

fetchUrl

Method to build and return a full request URL for the request. This method will add appropriate pagination details if necessary and also prepend the API url to have a complete URL for the request.

fetchUrl(string $path, integer $page, integer $limit) : string
inherited
since

1.7.3

Arguments

$path

stringURL to inflect

$page

integerPage to request

$limit

integerNumber of results to return per page

Response

stringThe request URL.

get

Method to get a single issue.

get(string $user, string $repo, integer $issueId) : object
throws

\DomainException

since

1.7.3

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$issueId

integerThe issue number.

Response

object

getComment

Method to get a specific comment on an issue.

getComment(string $user, string $repo, integer $commentId) : object
deprecated
deprecated

use issues->comments->get()

since

1.7.3

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$commentId

integerThe comment id to get.

Response

object

getComments

Method to get the list of comments on an issue.

getComments(string $user, string $repo, integer $issueId, integer $page, integer $limit) : array
deprecated
deprecated

use issues->comments->getList()

since

1.7.3

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$issueId

integerThe issue number.

$page

integerThe page number from which to get items.

$limit

integerThe number of items on a page.

Response

array

getLabel

Method to get a specific label on a repo.

getLabel(string $user, string $repo, string $name) : object
deprecated
deprecated

use issues->labels->get()

since

3.1.4

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$name

stringThe label name to get.

Response

object

getLabels

Method to get the list of labels on a repo.

getLabels(string $user, string $repo) : array
deprecated
deprecated

use issues->labels->getList()

since

3.1.4

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

Response

array

getList

Method to list an authenticated user's issues.

getList(string $filter = null, string $state = null, string $labels = null, string $sort = null, string $direction = null, \JDate $since = null, integer $page, integer $limit) : array
throws

\DomainException

since

1.7.3

Arguments

$filter

stringThe filter type: assigned, created, mentioned, subscribed.

$state

stringThe optional state to filter requests by. [open, closed]

$labels

stringThe list of comma separated Label names. Example: bug,ui,@high.

$sort

stringThe sort order: created, updated, comments, default: created.

$direction

stringThe list direction: asc or desc, default: desc.

$since

\JDateThe date/time since when issues should be returned.

$page

integerThe page number from which to get items.

$limit

integerThe number of items on a page.

Response

array

getListByRepository

Method to list issues.

getListByRepository(string $user, string $repo, string $milestone = null, string $state = null, string $assignee = null, string $mentioned = null, string $labels = null, string $sort = null, string $direction = null, \JDate $since = null, integer $page, integer $limit) : array
throws

\DomainException

since

1.7.3

Arguments

$user

stringThe name of the owner of the GitHub repository.

$repo

stringThe name of the GitHub repository.

$milestone

stringThe milestone number, 'none', or *.

$state

stringThe optional state to filter requests by. [open, closed]

$assignee

stringThe assignee name, 'none', or *.

$mentioned

stringThe GitHub user name.

$labels

stringThe list of comma separated Label names. Example: bug,ui,@high.

$sort

stringThe sort order: created, updated, comments, default: created.

$direction

stringThe list direction: asc or desc, default: desc.

$since

\JDateThe date/time since when issues should be returned.

$page

integerThe page number from which to get items.

$limit

integerThe number of items on a page.

Response

array

processResponse

Process the response and decode it.

processResponse(\JHttpResponse $response, integer $expectedCode = 200, boolean $decode = true) : mixed
inherited
throws

\DomainException

since

3.3.0

Arguments

$response

\JHttpResponseThe response.

$expectedCode

integerThe expected "good" code.

$decode

booleanIf the should be response be JSON decoded.

Response

mixed

Properties

name

inherited
since

3.3

Type(s)

string

packages

inherited
since

3.3

Type(s)

array

options

Options for the GitHub object.

inherited
since

1.7.3

Type(s)

\Joomla\Registry\Registry

client

The HTTP client object to use in sending HTTP requests.

inherited
since

1.7.3

Type(s)

\JGithubHttp

assignees

GitHub API object for assignees.

Type(s)

\JGithubPackageIssuesAssignees

comments

GitHub API object for comments.

Type(s)

\JGithubPackageIssuesComments

events

GitHub API object for events.

Type(s)

\JGithubPackageIssuesEvents

labels

GitHub API object for labels.

Type(s)

\JGithubPackageIssuesLabels

milestones

GitHub API object for milestones.

Type(s)

\JGithubPackageIssuesMilestones