public interface ResultsMapper extends SearchResultMapper, GetResultMapper, MultiGetResultMapper
Modifier and Type | Method and Description |
---|---|
EntityMapper |
getEntityMapper() |
default ProjectionFactory |
getProjectionFactory()
Get the configured
ProjectionFactory . |
default <T> T |
mapEntity(String source,
Class<T> clazz) |
default <T> T |
mapGetResult(org.elasticsearch.index.get.GetResult getResult,
Class<T> type)
Map a single
GetResult to an instance of the given type. |
default <T> T |
mapSearchHit(org.elasticsearch.search.SearchHit searchHit,
Class<T> type)
Map a single
SearchHit to an instance of the given type. |
mapResults
mapResult
mapResults
EntityMapper getEntityMapper()
default ProjectionFactory getProjectionFactory()
ProjectionFactory
. @Nullable default <T> T mapGetResult(org.elasticsearch.index.get.GetResult getResult, Class<T> type)
GetResult
to an instance of the given type.mapGetResult
in interface GetResultMapper
T
- getResult
- must not be null.type
- must not be null.is empty
.@Nullable default <T> T mapSearchHit(org.elasticsearch.search.SearchHit searchHit, Class<T> type)
SearchHit
to an instance of the given type.mapSearchHit
in interface SearchResultMapper
T
- searchHit
- must not be null.type
- must not be null.SearchHit
does not have a source
.Copyright © 2011–2020 Pivotal Software, Inc.. All rights reserved.