public static <T, U> List<U> transformList(List<T> inputList, Function<T, U> transformer) {
    return new ListView<>(inputList::size, index -> transformer.apply(inputList.get(index)));
  }
Create a transformed view of a list by applying a transformer function on each element when {@link List#get(int)}
is called. This method does not copy elements, so changes to the original list will be reflected in the returned
list. Method inspired by the Guava utility Lists.transform.
@param inputList the input list.
@param transformer the function to map an element in {@code inputList} to an element of type {@code U}.
@return the transformed list view.
ambry-utils/src/main/java/com/github/ambry/utils/Utils.java