Class PackIndexWriterV1
- java.lang.Object
-
- org.eclipse.jgit.internal.storage.file.PackIndexWriter
-
- org.eclipse.jgit.internal.storage.file.PackIndexWriterV1
-
class PackIndexWriterV1 extends PackIndexWriter
Creates the version 1 (old style) pack table of contents files.- See Also:
PackIndexWriter
,PackIndexV1
-
-
Field Summary
-
Fields inherited from class org.eclipse.jgit.internal.storage.file.PackIndexWriter
entries, out, packChecksum, tmp, TOC
-
-
Constructor Summary
Constructors Constructor Description PackIndexWriterV1(java.io.OutputStream dst)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) static boolean
canStore(PackedObjectInfo oe)
protected void
writeImpl()
Writes the index file toPackIndexWriter.out
.-
Methods inherited from class org.eclipse.jgit.internal.storage.file.PackIndexWriter
createOldestPossible, createVersion, oldestPossibleFormat, write, writeChecksumFooter, writeFanOutTable, writeTOC
-
-
-
-
Method Detail
-
canStore
static boolean canStore(PackedObjectInfo oe)
-
writeImpl
protected void writeImpl() throws java.io.IOException
Writes the index file toPackIndexWriter.out
.Implementations should go something like:
writeFanOutTable(); for (final PackedObjectInfo po : entries) writeOneEntry(po); writeChecksumFooter();
Where the logic for
writeOneEntry
is specific to the index format in use. Additional headers/footers may be used if necessary and thePackIndexWriter.entries
collection may be iterated over more than once if necessary. Implementors therefore have complete control over the data.- Specified by:
writeImpl
in classPackIndexWriter
- Throws:
java.io.IOException
- an error occurred while writing to the output stream, or this index format cannot store the object data supplied.
-
-