Search in sources :

Example 1 with ReactiveEntityLoader

use of org.hibernate.reactive.loader.entity.impl.ReactiveEntityLoader in project hibernate-reactive by hibernate.

the class ReactiveAbstractEntityPersister method createReactiveUniqueKeyLoader.

default UniqueEntityLoader createReactiveUniqueKeyLoader(Type uniqueKeyType, String[] columns, LoadQueryInfluencers loadQueryInfluencers) {
    if (uniqueKeyType.isEntityType()) {
        String className = ((EntityType) uniqueKeyType).getAssociatedEntityName();
        uniqueKeyType = getFactory().getMetamodel().entityPersister(className).getIdentifierType();
    }
    return new ReactiveEntityLoader(this, columns, uniqueKeyType, 1, LockMode.NONE, getFactory(), loadQueryInfluencers);
}
Also used : EntityType(org.hibernate.type.EntityType) ReactiveEntityLoader(org.hibernate.reactive.loader.entity.impl.ReactiveEntityLoader) MessageHelper.infoString(org.hibernate.pretty.MessageHelper.infoString)

Aggregations

MessageHelper.infoString (org.hibernate.pretty.MessageHelper.infoString)1 ReactiveEntityLoader (org.hibernate.reactive.loader.entity.impl.ReactiveEntityLoader)1 EntityType (org.hibernate.type.EntityType)1