public class ConnectedMoreLikeThisContext extends Object implements MoreLikeThisContext
| Constructor and Description |
|---|
ConnectedMoreLikeThisContext(QueryBuildingContext context) |
| Modifier and Type | Method and Description |
|---|---|
MoreLikeThisContext |
boostedTo(float boost)
Boost the query to a given value
Most of the time positive float:
- lower than 1 to diminish the weight
- higher than 1 to increase the weight
Could be negative but not unless you understand what is going on (advanced)
|
MoreLikeThisTerminalMatchingContext |
comparingAllFields()
Match the content using "all" of the indexed fields of the entity.
|
MoreLikeThisOpenedMatchingContext |
comparingField(String fieldName)
Match the content using the selected field of the entity.
|
MoreLikeThisOpenedMatchingContext |
comparingFields(String... fieldNames)
Match the content using the selected fields of the entity.
|
MoreLikeThisContext |
excludeEntityUsedForComparison()
Exclude the entity used for comparison from the results
|
MoreLikeThisContext |
favorSignificantTermsWithFactor(float factor)
Boost significant terms relative to their scores.
|
MoreLikeThisContext |
filteredBy(Filter filter)
Filter the query results with the Filter instance
|
MoreLikeThisContext |
withConstantScore()
All results matching the query have a constant score equals to the boost
FIXME is that true?
|
public ConnectedMoreLikeThisContext(QueryBuildingContext context)
public MoreLikeThisContext excludeEntityUsedForComparison()
MoreLikeThisContextexcludeEntityUsedForComparison in interface MoreLikeThisContextthis for method chainingpublic MoreLikeThisContext favorSignificantTermsWithFactor(float factor)
MoreLikeThisContextfavorSignificantTermsWithFactor in interface MoreLikeThisContextfactor - the factor valuethis for method chainingpublic MoreLikeThisTerminalMatchingContext comparingAllFields()
MoreLikeThisContextcomparingAllFields in interface MoreLikeThisContextthis for method chainingpublic MoreLikeThisOpenedMatchingContext comparingFields(String... fieldNames)
MoreLikeThisContextcomparingFields in interface MoreLikeThisContextfieldNames - the names of the fields to use for the comparisonthis for method chainingpublic MoreLikeThisOpenedMatchingContext comparingField(String fieldName)
MoreLikeThisContextcomparingField in interface MoreLikeThisContextfieldName - the name of the field to comparethis for method chainingpublic MoreLikeThisContext boostedTo(float boost)
QueryCustomizationboostedTo in interface QueryCustomization<MoreLikeThisContext>boost - the value to use as boostpublic MoreLikeThisContext withConstantScore()
QueryCustomizationwithConstantScore in interface QueryCustomization<MoreLikeThisContext>public MoreLikeThisContext filteredBy(Filter filter)
QueryCustomizationfilteredBy in interface QueryCustomization<MoreLikeThisContext>filter - the filter to useCopyright © 2006-2017 Red Hat, Inc. All Rights Reserved