public class: BatchFetchQueue
Tracks entity and collection keys that are available for batch
fetching, and the queries which were used to load entities, which
can be re-used as a subquery for loading owned collections.
|public static final Object ||MARKER || |
|Methods from java.lang.Object:|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait|
|Method from org.hibernate.engine.BatchFetchQueue Detail:|
public void addBatchLoadableEntityKey(EntityKey key)
If an EntityKey represents a batch loadable entity, add
it to the queue.
Note that the contract here is such that any key passed in should
previously have been been checked for existence within the
PersistenceContext ; failure to do so may cause the
referenced entity to be included in a batch even though it is
already associated with the PersistenceContext .
public void addSubselect(EntityKey key,
Adds a subselect fetch decriptor for the given entity key.
public void clear()
Clears all entries from this fetch queue.
public void clearSubselects()
Clears all pending subselect fetches from the queue.
Called after flushing.
public Serializable getCollectionBatch(CollectionPersister collectionPersister,
Get a batch of uninitialized collection keys for a given role
public Serializable getEntityBatch(EntityPersister persister,
Get a batch of unloaded identifiers for this class, using a slightly
complex algorithm that tries to grab keys registered immediately after
the given key.
public SubselectFetch getSubselect(EntityKey key)
Retrieve the fetch descriptor associated with the given entity key.
public void removeBatchLoadableEntityKey(EntityKey key)
After evicting or deleting or loading an entity, we don't
need to batch fetch it anymore, remove it from the queue
public void removeSubselect(EntityKey key)
After evicting or deleting an entity, we don't need to
know the query that was used to load it anymore (don't
call this after loading the entity, since we might still
need to load its collections)