Class EntityOperations
java.lang.Object
org.springframework.data.elasticsearch.core.EntityOperations
Common operations performed on an entity in the context of it's mapping metadata.
- Since:
- 3.2
- Author:
- Mark Paluch, Christoph Strobl, Peter-Josef Meisch, Roman Puchkovskiy
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
Information and commands on an entity. -
Constructor Summary
ConstructorDescriptionEntityOperations
(MappingContext<? extends ElasticsearchPersistentEntity<?>, ElasticsearchPersistentProperty> context) -
Method Summary
Modifier and TypeMethodDescriptionforEntity
(T entity, ConversionService conversionService, RoutingResolver routingResolver) Creates a newEntityOperations.AdaptableEntity
for the given bean andConversionService
andRoutingResolver
.
-
Constructor Details
-
EntityOperations
public EntityOperations(MappingContext<? extends ElasticsearchPersistentEntity<?>, ElasticsearchPersistentProperty> context)
-
-
Method Details
-
forEntity
public <T> EntityOperations.AdaptableEntity<T> forEntity(T entity, ConversionService conversionService, RoutingResolver routingResolver) Creates a newEntityOperations.AdaptableEntity
for the given bean andConversionService
andRoutingResolver
.- Parameters:
entity
- must not be null.conversionService
- must not be null.routingResolver
- theRoutingResolver
, must not be null- Returns:
- the
EntityOperations.AdaptableEntity
-