Search in sources :

Example 1 with CasConfigurationEmbeddedValueResolver

use of org.apereo.cas.config.support.CasConfigurationEmbeddedValueResolver in project cas by apereo.

the class CasCoreUtilConfiguration method init.

@PostConstruct
public void init() {
    final ConfigurableApplicationContext applicationContext = applicationContextProvider().getConfigurableApplicationContext();
    final DefaultFormattingConversionService conversionService = new DefaultFormattingConversionService(true);
    applicationContext.getEnvironment().setConversionService(conversionService);
    final ScheduledAnnotationBeanPostProcessor p = applicationContext.getBean(ScheduledAnnotationBeanPostProcessor.class);
    p.setEmbeddedValueResolver(new CasConfigurationEmbeddedValueResolver(applicationContext));
}
Also used : ConfigurableApplicationContext(org.springframework.context.ConfigurableApplicationContext) ScheduledAnnotationBeanPostProcessor(org.springframework.scheduling.annotation.ScheduledAnnotationBeanPostProcessor) CasConfigurationEmbeddedValueResolver(org.apereo.cas.config.support.CasConfigurationEmbeddedValueResolver) DefaultFormattingConversionService(org.springframework.format.support.DefaultFormattingConversionService) PostConstruct(javax.annotation.PostConstruct)

Aggregations

PostConstruct (javax.annotation.PostConstruct)1 CasConfigurationEmbeddedValueResolver (org.apereo.cas.config.support.CasConfigurationEmbeddedValueResolver)1 ConfigurableApplicationContext (org.springframework.context.ConfigurableApplicationContext)1 DefaultFormattingConversionService (org.springframework.format.support.DefaultFormattingConversionService)1 ScheduledAnnotationBeanPostProcessor (org.springframework.scheduling.annotation.ScheduledAnnotationBeanPostProcessor)1