1. There is no default constructor in AbstractTask i.e. the example should call super(String). public PrimeNumbersTask(int numbersToFind) { super("") //initialize } 2. The return type of execute <V> does not match the interface definition <V, C> i.e. shouldn't it return a List? @Override public List<Integer> execute(Tracker<Integer> tracker) throws Exception { while (!enough && !isCancelled()) {
There is no default constructor in AbstractTask i.e. the example should call super(String).
public PrimeNumbersTask(int numbersToFind) {
super("")
//initialize
}
The return type of execute does not match the interface definition <V, C>
i.e. shouldn't it return a List?
@OverRide
public List execute(Tracker tracker) throws Exception {
while (!enough && !isCancelled()) {