public interface LoadPlan
LoadPlan.Disposition.ENTITY_LOADER
- An entity load plan for
handling get/load handling. This form will typically have a single return (of type EntityReturn
)
defined by getReturns()
, possibly defining fetches.
LoadPlan.Disposition.COLLECTION_INITIALIZER
- A collection initializer,
used to load the contents of a collection. This form will typically have a single return (of
type CollectionReturn
) defined by getReturns()
, possibly defining fetches
LoadPlan.Disposition.MIXED
- A query load plan which can contain
multiple returns of mixed type (though all implementing Return
). Again, may possibly define fetches.
Modifier and Type | Interface and Description |
---|---|
static class |
LoadPlan.Disposition
Enumerated possibilities for describing the disposition of this LoadPlan.
|
Modifier and Type | Method and Description |
---|---|
boolean |
areLazyAttributesForceFetched()
Does this load plan indicate that lazy attributes are to be force fetched?
Here we are talking about laziness in regards to the legacy bytecode enhancement which adds support for
partial selects of an entity's state (e.g., skip loading a lob initially, wait until/if it is needed)
This one would effect the SQL that needs to get generated as well as how the result set would be read.
|
LoadPlan.Disposition |
getDisposition()
What is the disposition of this LoadPlan, in terms of its returns.
|
QuerySpaces |
getQuerySpaces()
Gets the
QuerySpaces for the load plan, which contains a QuerySpace
reference for each non-scalar return and for each entity, collection, and composite
FetchSource . |
List<? extends Return> |
getReturns()
Get the returns indicated by this LoadPlan.
A
LoadPlan.Disposition.ENTITY_LOADER LoadPlan would have just a single Return of type EntityReturn . |
boolean |
hasAnyScalarReturns()
Convenient form of checking
getReturns() for scalar root returns. |
LoadPlan.Disposition getDisposition()
List<? extends Return> getReturns()
LoadPlan.Disposition.ENTITY_LOADER
LoadPlan would have just a single Return of type EntityReturn
.
LoadPlan.Disposition.COLLECTION_INITIALIZER
LoadPlan would have just a single Return of type
CollectionReturn
.
LoadPlan.Disposition.MIXED
LoadPlan would contain a mix of EntityReturn
and
ScalarReturn
elements, but no CollectionReturn
.
LoadPlan.Disposition
QuerySpaces getQuerySpaces()
QuerySpaces
for the load plan, which contains a QuerySpace
reference for each non-scalar return and for each entity, collection, and composite
FetchSource
.
When generating SQL, the query spaces provide data for the "from clause" including joins.boolean areLazyAttributesForceFetched()
FETCH ALL PROPERTIES
key-phrase. In all other cases, this returns false.boolean hasAnyScalarReturns()
getReturns()
for scalar root returns.true
if getReturns()
contained any scalar returns; false
otherwise.Copyright © 2021 JBoss by Red Hat. All rights reserved.