PackWriter to select commits for which to build
pack index bitmaps.
| Modifier and Type | Class and Description |
|---|---|
| private static class | PackWriterBitmapPreparer.
Container for state used in the first phase of selecting commits, which
walks all of the reachable commits via the branch tips that are not
covered by a previous pack's bitmaps ( |
| private static class | PackWriterBitmapPreparer.
A RevFilter that excludes the commits named in a bitmap from the walk. |
| Modifier and Type | Field and Description |
|---|---|
| private final BitmapIndexImpl | |
| private final PackBitmapIndexRemapper | |
| private final BitmapIndexImpl | |
| private final int | |
| private static final int | |
| private static final int | |
| private final int | |
| private final int | |
| private final int | |
| private final long | |
| private static final Comparator | |
| private final ProgressMonitor | |
| private final ObjectReader | |
| private final int | |
| private final int | |
| private final Set | |
| private final PackBitmapIndexBuilder |
| Access | Constructor and Description |
|---|---|
| pack-priv | PackWriterBitmapPreparer(ObjectReader reader, PackBitmapIndexBuilder writeBitmaps, ProgressMonitor pm, Set<? extends ObjectId> want, PackConfig config)
|
| Modifier and Type | Method and Description |
|---|---|
| private PackWriterBitmapPreparer. | Returns: aCommitSelectionHelper capturing which commits are
covered by a previous pack's bitmaps and which new commits need
bitmap coveragea rw, int RevWalk to find reachable objects in this repositoryexpected count of commits. The actual count may be less due to
unreachable garbage. expectedCommitCount, Set<? extends ObjectId> commits that should be excluded from bitmap selection excludeFromBitmapSelection)Records which of the |
| private boolean | |
| pack-priv BitmapWalker | |
| pack-priv int | |
| pack-priv Collection | Returns: commit objects for which bitmap indices should be builtcount of commits in the pack expectedCommitCount, Set<? extends ObjectId> commits that should be excluded from bitmap selection excludeFromBitmapSelection)Returns the commit objects for which bitmap indices should be built. |
| bitmapIndex | back to summary |
|---|---|
| private final BitmapIndexImpl bitmapIndex | |
| bitmapRemapper | back to summary |
|---|---|
| private final PackBitmapIndexRemapper bitmapRemapper | |
| commitBitmapIndex | back to summary |
|---|---|
| private final BitmapIndexImpl commitBitmapIndex | |
| contiguousCommitCount | back to summary |
|---|---|
| private final int contiguousCommitCount | |
| DAY_IN_SECONDS | back to summary |
|---|---|
| private static final int DAY_IN_SECONDS | |
| DISTANCE_THRESHOLD | back to summary |
|---|---|
| private static final int DISTANCE_THRESHOLD | |
| distantCommitSpan | back to summary |
|---|---|
| private final int distantCommitSpan | |
| excessiveBranchCount | back to summary |
|---|---|
| private final int excessiveBranchCount | |
| excessiveBranchTipCount | back to summary |
|---|---|
| private final int excessiveBranchTipCount | |
| inactiveBranchTimestamp | back to summary |
|---|---|
| private final long inactiveBranchTimestamp | |
| ORDER_BY_REVERSE_TIMESTAMP | back to summary |
|---|---|
| private static final Comparator<RevCommit> ORDER_BY_REVERSE_TIMESTAMP | |
| pm | back to summary |
|---|---|
| private final ProgressMonitor pm | |
| reader | back to summary |
|---|---|
| private final ObjectReader reader | |
| recentCommitCount | back to summary |
|---|---|
| private final int recentCommitCount | |
| recentCommitSpan | back to summary |
|---|---|
| private final int recentCommitSpan | |
| want | back to summary |
|---|---|
| private final Set<? extends ObjectId> want | |
| writeBitmaps | back to summary |
|---|---|
| private final PackBitmapIndexBuilder writeBitmaps | |
| PackWriterBitmapPreparer | back to summary |
|---|---|
| pack-priv PackWriterBitmapPreparer(ObjectReader reader, PackBitmapIndexBuilder writeBitmaps, ProgressMonitor pm, Set<? extends ObjectId> want, PackConfig config) throws IOException | |
| captureOldAndNewCommits | back to summary |
|---|---|
| private PackWriterBitmapPreparer. Records which of the
| |
| isRecentCommit | back to summary |
|---|---|
| private boolean isRecentCommit(RevCommit revCommit) | |
| newBitmapWalker | back to summary |
|---|---|
| pack-priv BitmapWalker newBitmapWalker() | |
| nextSpan | back to summary |
|---|---|
| pack-priv int nextSpan(int distanceFromTip) | |
| selectCommits | back to summary |
|---|---|
| pack-priv Collection Returns the commit objects for which bitmap indices should be built.
| |
newWants) and stores them
in newCommitsByOldest. newCommitsByOldest is initialized
with an expected size of all commits, but may be smaller if some commits
are unreachable and/or some commits are covered by a previous pack's
bitmaps. commitStartPos will contain a positive offset to either
the root commit or the oldest commit not covered by previous bitmaps.
| Modifier and Type | Field and Description |
|---|---|
| pack-priv final RevCommit[] | |
| pack-priv final int | |
| pack-priv final Set | |
| pack-priv final List | |
| pack-priv final List | |
| pack-priv final BitmapIndex. |
| Access | Constructor and Description |
|---|---|
| pack-priv | CommitSelectionHelper(Set<? extends ObjectId> newWants, RevCommit[] commitsByOldest, int commitStartPos, List<RevCommit> newWantsByNewest, BitmapIndex.
|
| newCommitsByOldest | back to summary |
|---|---|
| pack-priv final RevCommit[] newCommitsByOldest | |
| newCommitStartPos | back to summary |
|---|---|
| pack-priv final int newCommitStartPos | |
| newWants | back to summary |
|---|---|
| pack-priv final Set<? extends ObjectId> newWants | |
| newWantsByNewest | back to summary |
|---|---|
| pack-priv final List<RevCommit> newWantsByNewest | |
| reusedCommits | back to summary |
|---|---|
| pack-priv final List<BitmapCommit> reusedCommits | |
| reusedCommitsBitmap | back to summary |
|---|---|
| pack-priv final BitmapIndex. | |
| CommitSelectionHelper | back to summary |
|---|---|
| pack-priv CommitSelectionHelper(Set<? extends ObjectId> newWants, RevCommit[] commitsByOldest, int commitStartPos, List<RevCommit> newWantsByNewest, BitmapIndex. | |
| getCommitCount | back to summary |
|---|---|
| pack-priv int getCommitCount() | |
| iterator | back to summary |
|---|---|
| public Iterator Implements java. Doc from java. Returns an iterator over elements of type | |
If a commit is in bitmap then that commit is not emitted by the
walk and its parents are marked as SEEN so the walk can skip them. The
bitmaps passed in have the property that the parents of any commit in
bitmap are also in bitmap, so marking the parents as
SEEN speeds up the RevWalk by saving it from walking down blind alleys
and does not change the commits emitted.
| Modifier and Type | Field and Description |
|---|---|
| private final BitmapIndex. |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public final PackWriterBitmapPreparer. | clone()
Implements abstract org. Creates and returns a copy of this object. |
| public final boolean | include(RevWalk
the active walker this filter is being invoked from within. rw, RevCommit the commit currently being tested. The commit has been parsed
and its body is available for inspection only if the filter
returns true from c)requiresCommitBody().Implements abstract org. Determine if the supplied commit should be included in results. |
| public final boolean | requiresCommitBody()
Overrides org. Whether the filter needs the commit body to be parsed. |
| bitmap | back to summary |
|---|---|
| private final BitmapIndex. | |
| NotInBitmapFilter | back to summary |
|---|---|
| pack-priv NotInBitmapFilter(BitmapIndex. | |
| clone | back to summary |
|---|---|
| public final PackWriterBitmapPreparer. Implements abstract org. Doc from org. Creates and returns a copy of this object. The precise meaning
of "copy" may depend on the class of the object. The general
intent is that, for any object will be true, and that the expression:x.clone() != x will bex.clone().getClass() == x.getClass() true, but these are not absolute requirements.
While it is typically the case that:
will bex.clone().equals(x) true, this is not an absolute requirement.
By convention, the returned object should be obtained by calling
By convention, the object returned by this method should be independent
of this object (which is being cloned). To achieve this independence,
it may be necessary to modify one or more fields of the object returned
by Clone this revision filter, including its parameters. This is a deep clone. If this filter embeds objects or other filters it must also clone those, to ensure the instances do not share mutable data.
| |
| include | back to summary |
|---|---|
| public final boolean include(RevWalk rw, RevCommit c) Implements abstract org. Doc from org. Determine if the supplied commit should be included in results.
| |
| requiresCommitBody | back to summary |
|---|---|
| public final boolean requiresCommitBody() Overrides org. Doc from org. Whether the filter needs the commit body to be parsed.
| |