@Test public void testScoreIsProperlyComputedWithCustomLanguageTag() { double score = SorensenDiceCoefficient.compute("çok ağrıyor", "az bilmiyor", "tr-TR"); int text1PairCount = countOf("ço","ok") + countOf("ağ","ğr","rı","ıy", "yo","or"); int text2PairCount = countOf("az") + countOf("bi","il","lm","mi","iy","yo","or"); int commonPairs = countOf("yo","or"); double expectedScore = 2.0 * commonPairs / (text1PairCount + text2PairCount); assertThat(score, closeTo((expectedScore), 0.00001)); }
public static double compute(String input1, String input2) { return compute(input1, input2, Locale.ENGLISH); }
SorensenDiceCoefficient { public static double compute(String input1, String input2) { return compute(input1, input2, Locale.ENGLISH); } }
SorensenDiceCoefficient { public static double compute(String input1, String input2) { return compute(input1, input2, Locale.ENGLISH); }  }
SorensenDiceCoefficient { public static double compute(String input1, String input2) { return compute(input1, input2, Locale.ENGLISH); }  static double compute(String input1, String input2); static double compute(String input1, String input2, String languageTag); }
SorensenDiceCoefficient { public static double compute(String input1, String input2) { return compute(input1, input2, Locale.ENGLISH); }  static double compute(String input1, String input2); static double compute(String input1, String input2, String languageTag);  }