Search in sources :

Example 1 with EntityRowMapper

use of org.springframework.data.jdbc.core.EntityRowMapper in project spring-data-jdbc by spring-projects.

the class JdbcQueryLookupStrategy method determineDefaultRowMapper.

private RowMapper<?> determineDefaultRowMapper(JdbcQueryMethod queryMethod) {
    Class<?> domainType = queryMethod.getReturnedObjectType();
    RowMapper typeMappedRowMapper = rowMapperMap.rowMapperFor(domainType);
    return // 
    typeMappedRowMapper == null ? new // 
    EntityRowMapper<>(// 
    context.getRequiredPersistentEntity(domainType), // 
    context, // 
    accessStrategy) : typeMappedRowMapper;
}
Also used : EntityRowMapper(org.springframework.data.jdbc.core.EntityRowMapper) SingleColumnRowMapper(org.springframework.jdbc.core.SingleColumnRowMapper) RowMapper(org.springframework.jdbc.core.RowMapper)

Aggregations

EntityRowMapper (org.springframework.data.jdbc.core.EntityRowMapper)1 RowMapper (org.springframework.jdbc.core.RowMapper)1 SingleColumnRowMapper (org.springframework.jdbc.core.SingleColumnRowMapper)1