Interface BeanPostProcessor

All Known Implementing Classes:
AopProxyBeanPostProcessor

public interface BeanPostProcessor
Bean post processor interface to customize bean initialization.
Bean后处理器接口,用于自定义Bean初始化。
  • Method Details

    • postProcessBeforeInitialization

      default Object postProcessBeforeInitialization(Object bean, String beanName)
      Apply this BeanPostProcessor to the given new bean instance before any bean initialization callbacks.
      在任何Bean初始化回调之前,将此BeanPostProcessor应用于给定的新Bean实例。
      Parameters:
      bean - the new bean instance
      新的Bean实例
      beanName - the name of the bean
      Bean的名称
      Returns:
      the bean instance to use
      要使用的Bean实例
    • postProcessAfterInitialization

      default Object postProcessAfterInitialization(Object bean, String beanName)
      Apply this BeanPostProcessor to the given new bean instance after any bean initialization callbacks.
      在任何Bean初始化回调之后,将此BeanPostProcessor应用于给定的新Bean实例。
      Parameters:
      bean - the new bean instance
      新的Bean实例
      beanName - the name of the bean
      Bean的名称
      Returns:
      the bean instance to use
      要使用的Bean实例