类 ProxyCreatorSupport

所有已实现的接口:
Advised, TargetClassAware, Serializable
直接已知子类:
AspectJProxyFactory, ProxyFactory, ProxyFactoryBean

public class ProxyCreatorSupport extends AdvisedSupport
Base class for proxy factories. Provides convenient access to a configurable AopProxyFactory.
从以下版本开始:
3.0
作者:
Juergen Hoeller, TODAY 2021/2/1 22:55
另请参阅:
  • 字段详细资料

    • serialVersionUID

      private static final long serialVersionUID
      另请参阅:
    • active

      private boolean active
      Set to true when the first AOP proxy has been created.
    • aopProxyFactory

      private AopProxyFactory aopProxyFactory
    • listeners

      @Nullable private ArrayList<AdvisedSupportListener> listeners
  • 构造器详细资料

    • ProxyCreatorSupport

      public ProxyCreatorSupport()
      Create a new ProxyCreatorSupport instance.
    • ProxyCreatorSupport

      public ProxyCreatorSupport(AopProxyFactory aopProxyFactory)
      Create a new ProxyCreatorSupport instance.
      参数:
      aopProxyFactory - the AopProxyFactory to use
  • 方法详细资料

    • setAopProxyFactory

      public void setAopProxyFactory(AopProxyFactory aopProxyFactory)
      Customize the AopProxyFactory, allowing different strategies to be dropped in without changing the core framework.

      Default is DefaultAopProxyFactory, using dynamic JDK proxies or CGLIB proxies based on the requirements.

    • getAopProxyFactory

      public AopProxyFactory getAopProxyFactory()
      Return the AopProxyFactory that this ProxyConfig uses.
    • createAopProxy

      protected final AopProxy createAopProxy()
      Subclasses should call this to get a new AOP proxy. They should not create an AOP proxy with this as an argument.
    • activate

      private void activate()
      Activate this proxy configuration.
    • adviceChanged

      protected void adviceChanged()
      Propagate advice change event to all AdvisedSupportListeners.
      覆盖:
      adviceChanged 在类中 AdvisedSupport
      另请参阅:
    • isActive

      protected final boolean isActive()
      Subclasses can call this to check whether any AOP proxies have been created yet.
    • addListener

      public void addListener(AdvisedSupportListener listener)
      Add the given AdvisedSupportListener to this proxy configuration.
      参数:
      listener - the listener to register
    • removeListener

      public void removeListener(AdvisedSupportListener listener)
      Remove the given AdvisedSupportListener from this proxy configuration.
      参数:
      listener - the listener to deregister