code: protected VelocityEngine createTemplateEngine(Properties properties) {
          Properties actualProperties = properties;
          if (actualProperties == null) {
              actualProperties = new Properties();
          }
  
          String resourceLoader = actualProperties.getProperty(VelocityEngine.RESOURCE_LOADER);
          if (StringUtils.isBlank(resourceLoader)) {
              actualProperties.setProperty(VelocityEngine.RESOURCE_LOADER, "classpath");
              actualProperties.setProperty("classpath.resource.loader.class", ClasspathResourceLoader.class.getName());
          }
  
          String loggerClass = actualProperties.getProperty(VelocityEngine.RUNTIME_LOG_LOGSYSTEM_CLASS);
          if (StringUtils.isBlank(loggerClass)) {
              actualProperties.setProperty(VelocityEngine.RUNTIME_LOG_LOGSYSTEM_CLASS,
                      "org.apache.velocity.runtime.log.NullLogChute");
          }
  
          VelocityEngine velocity = new VelocityEngine(actualProperties);
          velocity.init();
  
          return velocity;
      }
docs: Create and initialize a template engine to use for generating reports.
  
  @param properties properties to use for engine initialization. May be null.
  
  @return A new instance of th template engine to use.