package sudoku.constraint;

import sudoku.Block;
import sudoku.MutableCell;
import sudoku.Sudoku;

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 MutableCell(newSymbolIndex));
	}

}
