class FeatureBasedSimilarity extends AbstractStringMetric {

    @Override
    public double getSimilarity(String s1, String s2) {
        Validate.notNull(s1, "s1 must not be null");
        Validate.notNull(s2, "s2 must not be null");
        if (s1.equals(s2)) {
            return 1;
        }
        Set<String> features1 = extractFeatures(s1);
        Set<String> features2 = extractFeatures(s2);
        return setSimilarity.getSimilarity(features1, features2);
    }

    public  FeatureBasedSimilarity(FeatureSetting featureSetting, SetSimilarity setSimilarity);

}