1
0
mirror of synced 2026-07-19 08:15:08 +00:00

DATAES-141 add new constructor to fix: Mapping Context is null in

DefaultResultMapper when using custom Entitymapper
This commit is contained in:
dmaass
2014-12-17 11:16:25 +01:00
parent f309046ab4
commit 2367d8908f
@@ -65,6 +65,13 @@ public class DefaultResultMapper extends AbstractResultMapper {
super(entityMapper); super(entityMapper);
} }
public DefaultResultMapper(
MappingContext<? extends ElasticsearchPersistentEntity<?>, ElasticsearchPersistentProperty> mappingContext,
EntityMapper entityMapper) {
super(entityMapper);
this.mappingContext = mappingContext;
}
@Override @Override
public <T> FacetedPage<T> mapResults(SearchResponse response, Class<T> clazz, Pageable pageable) { public <T> FacetedPage<T> mapResults(SearchResponse response, Class<T> clazz, Pageable pageable) {
long totalHits = response.getHits().totalHits(); long totalHits = response.getHits().totalHits();