public class MongoPersistentEntityIndexCreator extends Object implements ApplicationListener<org.springframework.data.mapping.context.MappingContextEvent<?,?>>
MongoPersistentEntity instances contained in the given MongoMappingContext
for indexing metadata and ensures the indexes to be available.| Constructor and Description |
|---|
MongoPersistentEntityIndexCreator(MongoMappingContext mappingContext,
IndexOperationsProvider indexOperationsProvider)
Creates a new
MongoPersistentEntityIndexCreator for the given MongoMappingContext and
MongoDatabaseFactory. |
MongoPersistentEntityIndexCreator(MongoMappingContext mappingContext,
IndexOperationsProvider indexOperationsProvider,
IndexResolver indexResolver)
Creates a new
MongoPersistentEntityIndexCreator for the given MongoMappingContext and
MongoDatabaseFactory. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
isIndexCreatorFor(org.springframework.data.mapping.context.MappingContext<?,?> context)
Returns whether the current index creator was registered for the given
MappingContext. |
void |
onApplicationEvent(org.springframework.data.mapping.context.MappingContextEvent<?,?> event) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforPayloadpublic MongoPersistentEntityIndexCreator(MongoMappingContext mappingContext, IndexOperationsProvider indexOperationsProvider)
MongoPersistentEntityIndexCreator for the given MongoMappingContext and
MongoDatabaseFactory.mappingContext - must not be null.indexOperationsProvider - must not be null.public MongoPersistentEntityIndexCreator(MongoMappingContext mappingContext, IndexOperationsProvider indexOperationsProvider, IndexResolver indexResolver)
MongoPersistentEntityIndexCreator for the given MongoMappingContext and
MongoDatabaseFactory.mappingContext - must not be null.indexOperationsProvider - must not be null.indexResolver - must not be null.public void onApplicationEvent(org.springframework.data.mapping.context.MappingContextEvent<?,?> event)
onApplicationEvent in interface ApplicationListener<org.springframework.data.mapping.context.MappingContextEvent<?,?>>public boolean isIndexCreatorFor(org.springframework.data.mapping.context.MappingContext<?,?> context)
MappingContext.context - Copyright © 2011–2023 Pivotal Software, Inc.. All rights reserved.