Ejemplo n.º 1
0
 @Override
 protected boolean doStep(SolutionStep step) {
   boolean handled = false;
   switch (step.getType()) {
     case GIVE_UP:
       handled = true;
       break;
     default:
       handled = false;
   }
   return handled;
 }
Ejemplo n.º 2
0
 @Override
 protected boolean doStep(SolutionStep step) {
   boolean handled = true;
   sudoku = finder.getSudoku();
   switch (step.getType()) {
     case XY_WING:
     case W_WING:
     case XYZ_WING:
       for (Candidate cand : step.getCandidatesToDelete()) {
         sudoku.delCandidate(cand.getIndex(), cand.getValue());
       }
       break;
     default:
       handled = false;
   }
   return handled;
 }