use of de.geeksfactory.opacclient.searchfields.MeaningDetector in project opacclient by opacapp.
the class BaseApi method getSearchFields.
@Override
public List<SearchField> getSearchFields() throws JSONException, OpacErrorException, IOException {
List<SearchField> fields = parseSearchFields();
if (shouldUseMeaningDetector()) {
MeaningDetector md = new MeaningDetectorImpl(library);
for (int i = 0; i < fields.size(); i++) {
fields.set(i, md.detectMeaning(fields.get(i)));
}
Collections.sort(fields, new SearchField.OrderComparator());
}
return fields;
}
Aggregations