use of org.springframework.ui.freemarker.FreeMarkerConfigurationFactoryBean in project springframework-source-5.1.x by wb02125055.
the class FreeMarkerConfigurerTests method freeMarkerConfigurationFactoryBeanWithConfigLocation.
@Test(expected = IOException.class)
public void freeMarkerConfigurationFactoryBeanWithConfigLocation() throws Exception {
FreeMarkerConfigurationFactoryBean fcfb = new FreeMarkerConfigurationFactoryBean();
fcfb.setConfigLocation(new FileSystemResource("myprops.properties"));
Properties props = new Properties();
props.setProperty("myprop", "/mydir");
fcfb.setFreemarkerSettings(props);
fcfb.afterPropertiesSet();
}
use of org.springframework.ui.freemarker.FreeMarkerConfigurationFactoryBean in project igloo-parent by igloo-project.
the class NotificationTestConfig method freemarkerMailConfiguration.
@Bean
public FreeMarkerConfigurationFactoryBean freemarkerMailConfiguration() {
FreeMarkerConfigurationFactoryBean configuration = new FreeMarkerConfigurationFactoryBean();
configuration.setTemplateLoaderPath("classpath:notification");
return configuration;
}
use of org.springframework.ui.freemarker.FreeMarkerConfigurationFactoryBean in project igloo-parent by igloo-project.
the class BasicApplicationCoreNotificationConfig method freemarkerMailConfiguration.
@Bean
public FreeMarkerConfigurationFactoryBean freemarkerMailConfiguration() {
FreeMarkerConfigurationFactoryBean configuration = new FreeMarkerConfigurationFactoryBean();
configuration.setTemplateLoaderPath("classpath:notification");
return configuration;
}
use of org.springframework.ui.freemarker.FreeMarkerConfigurationFactoryBean in project tutorials-java by Artister.
the class GeneratorConfig method freeMarkerConfigurationFactoryBean.
@Bean
public FreeMarkerConfigurationFactoryBean freeMarkerConfigurationFactoryBean() {
FreeMarkerConfigurationFactoryBean factoryBean = new FreeMarkerConfigurationFactoryBean();
factoryBean.setTemplateLoaderPath("template");
Properties properties = new Properties();
properties.setProperty("defaultEncoding", "UTF-8");
factoryBean.setFreemarkerSettings(properties);
return factoryBean;
}
Aggregations