Top Description Methods
org.eclipse.jgit.internal.storage.file

public Interface PackObjectSizeIndex

Known Direct Implementers
org.eclipse.jgit.internal.storage.file.PackObjectSizeIndexV1, org.eclipse.jgit.internal.storage.file.PackObjectSizeIndexV1.EmptyPackObjectSizeIndex

Index of object sizes in a pack It is not guaranteed that the implementation contains the sizes of all objects (e.g. it could store only objects over certain threshold).

Method Summary

Modifier and TypeMethod and Description
public long

Returns:

number of objects in the index
getObjectCount
()

Number of objects in the index

public long

Returns:

size of the object, -1 if not found in the index.
getSize
(int
position in the pack (as returned from PackIndex)
idxOffset
)

Returns the inflated size of the object.

public int

Returns:

size in bytes
getThreshold
()

Minimal size of an object to be included in this index Cut-off value used at generation time to decide what objects to index.

Method Detail

getObjectCountback to summary
public long getObjectCount()

Number of objects in the index

Returns:long

number of objects in the index

getSizeback to summary
public long getSize(int idxOffset)

Returns the inflated size of the object.

Parameters
idxOffset:int

position in the pack (as returned from PackIndex)

Returns:long

size of the object, -1 if not found in the index.

getThresholdback to summary
public int getThreshold()

Minimal size of an object to be included in this index Cut-off value used at generation time to decide what objects to index.

Returns:int

size in bytes