Class DefaultSqlStoredQuery<E,R>
- java.lang.Object
-
- io.micronaut.data.runtime.operations.internal.query.DefaultBindableParametersStoredQuery<E,R>
-
- io.micronaut.data.runtime.operations.internal.sql.DefaultSqlStoredQuery<E,R>
-
- Type Parameters:
E
- The entity typeR
- The result type
- All Implemented Interfaces:
io.micronaut.core.annotation.AnnotationMetadataProvider
,io.micronaut.core.annotation.AnnotationSource
,io.micronaut.core.naming.Named
,StoredDataOperation<R>
,StoredQuery<E,R>
,BindableParametersStoredQuery<E,R>
,PersistentEntityAwareQuery<E>
,SqlStoredQuery<E,R>
,DelegateStoredQuery<E,R>
@Internal public class DefaultSqlStoredQuery<E,R> extends DefaultBindableParametersStoredQuery<E,R> implements SqlStoredQuery<E,R>
Implementation ofSqlStoredQuery
.- Since:
- 3.5.0
- Author:
- Denis Stepanov
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface io.micronaut.data.runtime.operations.internal.query.BindableParametersStoredQuery
BindableParametersStoredQuery.Binder
-
-
Constructor Summary
Constructors Constructor Description DefaultSqlStoredQuery(StoredQuery<E,R> storedQuery, RuntimePersistentEntity<E> runtimePersistentEntity, SqlQueryBuilder queryBuilder)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Map<QueryParameterBinding,java.lang.Object>
collectAutoPopulatedPreviousValues(E entity)
Collect auto-populated property values before pre-actions are triggered and property values are modified.Dialect
getDialect()
Get dialect.SqlQueryBuilder
getQueryBuilder()
boolean
isExpandableQuery()
-
Methods inherited from class io.micronaut.data.runtime.operations.internal.query.DefaultBindableParametersStoredQuery
bindParameter, bindParameters, getPersistentEntity, getRequiredPropertyPath, getStoredQueryDelegate, requireInvocationContext
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.micronaut.core.annotation.AnnotationMetadataProvider
findAnnotation, findAnnotation, findDeclaredAnnotation, findDeclaredAnnotation, isAnnotationPresent, isDeclaredAnnotationPresent, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByType
-
Methods inherited from interface io.micronaut.core.annotation.AnnotationSource
getAnnotation, getAnnotation, getDeclaredAnnotation, getDeclaredAnnotation, isAnnotationPresent, isDeclaredAnnotationPresent, synthesize, synthesizeDeclared
-
Methods inherited from interface io.micronaut.data.runtime.operations.internal.query.BindableParametersStoredQuery
bindParameters
-
Methods inherited from interface io.micronaut.data.runtime.query.internal.DelegateStoredQuery
getAnnotationMetadata, getArgumentTypes, getEntityIdentifierType, getExpandableQueryParts, getIndexedParameterAutoPopulatedPreviousPropertyIndexes, getIndexedParameterAutoPopulatedPreviousPropertyPaths, getIndexedParameterAutoPopulatedPropertyPaths, getJoinFetchPaths, getName, getQuery, getQueryBindings, getQueryHints, getResultArgument, getResultDataType, getResultType, getRootEntity, getTransactionDefinition, hasInExpression, hasPageable, hasResultConsumer, isCount, isDtoProjection, isNative, isOptimisticLock, isRawQuery, isSingleResult, useNumericPlaceholders
-
Methods inherited from interface io.micronaut.data.runtime.operations.internal.query.PersistentEntityAwareQuery
getPersistentEntity
-
Methods inherited from interface io.micronaut.data.model.runtime.StoredQuery
getIndexedParameterBinding, getIndexedParameterPaths, getIndexedParameterTypes, getLastUpdatedProperty, getParameterBinding, getParameterNames
-
-
-
-
Constructor Detail
-
DefaultSqlStoredQuery
public DefaultSqlStoredQuery(StoredQuery<E,R> storedQuery, RuntimePersistentEntity<E> runtimePersistentEntity, SqlQueryBuilder queryBuilder)
- Parameters:
storedQuery
- The stored queryruntimePersistentEntity
- The persistent entityqueryBuilder
- The query builder
-
-
Method Detail
-
isExpandableQuery
public boolean isExpandableQuery()
- Specified by:
isExpandableQuery
in interfaceSqlStoredQuery<E,R>
- Returns:
- true if query is expandable
-
getDialect
public Dialect getDialect()
Description copied from interface:SqlStoredQuery
Get dialect.- Specified by:
getDialect
in interfaceSqlStoredQuery<E,R>
- Returns:
- dialect
-
getQueryBuilder
public SqlQueryBuilder getQueryBuilder()
- Specified by:
getQueryBuilder
in interfaceSqlStoredQuery<E,R>
- Returns:
- query builder for possible modification in the prepared query
-
collectAutoPopulatedPreviousValues
public java.util.Map<QueryParameterBinding,java.lang.Object> collectAutoPopulatedPreviousValues(E entity)
Description copied from interface:SqlStoredQuery
Collect auto-populated property values before pre-actions are triggered and property values are modified.- Specified by:
collectAutoPopulatedPreviousValues
in interfaceSqlStoredQuery<E,R>
- Parameters:
entity
- The entity instance- Returns:
- collected values
-
-