@Override
public boolean apply(int itemID, Vector itemFeatures) {
if (!alreadyRatedItems.contains(itemID)) {
double predictedRating = userFeatures.dot(itemFeatures);
MutableRecommendedItem top = topItemsQueue.top();
if (predictedRating > top.getValue()) {
top.set(itemID, (float) predictedRating);
topItemsQueue.updateTop();
}
}