Class AbstractR2dbcQuery
java.lang.Object
org.springframework.data.r2dbc.repository.query.AbstractR2dbcQuery
- All Implemented Interfaces:
RepositoryQuery
- Direct Known Subclasses:
PartTreeR2dbcQuery
,StringBasedR2dbcQuery
Base class for reactive
RepositoryQuery
implementations for R2DBC.- Author:
- Mark Paluch, Stephen Cohen, Christoph Strobl
-
Constructor Summary
ConstructorsConstructorDescriptionAbstractR2dbcQuery
(R2dbcQueryMethod method, R2dbcEntityOperations entityOperations, R2dbcConverter converter) -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract reactor.core.publisher.Mono<PreparedOperation<?>>
createQuery
(org.springframework.data.relational.repository.query.RelationalParameterAccessor accessor) Creates aBindableQuery
instance using the givenParameterAccessor
protected abstract boolean
Returns whether the query should get a count projection applied.protected abstract boolean
Returns whether the query should get an exists projection applied.protected abstract boolean
Returns whether this query is a modifying one.
-
Constructor Details
-
AbstractR2dbcQuery
public AbstractR2dbcQuery(R2dbcQueryMethod method, R2dbcEntityOperations entityOperations, R2dbcConverter converter) - Parameters:
method
- must not be null.entityOperations
- must not be null.converter
- must not be null.- Since:
- 1.4
-
-
Method Details
-
getQueryMethod
- Specified by:
getQueryMethod
in interfaceRepositoryQuery
-
execute
- Specified by:
execute
in interfaceRepositoryQuery
-
isModifyingQuery
protected abstract boolean isModifyingQuery()Returns whether this query is a modifying one.- Returns:
- Since:
- 1.1
-
isCountQuery
protected abstract boolean isCountQuery()Returns whether the query should get a count projection applied.- Returns:
- Since:
- 1.2
-
isExistsQuery
protected abstract boolean isExistsQuery()Returns whether the query should get an exists projection applied.- Returns:
- Since:
- 1.2
-
createQuery
protected abstract reactor.core.publisher.Mono<PreparedOperation<?>> createQuery(org.springframework.data.relational.repository.query.RelationalParameterAccessor accessor) Creates aBindableQuery
instance using the givenParameterAccessor
- Parameters:
accessor
- must not be null.- Returns:
- a mono emitting a
BindableQuery
.
-