if (knownPages != null) {
filteredList = new ArrayList<Page>(pageList);
filteredList.removeAll(knownPages);
}
if (filteredList.size() <= maxPages) {
addTask(new DisambiguationStatusCallable(wikipedia, this, api, filteredList, forceApiCall));
} else {
int index = 0;
while (index < filteredList.size()) {
List<Page> tmpList = new ArrayList<Page>(api.getMaxPagesPerQuery());
for (int i = 0; (i < maxPages) && (index < filteredList.size()); i++, index++) {
tmpList.add(filteredList.get(index));
}
addTask(new DisambiguationStatusCallable(wikipedia, this, api, tmpList, forceApiCall));
}
}
block(true);
// Retrieving possible disambiguations