public final class BitmapWalker extends Object
Constructor and Description |
---|
BitmapWalker(ObjectWalk walker,
BitmapIndex bitmapIndex,
ProgressMonitor pm)
Create a BitmapWalker.
|
Modifier and Type | Method and Description |
---|---|
BitmapIndex.BitmapBuilder |
findObjects(Iterable<? extends ObjectId> start,
BitmapIndex.BitmapBuilder seen,
boolean ignoreMissing)
Return, as a bitmap, the objects reachable from the objects in start.
|
long |
getCountOfBitmapIndexMisses()
Return the number of objects that had to be walked because they were not covered by a
bitmap.
|
void |
setPrevBitmap(BitmapIndex.Bitmap prevBitmap)
Set the bitmap associated with the cached commit for the walker.
|
void |
setPrevCommit(AnyObjectId prevCommit)
Set the cached commit for the walker.
|
public BitmapWalker(ObjectWalk walker, BitmapIndex bitmapIndex, ProgressMonitor pm)
walker
- walker to use when traversing the object graph.bitmapIndex
- index to obtain bitmaps from.pm
- progress monitor to report progress on.public void setPrevCommit(AnyObjectId prevCommit)
prevCommit
- the cached commit.public void setPrevBitmap(BitmapIndex.Bitmap prevBitmap)
prevBitmap
- the bitmap associated with the cached commit.public long getCountOfBitmapIndexMisses()
public BitmapIndex.BitmapBuilder findObjects(Iterable<? extends ObjectId> start, BitmapIndex.BitmapBuilder seen, boolean ignoreMissing) throws MissingObjectException, IncorrectObjectTypeException, IOException
start
- the objects to start the object traversal from.seen
- the objects to skip if encountered during traversal.ignoreMissing
- true to ignore missing objects, false otherwise.MissingObjectException
- the object supplied is not available from the object
database. This usually indicates the supplied object is
invalid, but the reference was constructed during an earlier
invocation to
RevWalk.lookupAny(AnyObjectId, int)
.IncorrectObjectTypeException
- the object was not parsed yet and it was discovered during
parsing that it is not actually the type of the instance
passed in. This usually indicates the caller used the wrong
type in a
RevWalk.lookupAny(AnyObjectId, int)
call.IOException
- a pack file or loose object could not be read.Copyright © 2021 Eclipse JGit Project. All rights reserved.