Interface Issue

All Superinterfaces:
Comparable<Issue>, JsonPatchable, JsonReadable
All Known Implementing Classes:
Issue.Smart, SfIssue

@Immutable public interface Issue extends Comparable<Issue>, JsonReadable, JsonPatchable
GitHub issue.

Use a supplementary "smart" decorator to get other properties from an issue, for example:

 Issue.Smart issue = new Issue.Smart(origin);
 if (issue.isOpen()) {
   issue.close();
 }
Since:
0.1
See Also:
To do:
#1462:30min Implement lock reason validation. According to documentation lock reason must belong to a specific value domain. This validation must be performed in lock method and tests must be added to ensure that the class is accepting the correct values and rejecting the wrong ones.
Suppressed Checkstyle violations:
MultipleStringLiterals (500 lines)
  • Field Details

  • Method Details

    • repo

      Repo repo()
      Repository we're in.
      Returns:
      Repo
    • number

      int number()
      Get its number.
      Returns:
      Issue number
    • comments

      Comments comments()
      Get all comments of the issue.
      Returns:
      Comments
      See Also:
    • labels

      IssueLabels labels()
      Get all labels of the issue.
      Returns:
      Labels
      See Also:
    • events

      Iterable<Event> events() throws IOException
      Get all events of the issue.
      Returns:
      Events
      Throws:
      IOException - If there is any I/O problem
      See Also:
    • exists

      boolean exists() throws IOException
      Does this issue exist in GitHub?
      Returns:
      TRUE if this issue exists
      Throws:
      IOException - If there is any I/O problem
    • react

      void react(Reaction reaction) throws IOException
      Adds the reaction to the issue.
      Parameters:
      reaction - Reaction to be added.
      Throws:
      IOException - If there is any I/O problem
    • reactions

      Iterable<Reaction> reactions()
      List the reactions of the issue.
      Returns:
      Issue reactions.
    • lock

      void lock(String reason)
      Locks the issue.
      Parameters:
      reason - Lock reason
    • unlock

      void unlock()
      Unlocks the issue.
    • isLocked

      boolean isLocked()
      The issue conversation is locked?
      Returns:
      If the issue is locked.