public static void findEntryMessagePrinter(boolean hasMatch, ArrayList<Integer> matchingTasks) {
if (!hasMatch) {
System.out.println("No matching tasks found.");
} else {
System.out.println("Here are the matching tasks in your list:");
for (int i = 0; i < matchingTasks.size(); i++) {
System.out.print((i) + ".");
EntryPrinter.printEntry(matchingTasks.get(i));
}
}
}
}
Modify from
tasks
toentries
.