package com.qianwen.core.i18n.config;
|
|
import com.qianwen.core.i18n.advice.I18nResponseAdvice;
|
import com.qianwen.core.i18n.props.I18nProperties;
|
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
|
import org.springframework.boot.context.properties.EnableConfigurationProperties;
|
import org.springframework.context.MessageSource;
|
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Configuration;
|
|
@EnableConfigurationProperties({I18nProperties.class})
|
@Configuration(proxyBeanMethods = false)
|
@AutoConfigureAfter({I18nMessageSourceConfiguration.class})
|
/* loaded from: blade-starter-i18n-9.3.0.0-SNAPSHOT.jar:org/springblade/core/i18n/config/I18nAutoConfiguration.class */
|
public class I18nAutoConfiguration {
|
@ConditionalOnMissingBean
|
@Bean
|
public I18nResponseAdvice i18nResponseAdvice(MessageSource messageSource, I18nProperties i18nProperties) {
|
return new I18nResponseAdvice(messageSource, i18nProperties);
|
}
|
}
|