This commit is contained in:
@@ -2,6 +2,7 @@ package sudoku.constraint;
|
||||
|
||||
import sudoku.Block;
|
||||
import sudoku.Cell;
|
||||
import sudoku.MutableCell;
|
||||
import sudoku.Sudoku;
|
||||
|
||||
public class BlockConstraint implements IConstraint{
|
||||
@@ -9,7 +10,7 @@ public class BlockConstraint implements IConstraint{
|
||||
@Override
|
||||
public boolean canBePlaced(final Sudoku s, int x, int y, int newSymbolIndex) {
|
||||
Block bloc = s.getCell(x, y).getBlock();
|
||||
return !bloc.getCells().contains(new Cell(newSymbolIndex));
|
||||
return !bloc.getCells().contains(new MutableCell(newSymbolIndex));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user