类 ConfigurationPropertiesBindingPostProcessor

  • 所有已实现的接口:
    EventListener, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.config.BeanPostProcessor, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener<org.springframework.context.event.ContextRefreshedEvent>, org.springframework.context.EnvironmentAware, org.springframework.core.Ordered, org.springframework.core.PriorityOrdered

    public class ConfigurationPropertiesBindingPostProcessor
    extends Object
    implements org.springframework.beans.factory.config.BeanPostProcessor, org.springframework.beans.factory.BeanFactoryAware, org.springframework.context.EnvironmentAware, org.springframework.context.ApplicationContextAware, org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean, org.springframework.context.ApplicationListener<org.springframework.context.event.ContextRefreshedEvent>, org.springframework.core.PriorityOrdered
    BeanPostProcessor to bind PropertySources to beans annotated with ConfigurationProperties.
    • 方法详细资料

      • setConverters

        @Autowired(required=false)
        @ConfigurationPropertiesBinding
        public void setConverters​(List<org.springframework.core.convert.converter.Converter<?,​?>> converters)
        A list of custom converters (in addition to the defaults) to use when converting properties for binding.
        参数:
        converters - the converters to set
      • setGenericConverters

        @Autowired(required=false)
        @ConfigurationPropertiesBinding
        public void setGenericConverters​(List<org.springframework.core.convert.converter.GenericConverter> converters)
        A list of custom converters (in addition to the defaults) to use when converting properties for binding.
        参数:
        converters - the converters to set
      • setOrder

        public void setOrder​(int order)
        Set the order of the bean.
        参数:
        order - the order
      • getOrder

        public int getOrder()
        Return the order of the bean.
        指定者:
        getOrder 在接口中 org.springframework.core.Ordered
        返回:
        the order
      • setPropertySources

        public void setPropertySources​(org.springframework.core.env.PropertySources propertySources)
        Set the property sources to bind.
        参数:
        propertySources - the property sources
      • setValidator

        public void setValidator​(org.springframework.validation.Validator validator)
        Set the bean validator used to validate property fields.
        参数:
        validator - the validator
      • setConversionService

        public void setConversionService​(org.springframework.core.convert.ConversionService conversionService)
        Set the conversion service used to convert property values.
        参数:
        conversionService - the conversion service
      • setBeanFactory

        public void setBeanFactory​(org.springframework.beans.factory.BeanFactory beanFactory)
                            throws org.springframework.beans.BeansException
        指定者:
        setBeanFactory 在接口中 org.springframework.beans.factory.BeanFactoryAware
        抛出:
        org.springframework.beans.BeansException
      • setEnvironment

        public void setEnvironment​(org.springframework.core.env.Environment environment)
        指定者:
        setEnvironment 在接口中 org.springframework.context.EnvironmentAware
      • setApplicationContext

        public void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)
        指定者:
        setApplicationContext 在接口中 org.springframework.context.ApplicationContextAware
      • onApplicationEvent

        public void onApplicationEvent​(org.springframework.context.event.ContextRefreshedEvent event)
        指定者:
        onApplicationEvent 在接口中 org.springframework.context.ApplicationListener<org.springframework.context.event.ContextRefreshedEvent>
      • destroy

        public void destroy()
                     throws Exception
        指定者:
        destroy 在接口中 org.springframework.beans.factory.DisposableBean
        抛出:
        Exception
      • postProcessBeforeInitialization

        public Object postProcessBeforeInitialization​(Object bean,
                                                      String beanName)
                                               throws org.springframework.beans.BeansException
        指定者:
        postProcessBeforeInitialization 在接口中 org.springframework.beans.factory.config.BeanPostProcessor
        抛出:
        org.springframework.beans.BeansException
      • postProcessAfterInitialization

        public Object postProcessAfterInitialization​(Object bean,
                                                     String beanName)
                                              throws org.springframework.beans.BeansException
        指定者:
        postProcessAfterInitialization 在接口中 org.springframework.beans.factory.config.BeanPostProcessor
        抛出:
        org.springframework.beans.BeansException