public class PlotWalk extends RevWalk
Constructor and Description |
---|
PlotWalk(Repository repo)
Create a new revision walker for a given repository.
|
Modifier and Type | Method and Description |
---|---|
void |
addAdditionalRefs(Iterable<Ref> refs)
Add additional refs to the walk
|
protected RevCommit |
createCommit(AnyObjectId id)
Construct a new unparsed commit for the given object.
|
void |
dispose()
Dispose all internal state and invalidate all RevObject instances.
|
RevCommit |
next()
Pop the next most recent commit.
|
void |
sort(RevSort s,
boolean use)
Add or remove a sorting strategy for the returned commits.
|
assertNotStarted, assumeShallow, carry, carry, close, disposeFlag, getObjectReader, getRevFilter, getRevSort, getTreeFilter, hasRevSort, isMergedInto, isRetainBody, iterator, lookupAny, lookupBlob, lookupCommit, lookupOrNull, lookupTag, lookupTree, markStart, markStart, markUninteresting, newFlag, parseAny, parseAny, parseBody, parseCommit, parseHeaders, parseTag, parseTree, peel, reset, reset, resetRetain, resetRetain, retainOnReset, retainOnReset, setRetainBody, setRevFilter, setRewriteParents, setTreeFilter, sort, toObjectWalkWithSameObjects
public PlotWalk(Repository repo)
repo
- the repository the walker will obtain data from.public void dispose()
RevWalk
All RevObject (and thus RevCommit, etc.) instances previously acquired from this RevWalk are invalidated by a dispose call. Applications must not retain or use RevObject instances obtained prior to the dispose call. All RevFlag instances are also invalidated, and must not be reused.
public void addAdditionalRefs(Iterable<Ref> refs) throws IOException
refs
- additional refsIOException
public void sort(RevSort s, boolean use)
RevWalk
Multiple strategies can be applied at once, in which case some strategies
may take precedence over others. As an example, RevSort.TOPO
must
take precedence over RevSort.COMMIT_TIME_DESC
, otherwise it
cannot enforce its ordering.
protected RevCommit createCommit(AnyObjectId id)
RevWalk
createCommit
in class RevWalk
id
- the object this walker requires a commit reference for.public RevCommit next() throws MissingObjectException, IncorrectObjectTypeException, IOException
RevWalk
next
in class RevWalk
MissingObjectException
- one or or more of the next commit's parents are not available
from the object database, but were thought to be candidates
for traversal. This usually indicates a broken link.IncorrectObjectTypeException
- one or or more of the next commit's parents are not actually
commit objects.IOException
- a pack file or loose object could not be read.Copyright © 2015 Eclipse JGit Project. All rights reserved.