Class SolrQueryMethod
java.lang.Object
org.springframework.data.repository.query.QueryMethod
org.springframework.data.solr.repository.query.SolrQueryMethod
public class SolrQueryMethod
extends org.springframework.data.repository.query.QueryMethod
Solr specific implementation of
QueryMethod taking care of Query-
Constructor Summary
ConstructorsConstructorDescriptionSolrQueryMethod(Method method, org.springframework.data.repository.core.RepositoryMetadata metadata, org.springframework.data.projection.ProjectionFactory factory, SolrEntityInformationCreator solrInformationCreator) -
Method Summary
Modifier and TypeMethodDescriptionprotected SolrParameterscreateParameters(Method method) booleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanMethods inherited from class org.springframework.data.repository.query.QueryMethod
createParameters, getDomainClass, getEntityInformation, getName, getResultProcessor, getReturnedObjectType, isCollectionQuery, isModifyingQuery, isPageQuery, isQueryForEntity, isScrollQuery, isSliceQuery, isStreamQuery, toString
-
Constructor Details
-
SolrQueryMethod
public SolrQueryMethod(Method method, org.springframework.data.repository.core.RepositoryMetadata metadata, org.springframework.data.projection.ProjectionFactory factory, SolrEntityInformationCreator solrInformationCreator)
-
-
Method Details
-
hasAnnotatedQuery
public boolean hasAnnotatedQuery()- Returns:
- true if
Query.value()is not blank
-
hasQueryAnnotation
public boolean hasQueryAnnotation()- Returns:
- true if
Queryis not blank
-
hasAnnotatedNamedQueryName
public boolean hasAnnotatedNamedQueryName()- Returns:
- true if
Query.name()is not blank
-
hasProjectionFields
public boolean hasProjectionFields()- Returns:
- true if
Query.fields()is not empty
-
getProjectionFields
- Returns:
- empty collection if
Query.fields()is empty
-
getTimeAllowed
- Returns:
- null if
Query.timeAllowed()is null or negative
-
isFacetQuery
public boolean isFacetQuery()- Returns:
- true if
hasFacetFields()orhasFacetQueries()
-
hasFacetFields
public boolean hasFacetFields()- Returns:
- true if
Facet.fields()is not empty
-
hasPivotFields
public boolean hasPivotFields()- Returns:
- true if is not empty
-
getFacetFields
- Returns:
- empty collection if
Facet.fields()is empty
-
getFacetQueries
- Returns:
- empty collection if
Facet.queries()is empty
-
getPivotFields
-
hasFacetQueries
public boolean hasFacetQueries()- Returns:
- true if
Facet.queries()is not empty
-
getFacetLimit
- Returns:
- value of
Facet.limit()
-
getFacetMinCount
- Returns:
- value of
Facet.minCount()
-
getFacetPrefix
- Returns:
- value of
Facet.prefix()
-
hasStatsDefinition
public boolean hasStatsDefinition()- Returns:
- if something was configured within
Stats - Since:
- 1.4
-
isFieldStatsCountDistinctEnable
public boolean isFieldStatsCountDistinctEnable()- Returns:
- true if stats is distinct
- Since:
- 1.4
-
getFieldStats
- Returns:
- value of
Stats.value() - Since:
- 1.4
-
getStatsFacets
- Returns:
- value of
Stats.facets() - Since:
- 1.4
-
getStatsSelectiveFacets
- Returns:
- value of facets used in
Stats.selective() - Since:
- 1.4
-
getStatsSelectiveCountDistinctFields
- Returns:
- value of facets used in
Stats.selective() - Since:
- 1.4
-
hasFilterQuery
public boolean hasFilterQuery()- Returns:
- true if
Query.filters()is not empty
-
isDeleteQuery
public boolean isDeleteQuery()- Returns:
- value of
Query.delete() - Since:
- 1.2
-
isHighlightQuery
public boolean isHighlightQuery()- Returns:
- if
Highlightis present
-
getHighlightFieldNames
- Returns:
- empty collection if
Highlight.fields()is empty
-
getHighlightQuery
- Returns:
- null if
Highlight.query()is blank
-
getHighlighSnipplets
- Returns:
- value of
Highlight.snipplets()or null if negative
-
getHighlightFragsize
- Returns:
- value of
Highlight.fragsize()or null if negative
-
getHighlightFormatter
- Returns:
- value of
Highlight.formatter()or null if blank
-
getHighlightPrefix
- Returns:
- value of
Highlight.prefix()or null if blank
-
getHighlightPostfix
- Returns:
- value of
Highlight.postfix()or null if blank
-
hasHighlightFields
public boolean hasHighlightFields()- Returns:
- true if
Highlight.fields()is not empty
-
getDefaultOperator
- Returns:
- value of
Query.defaultOperator()orQuery.Operator.NONEif not set
-
getDefType
- Returns:
- null if
Query.defType()not set
-
getRequestHandler
- Returns:
- null if
Query.requestHandler()not set
-
getSpellcheckAnnotation
- Returns:
- Since:
- 2.1
-
hasSpellcheck
public boolean hasSpellcheck()- Returns:
- Since:
- 2.1
-
getSpellcheckOptions
- Returns:
- Since:
- 2.1
-
getNamedQueryName
- Overrides:
getNamedQueryNamein classorg.springframework.data.repository.query.QueryMethod
-
returnsOptional
public boolean returnsOptional()- Returns:
- true if the method return type is
Optional. - Since:
- 2.0
-
createParameters
- Overrides:
createParametersin classorg.springframework.data.repository.query.QueryMethod
-
getParameters
- Overrides:
getParametersin classorg.springframework.data.repository.query.QueryMethod
-