public class WalkSorter extends Object
ChangeData
s based on RevWalk
ordering.
Split changes by project, and map each change to a single commit based on the latest patch
set. The set of patch sets considered may be limited by calling includePatchSets(Iterable)
. Perform a standard RevWalk
on each project repository, do
an approximate topo sort, and record the order in which each change's commit is seen.
Once an order within each project is determined, groups of changes are sorted based on the project name. This is slightly more stable than sorting on something like the commit or change timestamp, as it will not unexpectedly reorder large groups of changes on subsequent calls if one of the changes was updated.
Modifier and Type | Class and Description |
---|---|
static class |
WalkSorter.PatchSetData |
Modifier and Type | Method and Description |
---|---|
WalkSorter |
includePatchSets(Iterable<PatchSet.Id> patchSets) |
WalkSorter |
setRetainBody(boolean retainBody) |
Iterable<WalkSorter.PatchSetData> |
sort(Iterable<ChangeData> in) |
public WalkSorter includePatchSets(Iterable<PatchSet.Id> patchSets)
public WalkSorter setRetainBody(boolean retainBody)
public Iterable<WalkSorter.PatchSetData> sort(Iterable<ChangeData> in) throws com.google.gwtorm.server.OrmException, IOException
com.google.gwtorm.server.OrmException
IOException