@Override
	public List<Move> generateMoves(Position from)
	{
		List<Move> result = new ArrayList<Move>();
		
		Column column = from.getColumn();
		Row row = from.getRow();
		
		Position to;
		
		if (!row.isFirst())
		{
			if (!column.isFirst()) 
			{
				to = Position.get(column.previous(), row.previous());
				result.add(new Move(this, from, to));
			}
			
			to = Position.get(column, row.previous());
			result.add(new Move(this, from, to));
			
			if (!column.isLast())
			{
				to = Position.get(column.next(), row.previous());
				result.add(new Move(this, from, to));
			}
		}
		
		if (!column.isLast()) 
		{
			to = Position.get(column.next(), row);
			result.add(new Move(this, from, to));
		}
		
		if (!row.isLast())
		{
			if (!column.isLast())
			{
				to = Position.get(column.next(), row.next());
				result.add(new Move(this, from, to));
			}
			
			to = Position.get(column, row.next());
			result.add(new Move(this, from, to));
			
			if (!column.isFirst()) 
			{
				to = Position.get(column.previous(), row.next());
				result.add(new Move(this, from, to));
			}
		}
		
		if (!column.isFirst()) 
		{
			to = Position.get(column.previous(), row);
			result.add(new Move(this, from, to));
		}
		
		return result;
	}