org.eclipse.jgit.storage.dht
Class ChunkIndex

java.lang.Object
  extended by org.eclipse.jgit.storage.dht.ChunkIndex

public abstract class ChunkIndex
extends java.lang.Object

Index into a PackChunk.


Method Summary
 int getObjectCount()
          Get the total number of objects described by this index.
 ObjectId getObjectId(int nth)
          Get an ObjectId from this index.
 int getOffset(int nth)
          Get the offset of an object in the chunk.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getObjectCount

public final int getObjectCount()
Get the total number of objects described by this index.

Returns:
number of objects in this index and its associated chunk.

getObjectId

public final ObjectId getObjectId(int nth)
Get an ObjectId from this index.

Parameters:
nth - the object to return. Must be in range [0, getObjectCount).
Returns:
the object id.

getOffset

public final int getOffset(int nth)
Get the offset of an object in the chunk.

Parameters:
nth - offset to return. Must be in range [0, getObjectCount).
Returns:
the offset.


Copyright © 2011. All Rights Reserved.