return (String[]) set.toArray(new String[set.size()]);
}
private List buildMatchList(String[] canonicalProperties, String[] canonicalFields) {
List matchList = new LinkedList();
MatchCalculator calc = new MatchCalculator();
for (int i = 0; i < canonicalProperties.length; i++) {
for (int j = 0; j < canonicalFields.length; j++) {
String prop = canonicalProperties[i];
String field = canonicalFields[j];
double score = calc.calculateMatch(prop, field);
Match match = new Match(prop, field, score);
matchList.add(match);
}
}
sortMatches(matchList);