code: public static List<Integer> toIntegerList(int[] array) {
          List<Integer> result = new ArrayList<Integer>(array.length);
          for (int partitionId : array) {
              result.add(partitionId);
          }
          return result;
      }
docs: Converts an int array to an Integer {@link List}.
  <p>
  The returned collection can be modified after it is created; it isn't protected by an immutable wrapper.
  
  @param array the array
  @return the list.
  throws {@link NullPointerException} if array is null.