Interface PullComment

  • All Superinterfaces:
    Comparable<PullComment>, JsonPatchable, JsonReadable
    All Known Implementing Classes:
    PullComment.Smart

    @Immutable
    public interface PullComment
    extends JsonReadable, JsonPatchable, Comparable<PullComment>
    Github pull comment.

    PullComment implements JsonReadable, that's how you can get its full details in JSON format. For example, to get its id, you get the entire JSON and then gets its element:

    String id = comment.jsn().getString("id");

    However, it's better to use a supplementary "smart" decorator, which automates most of these operations:

    String id = new PullComment.Smart(comment).identifier();
    Since:
    0.8
    Version:
    $Id: 0a9fac66209b5e52aedcfe2dae58b2b668c85172 $
    Author:
    Carlos Miranda (miranda.cma@gmail.com)
    See Also:
    Pull Comments API
    • Method Detail

      • pull

        Pull pull()
        Pull we're in.
        Returns:
        Pull
      • number

        int number()
        Get its number.
        Returns:
        Pull comment number
      • react

        void react​(Reaction reaction)
        Adds the reaction to the pull comment.
        Parameters:
        reaction - Reaction to be added.
      • reactions

        Collection<Reaction> reactions()
        List the reactions of the pull comment.
        Returns:
        Comment reactions.