Class UniqueMatcher

java.lang.Object
com.aquima.interactions.matching.impl.model.MultiValueMatcher
com.aquima.interactions.matching.impl.model.UniqueMatcher
All Implemented Interfaces:
IMatchFunction

public class UniqueMatcher extends MultiValueMatcher

Unique match strategy.
This multi value strategy calculates gets the best scoring mapping between the elements of the request value and the elements of the case value, such that each element in the case value is mapped to a unique element in the request value.

Currently, the request values and case values may have at most 3 elements. An InvalidStateException will be thrown, if a case value or request value contains more than 3 elements.

The Hungarian algorithm may be used to implement this matcher.

Copyright: Copyright (c) 2002

Company: Everest b.v.

Since:
6.5
Author:
M. Sloof
  • Constructor Details

  • Method Details

    • match

      public int match(IMatchValue vraag, IMatchValue aanbod)
      Description copied from interface: IMatchFunction
      This method should compare the demand value against the supply value and determine the match score.
      Parameters:
      vraag - The value that is demanded.
      aanbod - The value that is supplied.
      Returns:
      The match score for the supply and demand combination.