Interface ElasticsearchPersistentEntity<T>
- All Superinterfaces:
Iterable<ElasticsearchPersistentProperty>
,PersistentEntity<T,
ElasticsearchPersistentProperty>
- All Known Implementing Classes:
SimpleElasticsearchPersistentEntity
public interface ElasticsearchPersistentEntity<T>
extends PersistentEntity<T,ElasticsearchPersistentProperty>
ElasticsearchPersistentEntity
- Author:
- Rizwan Idrees, Mohsin Husen, Mark Paluch, Sascha Woo, Oliver Gierke, Ivan Greene, Peter-Josef Meisch, Roman Puchkovskiy, Subhobrata Dey
-
Method Summary
Modifier and TypeMethodDescriptiondynamic()
returns the default settings for an index.Returns theJoinField
property of theElasticsearchPersistentEntity
.getPersistentPropertyWithFieldName
(String fieldName) returns theElasticsearchPersistentProperty
with the given fieldName (may be set by theField
annotation.short
default ElasticsearchPersistentProperty
Returns theSeqNoPrimaryTerm
property of theElasticsearchPersistentEntity
or throws an IllegalStateException in case no such property is available on the entity.Returns theSeqNoPrimaryTerm
property of theElasticsearchPersistentEntity
.short
boolean
Returns whether theElasticsearchPersistentEntity
has aJoinField
property.boolean
Returns whether theElasticsearchPersistentEntity
has aSeqNoPrimaryTerm
property.boolean
boolean
resolveRouting
(T bean) Resolves the routing for a bean.boolean
boolean
boolean
Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
Methods inherited from interface org.springframework.data.mapping.PersistentEntity
doWithAll, doWithAssociations, doWithAssociations, doWithProperties, doWithProperties, findAnnotation, getIdentifierAccessor, getIdProperty, getInstanceCreatorMetadata, getName, getPersistenceConstructor, getPersistentProperties, getPersistentProperty, getPersistentProperty, getPropertyAccessor, getPropertyPathAccessor, getRequiredAnnotation, getRequiredIdProperty, getRequiredPersistentProperty, getRequiredVersionProperty, getType, getTypeAlias, getTypeInformation, hasIdProperty, hasVersionProperty, isAnnotationPresent, isConstructorArgument, isCreatorArgument, isIdProperty, isImmutable, isNew, isVersionProperty, requiresPropertyPopulation
-
Method Details
-
getIndexCoordinates
IndexCoordinates getIndexCoordinates() -
getShards
short getShards() -
getReplicas
short getReplicas() -
isUseServerConfiguration
boolean isUseServerConfiguration() -
getRefreshInterval
-
getIndexStoreType
-
getVersionProperty
ElasticsearchPersistentProperty getVersionProperty()- Specified by:
getVersionProperty
in interfacePersistentEntity<T,
ElasticsearchPersistentProperty>
-
settingPath
-
getVersionType
-
isCreateIndexAndMapping
boolean isCreateIndexAndMapping() -
getPersistentPropertyWithFieldName
returns theElasticsearchPersistentProperty
with the given fieldName (may be set by theField
annotation.- Parameters:
fieldName
- to field name for the search, must not be null- Returns:
- the found property, otherwise null
- Since:
- 4.0
-
hasSeqNoPrimaryTermProperty
boolean hasSeqNoPrimaryTermProperty()Returns whether theElasticsearchPersistentEntity
has aSeqNoPrimaryTerm
property. If this call returns true,getSeqNoPrimaryTermProperty()
will return a non-null value.- Returns:
- false when
ElasticsearchPersistentEntity
does not define a SeqNoPrimaryTerm property. - Since:
- 4.0
-
hasJoinFieldProperty
boolean hasJoinFieldProperty()Returns whether theElasticsearchPersistentEntity
has aJoinField
property. If this call returns true,getJoinFieldProperty()
will return a non-null value.- Returns:
- false when
ElasticsearchPersistentEntity
does not define a JoinField property. - Since:
- 4.1
-
getSeqNoPrimaryTermProperty
Returns theSeqNoPrimaryTerm
property of theElasticsearchPersistentEntity
. Can be null in case no such property is available on the entity.- Returns:
- the
SeqNoPrimaryTerm
ElasticsearchPersistentProperty
of thePersistentEntity
or null if not defined. - Since:
- 4.0
-
getJoinFieldProperty
Returns theJoinField
property of theElasticsearchPersistentEntity
. Can be null in case no such property is available on the entity.- Returns:
- the
JoinField
ElasticsearchPersistentProperty
of thePersistentEntity
or null if not defined. - Since:
- 4.1
-
getRequiredSeqNoPrimaryTermProperty
Returns theSeqNoPrimaryTerm
property of theElasticsearchPersistentEntity
or throws an IllegalStateException in case no such property is available on the entity.- Returns:
- the
SeqNoPrimaryTerm
ElasticsearchPersistentProperty
of thePersistentEntity
. - Since:
- 4.0
-
getIndexedIndexNameProperty
- Returns:
- the property annotated with
IndexedIndexName
if it exists, otherwise null - Since:
- 5.1
-
getDefaultSettings
Settings getDefaultSettings()returns the default settings for an index.- Returns:
- settings
- Since:
- 4.1
-
resolveRouting
Resolves the routing for a bean.- Parameters:
bean
- the bean to resolve the routing for- Returns:
- routing value, may be null
-
getFieldNamingStrategy
FieldNamingStrategy getFieldNamingStrategy()- Returns:
- the
FieldNamingStrategy
for the entity - Since:
- 4.3
-
writeTypeHints
boolean writeTypeHints()- Returns:
- true if type hints on this entity should be written.
- Since:
- 4.3
-
dynamic
Dynamic dynamic()- Returns:
- the
dynamic
mapping parameter value. - Since:
- 4.3
-
storeIdInSource
boolean storeIdInSource()- Returns:
- the storeIdInSource value from the document annotation
- Since:
- 5.1
-
storeVersionInSource
boolean storeVersionInSource()- Returns:
- the storeVersionInSource value from the document annotation.
- Since:
- 5.1
-