com.wcohen.secondstring
Class DistanceFactory

java.lang.Object
  |
  +--com.wcohen.secondstring.DistanceFactory

public class DistanceFactory
extends java.lang.Object

Creates distance metrics from string descriptions. String descriptions are of the form D1/D2/..Dk where D is either the class name of a StringDistance or a class name plus [param=xxx] where xxx is a double. For example,

SoftTFIDF[tokenMatchThreshold=0.9]/WinklerVariant/Jaro

builds the JaroWinklerSoftTFIDF class.


Constructor Summary
DistanceFactory()
           
 
Method Summary
static StringDistance build(java.lang.String classNames)
          Generate a StringDistance from a class name, or a sequence of classnames separated by slashes.
static StringDistance build(java.lang.String[] classNames)
          Generate a StringDistance from a sequence of classnames.
static void main(java.lang.String[] args)
          Test routine.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DistanceFactory

public DistanceFactory()
Method Detail

build

public static StringDistance build(java.lang.String classNames)
Generate a StringDistance from a class name, or a sequence of classnames separated by slashes.


build

public static StringDistance build(java.lang.String[] classNames)
Generate a StringDistance from a sequence of classnames.


main

public static void main(java.lang.String[] args)
Test routine.