|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.gitective.core.RepositoryService
org.gitective.core.CommitFinder
public class CommitFinder
Commit finder class for locating commits based on combining
TreeFilter and RevFilter instances and performing a
RevWalk on one or more Git repositories.
| Field Summary | |
|---|---|
protected org.eclipse.jgit.revwalk.filter.RevFilter |
commitFilter
Commit filter for selecting commits to match |
protected org.eclipse.jgit.revwalk.filter.RevFilter |
commitMatcher
Commit filter for matches |
protected org.eclipse.jgit.revwalk.RevSort |
sort
Sort strategy for RevWalk |
protected org.eclipse.jgit.treewalk.filter.TreeFilter |
treeFilter
Tree filter for selecting commits to match |
| Fields inherited from class org.gitective.core.RepositoryService |
|---|
repositories |
| Constructor Summary | |
|---|---|
CommitFinder(Collection<?> repositories)
Create a commit finder for th given repository collection |
|
CommitFinder(File... gitDirs)
Create a commit finder for the given Git directories. |
|
CommitFinder(org.eclipse.jgit.lib.Repository... repositories)
Create a commit finder for the given Git repositories. |
|
CommitFinder(String... gitDirs)
Create a commit finder for the given Git directory paths. |
|
| Method Summary | |
|---|---|
protected org.eclipse.jgit.revwalk.RevWalk |
createWalk(org.eclipse.jgit.lib.Repository repository)
Create a newly configured RevWalk for the repository |
CommitFinder |
find()
Search the commits starting at the commit that HEAD current references. |
CommitFinder |
findBetween(org.eclipse.jgit.lib.ObjectId start,
org.eclipse.jgit.lib.ObjectId end)
Search the commits between the given start and end commits. |
CommitFinder |
findBetween(org.eclipse.jgit.lib.ObjectId start,
String end)
Search the commits between the given start commit id and the given end revision. |
CommitFinder |
findBetween(String start,
org.eclipse.jgit.lib.ObjectId end)
Search the commits between the given start revision and the given end commit id. |
CommitFinder |
findBetween(String start,
String end)
Search the commits between the given start revision and the given end revision. |
CommitFinder |
findFrom(org.eclipse.jgit.lib.ObjectId start)
Search the commits starting from the given commit id. |
CommitFinder |
findFrom(String start)
Search the commits starting from the given revision. |
CommitFinder |
findInBranches()
Search the commits starting at the commit that each branch is referencing. |
CommitFinder |
findInTags()
Search the commits starting at the commit that each tag is referencing. |
CommitFinder |
findUntil(org.eclipse.jgit.lib.ObjectId end)
Search the commits starting at HEAD and ending with the given commit id |
CommitFinder |
findUntil(String end)
Search the commits starting at HEAD and ending with the given revision |
CommitFinder |
setFilter(org.eclipse.jgit.revwalk.filter.RevFilter filter)
Set the RevFilter to use to filter commits during searches. |
CommitFinder |
setFilter(org.eclipse.jgit.treewalk.filter.TreeFilter filter)
Set the TreeFilter to use to limit commits visited. |
CommitFinder |
setMatcher(org.eclipse.jgit.revwalk.filter.RevFilter filter)
Set the RevFilter to use to match filtered commits. |
CommitFinder |
setReverseOrder(boolean reverse)
Set whether to use RevSort.REVERSE to sort commits |
protected CommitFinder |
walk(org.eclipse.jgit.lib.Repository repository,
org.eclipse.jgit.lib.ObjectId start,
org.eclipse.jgit.lib.ObjectId end)
Walk the commits between the start commit id and end commit id. |
protected CommitFinder |
walk(org.eclipse.jgit.revwalk.RevWalk walk)
Traverse the commits in the given RevWalk |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected org.eclipse.jgit.revwalk.filter.RevFilter commitFilter
protected org.eclipse.jgit.treewalk.filter.TreeFilter treeFilter
protected org.eclipse.jgit.revwalk.filter.RevFilter commitMatcher
protected org.eclipse.jgit.revwalk.RevSort sort
RevWalk
| Constructor Detail |
|---|
public CommitFinder(File... gitDirs)
gitDirs - public CommitFinder(org.eclipse.jgit.lib.Repository... repositories)
repositories - public CommitFinder(String... gitDirs)
gitDirs - public CommitFinder(Collection<?> repositories)
repositories - | Method Detail |
|---|
public CommitFinder setFilter(org.eclipse.jgit.revwalk.filter.RevFilter filter)
RevFilter to use to filter commits during searches.
filter -
public CommitFinder setMatcher(org.eclipse.jgit.revwalk.filter.RevFilter filter)
RevFilter to use to match filtered commits.
filter -
public CommitFinder setFilter(org.eclipse.jgit.treewalk.filter.TreeFilter filter)
TreeFilter to use to limit commits visited.
filter -
public CommitFinder setReverseOrder(boolean reverse)
RevSort.REVERSE to sort commits
This will only affect the order that commits are passed to the filter set
by calling setMatcher(RevFilter). The filter set by calling
setFilter(RevFilter) will still visit commits in starting order.
reverse -
protected org.eclipse.jgit.revwalk.RevWalk createWalk(org.eclipse.jgit.lib.Repository repository)
RevWalk for the repository
repository -
RevWalk
protected CommitFinder walk(org.eclipse.jgit.revwalk.RevWalk walk)
throws IOException
RevWalk
walk -
IOException
protected CommitFinder walk(org.eclipse.jgit.lib.Repository repository,
org.eclipse.jgit.lib.ObjectId start,
org.eclipse.jgit.lib.ObjectId end)
repository - start - must be non-nullend -
public CommitFinder findFrom(org.eclipse.jgit.lib.ObjectId start)
start -
public CommitFinder findFrom(String start)
start -
public CommitFinder find()
public CommitFinder findInTags()
Repositories that have no tags will be ignored.
public CommitFinder findInBranches()
Repositories that have no branches will be ignored.
public CommitFinder findBetween(org.eclipse.jgit.lib.ObjectId start,
org.eclipse.jgit.lib.ObjectId end)
start - end -
public CommitFinder findBetween(String start,
org.eclipse.jgit.lib.ObjectId end)
start - end -
public CommitFinder findBetween(org.eclipse.jgit.lib.ObjectId start,
String end)
start - end -
public CommitFinder findBetween(String start,
String end)
start - end -
public CommitFinder findUntil(String end)
end -
public CommitFinder findUntil(org.eclipse.jgit.lib.ObjectId end)
end -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||