org.vivoweb.harvester.score.algorithm
Interface Algorithm

All Known Implementing Classes:
CaseInsensitiveInitialTest, EqualityTest, NormalizedDamerauLevenshteinDifference, NormalizedDoubleMetaphoneDifference, NormalizedLevenshteinDifference, NormalizedSoundExDifference, NormalizedTypoDifference

public interface Algorithm

Interface for Score algorithms Using this standardized interface allows any custom algorithms to be added easily

Author:
Nicholas Skaggs nskaggs@ctrip.ufl.edu, Stephen Williams svwilliams@ctrip.ufl.edu, Christopher Haines hainesc@ctrip.ufl.edu

Method Summary
 float calculate(java.lang.CharSequence itemX, java.lang.CharSequence itemY)
          Perform a calculation to determine what percent match the given Strings are
 

Method Detail

calculate

float calculate(java.lang.CharSequence itemX,
                java.lang.CharSequence itemY)
Perform a calculation to determine what percent match the given Strings are

Parameters:
itemX - compare this with the other String
itemY - compare this with the other String
Returns:
a float (0.0, 1.0) representing what percent match the given Strings are