Interface IMatchDefinitionDS
- All Superinterfaces:
IReportingDS
- All Known Implementing Classes:
ExtXmlMatchDefinitionDS
This interface defines the methods that are needed to initialise a match definition object for the match engine.
- Since:
- 6.2
- Author:
- F. van der Meer, O. Kerpershoek
-
Method Summary
Modifier and TypeMethodDescriptionThis method returns the name of the attribute ( excluding entity name ) to which this definition belongs to.Returns the id of the master attribute.This function returns the match function name this match definition uses.This method should return the requirement that should be met before a match can take place.This method should return the id of the multi value strategy that should be used to match list of values.int
The threshold percentage can be used to limit the number of cases that are valid.int
The unknown percentage is used when a certain value is requested, but there is no value offered.int
This method returns the weight of this match definition.boolean
This method determines the match direction of the attribute (if the attribute is matched that is).Methods inherited from interface com.aquima.interactions.foundation.report.IReportingDS
addMessage
-
Method Details
-
getAttributeName
String getAttributeName()This method returns the name of the attribute ( excluding entity name ) to which this definition belongs to.- Returns:
- The name of the attribute.
-
getWeight
int getWeight()This method returns the weight of this match definition. The value can range between 1 and 100 and the default value should be 1.- Returns:
- The weight of the match definition.
-
getMatchFunction
String getMatchFunction()This function returns the match function name this match definition uses.- Returns:
- The match function the definition will be using which is never null
-
matchReverse
boolean matchReverse()This method determines the match direction of the attribute (if the attribute is matched that is). Normally all the attributes are matched from the profile, that is the profile contains the requested value and the case the offered value. With a reverse match, the case contains the requested value, and the profile the offered value.
Note: Do not let yourself be fooled by the normBased method in the case base data source ! This method determines the match direction, no other method is used. Default when matching and match reverse is off a profile value acts as the demand-value and the case-value acts as the supply-value when match reverse has been enabled the demand-value and supply-value are switched.- Returns:
- The match direction of the attribute, false = profile -> case, true = case -> profile.
-
getStrategy
StrategyType getStrategy()This method should return the id of the multi value strategy that should be used to match list of values. This method will only be invoked when either the profile or the case contains multiple values. See theStrategyType
for possible values.- Returns:
- An id specifying the multi-value strategy.
-
getRequirement
RequirementType getRequirement()This method should return the requirement that should be met before a match can take place. The requirement object indicates which values should be present in order to be able to match the attribute. The possible values are:- profile The profile must have a value.
- case The case should have a value.
- both Both the profile and the case must have a value.
- either Either the profile or the case must have a value.
- Returns:
- An id specifying the requirements for a match.
-
getMasterAttributeName
String getMasterAttributeName()Returns the id of the master attribute. If no master attribute is present (which is very normal) a negative value should be returned. The master attribute is used only to calculate the score at the moment. The score of this attribute will be multiplied with the score (percentage) of the master attribute. As a result, the score of a child attribute will never be higher than the score of it's master. The master attribute should be present within the same attribute group.- Returns:
- An optional string representing the master attribute name; this can be null when there is no master.
-
getUnknownPercentage
int getUnknownPercentage()The unknown percentage is used when a certain value is requested, but there is no value offered. As the lack of a value can be interpreted differently for each attribute, this method can be used to steer the behaviour. Normally the lack of a value will be treated as a mismatch, but this percentage can change that even to a match. The value of 100 means the lack of a value is just as good as a complete match, whereas zero means that the lack of a value is a mismatch.- Returns:
- The percentage of the score that the attribute should get when no value is found.
-
getThresholdPercentage
int getThresholdPercentage()The threshold percentage can be used to limit the number of cases that are valid. Only cases that score above the threshold for this attribute will be allowed in the match result. An attribute threshold of 100 is equal to the required setting of the old match engine.- Returns:
- The minimum score this attribute should reach in order to be allowed in the match result.
-