docs: public static <T> T newInstance(Class<T> clazz) throws ClassInstantiationException {
          if (clazz == null) {
              return null;
          }
  
          try {
              return clazz.newInstance();
          } catch (Exception e) {
              throw new ClassInstantiationException("Failed to instantiate class: " + clazz.getName(), e);
          }
      }