Class DfsObjectToPack
- java.lang.Object
-
- org.eclipse.jgit.lib.AnyObjectId
-
- org.eclipse.jgit.lib.ObjectId
-
- org.eclipse.jgit.lib.ObjectIdOwnerMap.Entry
-
- org.eclipse.jgit.transport.PackedObjectInfo
-
- org.eclipse.jgit.internal.storage.pack.ObjectToPack
-
- org.eclipse.jgit.internal.storage.dfs.DfsObjectToPack
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<AnyObjectId>
class DfsObjectToPack extends ObjectToPack
-
-
Field Summary
Fields Modifier and Type Field Description private static int
FLAG_FOUND
(package private) long
length
Length of the data section of the object.(package private) long
offset
Offset of the object's header inpack
.(package private) DfsPackFile
pack
Pack to reuse compressed data from, otherwise null.
-
Constructor Summary
Constructors Constructor Description DfsObjectToPack(AnyObjectId src, int type)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
clearReuseAsIs()
Forget the reuse information previously stored.(package private) boolean
isFound()
void
select(StoredObjectRepresentation ref)
Remember a specific representation for reuse at a later time.(package private) void
setFound()
-
Methods inherited from class org.eclipse.jgit.internal.storage.pack.ObjectToPack
clearExtendedFlag, getDeltaBase, getDeltaBaseId, getExtendedFlags, getType, isDeltaRepresentation, isExtendedFlag, isReuseAsIs, isWritten, setExtendedFlag, setExtendedFlags, toString
-
Methods inherited from class org.eclipse.jgit.transport.PackedObjectInfo
getCRC, getOffset, setCRC, setOffset, setType
-
Methods inherited from class org.eclipse.jgit.lib.ObjectId
equals, fromRaw, fromRaw, fromRaw, fromRaw, fromString, fromString, isId, toObjectId, toString, zeroId
-
-
-
-
Field Detail
-
FLAG_FOUND
private static final int FLAG_FOUND
- See Also:
- Constant Field Values
-
pack
DfsPackFile pack
Pack to reuse compressed data from, otherwise null.
-
offset
long offset
Offset of the object's header inpack
.
-
length
long length
Length of the data section of the object.
-
-
Constructor Detail
-
DfsObjectToPack
DfsObjectToPack(AnyObjectId src, int type)
-
-
Method Detail
-
isFound
final boolean isFound()
-
setFound
final void setFound()
-
clearReuseAsIs
protected void clearReuseAsIs()
Forget the reuse information previously stored.Implementations may subclass this method, but they must also invoke the super version with
super.clearReuseAsIs()
to ensure the flag is properly cleared for the writer.- Overrides:
clearReuseAsIs
in classObjectToPack
-
select
public void select(StoredObjectRepresentation ref)
Remember a specific representation for reuse at a later time.Implementers should remember the representation chosen, so it can be reused at a later time.
PackWriter
may invoke this method multiple times for the same object, each time saving the current best representation found.- Overrides:
select
in classObjectToPack
- Parameters:
ref
- the object representation.
-
-