@Override /*package*/ GHUser[] getItems(GitHub root) { return GHUser.wrap(items,root); } }
/*package*/ GHIssue wrap(GitHub root) { this.root = root; if(assignee != null) assignee.wrapUp(root); if(assignees!=null) GHUser.wrap(assignees,root); if(user != null) user.wrapUp(root); if(closed_by != null) closed_by.wrapUp(root); return this; }
/*package*/ GHIssue wrap(GitHub root) { this.root = root; if(assignee != null) assignee.wrapUp(root); if(assignees!=null) GHUser.wrap(assignees,root); if(user != null) user.wrapUp(root); if(closed_by != null) closed_by.wrapUp(root); return this; }
@Override /*package*/ GHUser[] getItems(GitHub root) { return GHUser.wrap(items,root); } }
GHPullRequest wrapUp(GitHub root) { if (owner != null) owner.wrap(root); if (base != null) base.wrapUp(root); if (head != null) head.wrapUp(root); if (merged_by != null) merged_by.wrapUp(root); if (requested_reviewers != null) GHUser.wrap(requested_reviewers, root); return this; }
@Override /*package*/ GHUser[] getItems(GitHub root) { return GHUser.wrap(items,root); } }
GHPullRequest wrapUp(GitHub root) { if (owner != null) owner.wrap(root); if (base != null) base.wrapUp(root); if (head != null) head.wrapUp(root); if (merged_by != null) merged_by.wrapUp(root); if (requested_reviewers != null) GHUser.wrap(requested_reviewers, root); return this; }
/** * Gets the names of the collaborators on this repository. * This method deviates from the principle of this library but it works a lot faster than {@link #getCollaborators()}. */ public Set<String> getCollaboratorNames() throws IOException { Set<String> r = new HashSet<String>(); for (GHUser u : GHUser.wrap(root.retrieve().to(getApiTailUrl("collaborators"), GHUser[].class),root)) r.add(u.login); return r; }
/** * Gets the names of the collaborators on this repository. * This method deviates from the principle of this library but it works a lot faster than {@link #getCollaborators()}. */ public Set<String> getCollaboratorNames() throws IOException { Set<String> r = new HashSet<String>(); for (GHUser u : GHUser.wrap(root.retrieve().to(getApiTailUrl("collaborators"), GHUser[].class),root)) r.add(u.login); return r; }
/** * Gets the names of the collaborators on this repository. * This method deviates from the principle of this library but it works a lot faster than {@link #getCollaborators()}. */ public Set<String> getCollaboratorNames() throws IOException { Set<String> r = new HashSet<String>(); for (GHUser u : GHUser.wrap(root.retrieve().to(getApiTailUrl("collaborators"), GHUser[].class),root)) r.add(u.login); return r; }
/** * Lists the users that this user is following */ @WithBridgeMethods(Set.class) public GHPersonSet<GHUser> getFollows() throws IOException { GHUser[] followers = root.retrieve().to("/users/" + login + "/following", GHUser[].class); return new GHPersonSet<GHUser>(Arrays.asList(wrap(followers,root))); }
/** * Lists the users who are following this user. */ @WithBridgeMethods(Set.class) public GHPersonSet<GHUser> getFollowers() throws IOException { GHUser[] followers = root.retrieve().to("/users/" + login + "/followers", GHUser[].class); return new GHPersonSet<GHUser>(Arrays.asList(wrap(followers,root))); }