Package com.jcabi.github
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
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classSmart PullComment with extra features. -
Method Summary
Methods inherited from interface java.lang.Comparable
compareToMethods inherited from interface com.jcabi.github.JsonPatchable
patchMethods inherited from interface com.jcabi.github.JsonReadable
json
-
Method Details
-
pull
Pull pull()Pull we're in.- Returns:
- Pull
-
number
int number()Get its number.- Returns:
- Pull comment number
-
react
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.
-