|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.eclipse.jgit.lib.PackFile
public class PackFile
A Git version 2 pack file representation. A pack file contains Git objects in delta packed format yielding high compression of lots of object where some objects are similar.
| Field Summary | |
|---|---|
static java.util.Comparator<PackFile> |
SORT
Sorts PackFiles to be most recently created to least recently created. |
| Constructor Summary | |
|---|---|
PackFile(java.io.File idxFile,
java.io.File packFile)
Construct a reader for an existing, pre-indexed packfile. |
|
| Method Summary | |
|---|---|
void |
close()
Close the resources utilized by this repository |
org.eclipse.jgit.lib.PackedObjectLoader |
get(WindowCursor curs,
AnyObjectId id)
Get an object from this pack. |
java.io.File |
getPackFile()
|
boolean |
hasObject(AnyObjectId id)
Determine if an object is contained within the pack file. |
java.util.Iterator<PackIndex.MutableEntry> |
iterator()
Provide iterator over entries in associated pack index, that should also exist in this pack file. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static java.util.Comparator<PackFile> SORT
| Constructor Detail |
|---|
public PackFile(java.io.File idxFile,
java.io.File packFile)
idxFile - path of the .idx file listing the contents.packFile - path of the .pack file holding the data.| Method Detail |
|---|
public java.io.File getPackFile()
public boolean hasObject(AnyObjectId id)
throws java.io.IOException
For performance reasons only the index file is searched; the main pack content is ignored entirely.
id - the object to look for. Must not be null.
java.io.IOException - the index file cannot be loaded into memory.
public org.eclipse.jgit.lib.PackedObjectLoader get(WindowCursor curs,
AnyObjectId id)
throws java.io.IOException
curs - temporary working space associated with the calling thread.id - the object to obtain from the pack. Must not be null.
java.io.IOException - the pack file or the index could not be read.public void close()
public java.util.Iterator<PackIndex.MutableEntry> iterator()
Iterator returns objects in SHA-1 lexicographical order.
iterator in interface java.lang.Iterable<PackIndex.MutableEntry>PackIndex.iterator()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||