Top Description Methods
org.eclipse.jgit.lib

public Interface AsyncObjectLoaderQueue<T extends ObjectId>

extends AsyncOperation
Type Parameters
<T>
type of identifier supplied to the call that made the queue.
Imports
java.io.IOException, org.eclipse.jgit.errors.MissingObjectException

Queue to open objects asynchronously. A queue may perform background decompression of objects and supply them (possibly out-of-order) to the application.

Method Summary

Modifier and TypeMethod and Description
public T

Returns:

the current object, null if the implementation lost track. Implementations may for performance reasons discard the caller's ObjectId and provider their own through getObjectId().
getCurrent
()

Get the current object, null if the implementation lost track.

public ObjectId

Returns:

the ObjectId of the current object. Never null.
getObjectId
()

Get the ObjectId of the current object.

public boolean

Returns:

true if there is a result available; false if the queue has finished its input iteration.
next
()

Position this queue onto the next available result.

public ObjectLoader

Returns:

the ObjectLoader to read this object. Never null.
open
()

Obtain a loader to read the object.

Inherited from org.eclipse.jgit.lib.AsyncOperation:
cancelrelease

Method Detail

getCurrentback to summary
public T getCurrent()

Get the current object, null if the implementation lost track.

Returns:T

the current object, null if the implementation lost track. Implementations may for performance reasons discard the caller's ObjectId and provider their own through getObjectId().

getObjectIdback to summary
public ObjectId getObjectId()

Get the ObjectId of the current object. Never null.

Returns:ObjectId

the ObjectId of the current object. Never null.

nextback to summary
public boolean next() throws MissingObjectException, IOException

Position this queue onto the next available result. Even if this method returns true, open() may still throw org.eclipse.jgit.errors.MissingObjectException if the underlying object database was concurrently modified and the current object is no longer available.

Returns:boolean

true if there is a result available; false if the queue has finished its input iteration.

Exceptions
MissingObjectException:
the object does not exist. If the implementation is retaining the application's objects getCurrent() will be the current object that is missing. There may be more results still available, so the caller should continue invoking next to examine another result.
IOException:
the object store cannot be accessed.
openback to summary
public ObjectLoader open() throws IOException

Obtain a loader to read the object. This method can only be invoked once per result Due to race conditions with a concurrent modification of the underlying object database, an object may be unavailable when this method is invoked, even though next returned successfully.

Returns:ObjectLoader

the ObjectLoader to read this object. Never null.

Exceptions
IOException:
the object store cannot be accessed.
MissingObjectException:
the object does not exist. If the implementation is retaining the application's objects getCurrent() will be the current object that is missing. There may be more results still available, so the caller should continue invoking next to examine another result.