Package org.hibernate.reactive.query.spi
Class ReactiveAbstractSelectionQuery<R>
- java.lang.Object
-
- org.hibernate.reactive.query.spi.ReactiveAbstractSelectionQuery<R>
-
- Type Parameters:
R
-
public class ReactiveAbstractSelectionQuery<R> extends Object
EmulateAbstractSelectionQuery
.Hibernate Reactive implementations already extend another class, they cannot extends
too
. This approach allows us to avoid duplicating code.
-
-
Constructor Summary
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DomainParameterXref
getDomainParameterXref()
String
getQueryString()
CompletionStage<R>
getReactiveSingleResult()
CompletionStage<R>
getReactiveSingleResultOrNull()
List<R>
getResultList()
Stream<R>
getResultStream()
Class<R>
getResultType()
R
getSingleResult()
R
getSingleResultOrNull()
SqmStatement<?>
getSqmStatement()
TupleMetadata
getTupleMetadata()
List<R>
list()
CompletionStage<List<R>>
reactiveList()
CompletionStage<R>
reactiveUnique()
CompletionStage<Optional<R>>
reactiveUniqueResultOptional()
ReactiveSelectQueryPlan<R>
resolveSelectReactiveQueryPlan()
R
uniqueResult()
Optional<R>
uniqueResultOptional()
-
-
-
Constructor Detail
-
ReactiveAbstractSelectionQuery
public ReactiveAbstractSelectionQuery(SqmInterpretationsKey.InterpretationsKeySource interpretationKeySource, SharedSessionContractImplementor session, Supplier<CompletionStage<List<R>>> doList, Supplier<SqmStatement<?>> getStatement, Supplier<TupleMetadata> getTupleMetadata, Supplier<DomainParameterXref> getDomainParameterXref, Supplier<Class<R>> getResultType, Supplier<String> getQueryString, Runnable beforeQuery, Consumer<Boolean> afterQuery, Function<List<R>,R> uniqueElement)
-
ReactiveAbstractSelectionQuery
public ReactiveAbstractSelectionQuery(Supplier<QueryOptions> queryOptionsSupplier, SharedSessionContractImplementor session, Supplier<CompletionStage<List<R>>> doList, Supplier<SqmStatement<?>> getStatement, Supplier<TupleMetadata> getTupleMetadata, Supplier<DomainParameterXref> getDomainParameterXref, Supplier<Class<R>> getResultType, Supplier<String> getQueryString, Runnable beforeQuery, Consumer<Boolean> afterQuery, Function<List<R>,R> uniqueElement, SqmInterpretationsKey.InterpretationsKeySource interpretationsKeySource)
-
-
Method Detail
-
reactiveUnique
public CompletionStage<R> reactiveUnique()
-
reactiveUniqueResultOptional
public CompletionStage<Optional<R>> reactiveUniqueResultOptional()
-
getReactiveSingleResult
public CompletionStage<R> getReactiveSingleResult()
-
getReactiveSingleResultOrNull
public CompletionStage<R> getReactiveSingleResultOrNull()
-
reactiveList
public CompletionStage<List<R>> reactiveList()
-
resolveSelectReactiveQueryPlan
public ReactiveSelectQueryPlan<R> resolveSelectReactiveQueryPlan()
-
getSqmStatement
public SqmStatement<?> getSqmStatement()
-
getTupleMetadata
public TupleMetadata getTupleMetadata()
-
getDomainParameterXref
public DomainParameterXref getDomainParameterXref()
-
getQueryString
public String getQueryString()
-
getSingleResult
public R getSingleResult()
-
getSingleResultOrNull
public R getSingleResultOrNull()
-
uniqueResult
public R uniqueResult()
-
-