Log createLogFromClassName(String classLabel) throws Exception {
  Class<?> clazz=Class.forName(logClassName);
  @SuppressWarnings("unchecked") Constructor<Log> constructor=(Constructor<Log>)clazz.getConstructor(String.class);
  return constructor.newInstance(classLabel);
}

Log createLogFromClassName ( String classLabel ) throws Exception { Class < ? > clazz = Class . forName ( logClassName ) ; @ SuppressWarnings ( "unchecked" ) Constructor < Log > constructor = ( Constructor < Log > ) clazz . getConstructor ( String . class ) ; return constructor . newInstance ( classLabel ) ; }
try to create the log from the class name which may throw .
