class MoreMapUtils {

  public static <T extends Enum<T>> List<T> getListOfEnum(
      Map<?, ?> map,
      Object key,
      List<T> defaultValue,
      final Class<T> enumClass) {
    return getList(map, key, defaultValue, new Function<Object, T>() {
      @Override
      public T apply(Object input) {
        if (input == null) {
          return null;
        }
        if (enumClass.isAssignableFrom(input.getClass())) {
          return enumClass.cast(input);
        }
        return Enum.valueOf(enumClass, input.toString().trim().toUpperCase(Locale.ROOT));
      }
    });
  }

  private  MoreMapUtils();

}