public void replaceBoardWithRandom(String board){
  if (board == null) {
    return;
  }
  for (int i=0; i < boardsSelected.size(); i++) {
    if (board.equals(boardsSelected.get(i))) {
      int rindex;
      if (boardsAvailable.size() == 1) {
        rindex=0;
      }
 else {
        rindex=Compute.randomInt(boardsAvailable.size() - 3) + 3;
      }
      if (0 == Compute.randomInt(2)) {
        boardsSelected.set(i,Board.BOARD_REQUEST_ROTATION + boardsAvailable.get(rindex));
      }
 else {
        boardsSelected.set(i,boardsAvailable.get(rindex));
      }
    }
  }
}

public void replaceBoardWithRandom ( String board ) { if ( board == null ) { return ; } for ( int i = 0 ; i < boardsSelected . size ( ) ; i ++ ) { if ( board . equals ( boardsSelected . get ( i ) ) ) { int rindex ; if ( boardsAvailable . size ( ) == 1 ) { rindex = 0 ; } else { rindex = Compute . randomInt ( boardsAvailable . size ( ) - 3 ) + 3 ; } if ( 0 == Compute . randomInt ( 2 ) ) { boardsSelected . set ( i , Board . BOARD_REQUEST_ROTATION + boardsAvailable . get ( rindex ) ) ; } else { boardsSelected . set ( i , boardsAvailable . get ( rindex ) ) ; } } } }
replaces the specified type of board with random boards
