public class GroupCollector extends Object
ReceiveCommits
.
For each commit encountered along a walk between the branch tip and the tip of the push, the group of a commit is defined as follows:
PatchSet
record.
Callers must call visit(RevCommit)
on all commits between the
current branch tip and the tip of a push, in reverse topo order (parents
before children). Once all commits have been visited, call getGroups()
for the result.
Modifier and Type | Method and Description |
---|---|
static GroupCollector |
create(com.google.common.collect.Multimap<org.eclipse.jgit.lib.ObjectId,org.eclipse.jgit.lib.Ref> changeRefsById,
com.google.gerrit.reviewdb.server.ReviewDb db,
PatchSetUtil psUtil,
ChangeNotes.Factory notesFactory,
com.google.gerrit.reviewdb.client.Project.NameKey project) |
static GroupCollector |
createForSchemaUpgradeOnly(com.google.common.collect.Multimap<org.eclipse.jgit.lib.ObjectId,org.eclipse.jgit.lib.Ref> changeRefsById,
com.google.gerrit.reviewdb.server.ReviewDb db) |
static List<String> |
getDefaultGroups(org.eclipse.jgit.lib.ObjectId commit) |
static List<String> |
getDefaultGroups(com.google.gerrit.reviewdb.client.PatchSet ps) |
com.google.common.collect.SortedSetMultimap<org.eclipse.jgit.lib.ObjectId,String> |
getGroups() |
static List<String> |
getGroups(RevisionResource rsrc) |
void |
visit(org.eclipse.jgit.revwalk.RevCommit c) |
public static List<String> getDefaultGroups(com.google.gerrit.reviewdb.client.PatchSet ps)
public static List<String> getGroups(RevisionResource rsrc)
public static GroupCollector create(com.google.common.collect.Multimap<org.eclipse.jgit.lib.ObjectId,org.eclipse.jgit.lib.Ref> changeRefsById, com.google.gerrit.reviewdb.server.ReviewDb db, PatchSetUtil psUtil, ChangeNotes.Factory notesFactory, com.google.gerrit.reviewdb.client.Project.NameKey project)
public static GroupCollector createForSchemaUpgradeOnly(com.google.common.collect.Multimap<org.eclipse.jgit.lib.ObjectId,org.eclipse.jgit.lib.Ref> changeRefsById, com.google.gerrit.reviewdb.server.ReviewDb db)
public void visit(org.eclipse.jgit.revwalk.RevCommit c)
public com.google.common.collect.SortedSetMultimap<org.eclipse.jgit.lib.ObjectId,String> getGroups() throws com.google.gwtorm.server.OrmException, NoSuchChangeException
com.google.gwtorm.server.OrmException
NoSuchChangeException