Package com.atlassian.jira.search
Class DefaultScoreComputedFieldSort
java.lang.Object
com.atlassian.jira.search.DefaultScoreComputedFieldSort
- All Implemented Interfaces:
FieldSort,ScoreComputedFieldSort
@PublicApi
public class DefaultScoreComputedFieldSort
extends Object
implements ScoreComputedFieldSort
Default implementation of
ScoreComputedFieldSort.- Since:
- 10.4
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.atlassian.jira.search.FieldSort
FieldSort.Order -
Constructor Summary
ConstructorsConstructorDescriptionDefaultScoreComputedFieldSort(String field, FieldSort.Order order, Map<String, Long> valueToScore) DefaultScoreComputedFieldSort(String field, FieldSort.Order order, Map<String, Long> valueToScore, long defaultScore) DefaultScoreComputedFieldSort(String field, FieldSort.Order order, Map<String, Long> valueToScore, long defaultValue, Long missingValueScore) -
Method Summary
Modifier and TypeMethodDescriptionlongA default score value to use when a field value does not match an entry inScoreComputedFieldSort.valueToScore()booleanfield()inthashCode()Specifies a value to be used when a field has no assigned valueorder()reverse()toString()The values to be used to score the results
-
Constructor Details
-
DefaultScoreComputedFieldSort
public DefaultScoreComputedFieldSort(String field, FieldSort.Order order, Map<String, Long> valueToScore) -
DefaultScoreComputedFieldSort
public DefaultScoreComputedFieldSort(String field, FieldSort.Order order, Map<String, Long> valueToScore, long defaultScore) -
DefaultScoreComputedFieldSort
-
-
Method Details
-
field
-
defaultScore
public long defaultScore()Description copied from interface:ScoreComputedFieldSortA default score value to use when a field value does not match an entry inScoreComputedFieldSort.valueToScore()- Specified by:
defaultScorein interfaceScoreComputedFieldSort- Returns:
- default score
-
missingValueScore
Description copied from interface:ScoreComputedFieldSortSpecifies a value to be used when a field has no assigned value- Specified by:
missingValueScorein interfaceScoreComputedFieldSort- Returns:
- optional missing value score
-
valueToScore
Description copied from interface:ScoreComputedFieldSortThe values to be used to score the results- Specified by:
valueToScorein interfaceScoreComputedFieldSort- Returns:
- pre-computed field values
-
order
-
reverse
- Specified by:
reversein interfaceFieldSort- Specified by:
reversein interfaceScoreComputedFieldSort
-
equals
-
hashCode
public int hashCode() -
toString
-