Package de.cxp.ocs.config
Class ScoringConfiguration.ScoringFunction
java.lang.Object
de.cxp.ocs.config.ScoringConfiguration.ScoringFunction
- Enclosing class:
ScoringConfiguration
Specific configuration for each scoring rule.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionData field that should be used for that scoring rule.setOptions
(Map<ScoreOption, String> options) Set additional options required for the according scoring type.Set how scoring works for that field.setWeight
(float weight) Set the weight that is multiplied with the scoring function result.
-
Constructor Details
-
ScoringFunction
public ScoringFunction()
-
-
Method Details
-
setField
Data field that should be used for that scoring rule.- Parameters:
field
- field name- Returns:
- self
-
setType
Set how scoring works for that field.- Parameters:
type
- type- Returns:
- self
-
setWeight
Set the weight that is multiplied with the scoring function result.- Parameters:
weight
- value > 0- Returns:
- self
-
setOptions
Set additional options required for the according scoring type.- Parameters:
options
- score options- Returns:
- self
-