Interface CollectionName
public interface CollectionName
Abstraction to determine the collection name for a given entity class. The collection name can be either derived from
an entity or can be a simple string.
- Since:
- 5.1
- Author:
- Mark Paluch
-
Method Summary
Modifier and TypeMethodDescriptionstatic CollectionNameCreate a newCollectionNamethat shall be derived from the givenentityClass.Returns the collection name.getCollectionName(Function<Class<?>, @Nullable MongoPersistentEntity<?>> entityLookup) Returns the collection name, potentially by considering aMongoPersistentEntity.Class<?> Returns the entity class for which the collection name is derived.static CollectionNameCreate a newCollectionNamefor the givencollectionName.
-
Method Details
-
getCollectionName
String getCollectionName()Returns the collection name. -
getCollectionName
Returns the collection name, potentially by considering aMongoPersistentEntity. -
getEntityClass
Class<?> getEntityClass()Returns the entity class for which the collection name is derived. -
just
Create a newCollectionNamefor the givencollectionName. -
from
Create a newCollectionNamethat shall be derived from the givenentityClass.
-