Class RefTableTargetResolver<Q extends QReference<R,?>,R extends MReference,TQ extends QObject<TR>,TR extends MObject>
java.lang.Object
com.evolveum.midpoint.repo.sqale.mapping.RefTableTargetResolver<Q,R,TQ,TR>
- Type Parameters:
Q
- type of reference entity path (where the mapping is)R
- row type forRefTableTargetResolver
TQ
- type of target entity path, that is referenced objectTR
- row type related to the target entity pathRefTableTargetResolver
- All Implemented Interfaces:
ItemRelationResolver<Q,
R, TQ, TR>
public class RefTableTargetResolver<Q extends QReference<R,?>,R extends MReference,TQ extends QObject<TR>,TR extends MObject>
extends Object
implements ItemRelationResolver<Q,R,TQ,TR>
Resolver that knows how to traverse from reference table to the reference target.
The resolver uses mapping lazily via supplier to avoid call cycles during mapping initialization.
Ideal mapping type provided by the supplier is to be found in the schema inside
`<a:objectReferenceTargetType>` element for the reference, using more generic type means
Postgres has to search through more sub-tables than necessary and also doesn't provide
the right implicit type for further conditions on the target.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.evolveum.midpoint.repo.sqlbase.mapping.ItemRelationResolver
ItemRelationResolver.ResolutionResult<TQ extends FlexibleRelationalPathBase<TR>,
TR> -
Constructor Summary
ConstructorDescriptionRefTableTargetResolver
(@NotNull Supplier<QueryTableMapping<?, TQ, TR>> targetMappingSupplier) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.evolveum.midpoint.repo.sqlbase.mapping.ItemRelationResolver
resolve, resolveUsingJoin
-
Constructor Details
-
RefTableTargetResolver
public RefTableTargetResolver(@NotNull @NotNull Supplier<QueryTableMapping<?, TQ, TR>> targetMappingSupplier)
-
-
Method Details
-
resolve
public ItemRelationResolver.ResolutionResult<TQ,TR> resolve(SqlQueryContext<?, Q, R> context, boolean parent) - Specified by:
resolve
in interfaceItemRelationResolver<Q extends QReference<R,
?>, R extends MReference, TQ extends QObject<TR>, TR extends MObject>
-