Package org.hibernate.loader.plan.spi
Interface CollectionReference
-
- All Known Subinterfaces:
CollectionAttributeFetch
,CollectionReturn
public interface CollectionReference
Represents a reference to a persistent collection either as a Return or as aCollectionAttributeFetch
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
allowElementJoin()
Should a collection element join be allowed? Returningtrue
indicates that an element join can safely be added.boolean
allowIndexJoin()
Should a collection index join be allowed? Returningtrue
indicates that an index join can safely be added.CollectionPersister
getCollectionPersister()
Retrieves the CollectionPersister describing the collection associated with this CollectionReference.CollectionFetchableElement
getElementGraph()
Retrieve the metadata about the elements of this collection *as a FetchSource*.CollectionFetchableIndex
getIndexGraph()
Retrieve the metadata about the index of this collection *as a FetchSource*.PropertyPath
getPropertyPath()
Retrieve the PropertyPath to this reference.java.lang.String
getQuerySpaceUid()
Obtain the UID of the QuerySpace (specifically aCollectionQuerySpace
) that this CollectionReference refers to.
-
-
-
Method Detail
-
getQuerySpaceUid
java.lang.String getQuerySpaceUid()
Obtain the UID of the QuerySpace (specifically aCollectionQuerySpace
) that this CollectionReference refers to.- Returns:
- The UID
-
getCollectionPersister
CollectionPersister getCollectionPersister()
Retrieves the CollectionPersister describing the collection associated with this CollectionReference.- Returns:
- The CollectionPersister.
-
getIndexGraph
CollectionFetchableIndex getIndexGraph()
Retrieve the metadata about the index of this collection *as a FetchSource*. Will returnnull
when:- the collection is not indexed
- the index is not a composite, entity, or "any" (cannot act as a FetchSource)
- Returns:
- The collection index metadata as a FetchSource, or
null
.
-
getElementGraph
CollectionFetchableElement getElementGraph()
Retrieve the metadata about the elements of this collection *as a FetchSource*. Will returnnull
when the element is not a composite, entity, or "any" (cannot act as a FetchSource). Works only for map keys, since a List index cannot be anything other than an int which cannot be a FetchSource.- Returns:
- The collection element metadata as a FetchSource, or
null
.
-
getPropertyPath
PropertyPath getPropertyPath()
Retrieve the PropertyPath to this reference.- Returns:
- The PropertyPath
-
allowElementJoin
boolean allowElementJoin()
Should a collection element join be allowed? Returningtrue
indicates that an element join can safely be added.- Returns:
- true, if a collection index join is allowed.
-
allowIndexJoin
boolean allowIndexJoin()
Should a collection index join be allowed? Returningtrue
indicates that an index join can safely be added.- Returns:
- true, if a collection index join is allowed.
-
-