Save This Page
Home » spring-framework-2.5.5-with-dependencies » org.springframework » aop » framework » [javadoc | source]
org.springframework.aop.framework
final class: Cglib2AopProxy [javadoc | source]
java.lang.Object
   org.springframework.aop.framework.Cglib2AopProxy

All Implemented Interfaces:
    AopProxy, Serializable

CGLIB2-based AopProxy implementation for the Spring AOP framework.

Requires CGLIB 2.1+ on the classpath.. As of Spring 2.0, earlier CGLIB versions are not supported anymore.

Objects of this type should be obtained through proxy factories, configured by an AdvisedSupport object. This class is internal to Spring's AOP framework and need not be used directly by client code.

DefaultAopProxyFactory will automatically create CGLIB2-based proxies if necessary, for example in case of proxying a target class (see the attendant javadoc for details).

Proxies created using this class are thread-safe if the underlying (target) class is thread-safe.

Nested Class Summary:
public static class  Cglib2AopProxy.SerializableNoOp  Serializable replacement for CGLIB's NoOp interface. Public to allow use elsewhere in the framework. 
Field Summary
protected static final  Log logger    Logger available to subclasses; static to optimize serialization 
protected final  AdvisedSupport advised    The configuration used to configure this proxy 
Constructor:
 public Cglib2AopProxy(AdvisedSupport config) throws AopConfigException 
    Create a new Cglib2AopProxy for the given AOP configuration.
    Parameters:
    config - the AOP configuration as AdvisedSupport object
    Throws:
    AopConfigException - if the config is invalid. We try to throw an informative exception in this case, rather than let a mysterious failure happen later.
Method from org.springframework.aop.framework.Cglib2AopProxy Summary:
createEnhancer,   equals,   getProxy,   getProxy,   hashCode,   setConstructorArguments
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.springframework.aop.framework.Cglib2AopProxy Detail:
 protected Enhancer createEnhancer() 
    Creates the CGLIB Enhancer . Subclasses may wish to override this to return a custom Enhancer implementation.
 public boolean equals(Object other) 
 public Object getProxy() 
 public Object getProxy(ClassLoader classLoader) 
 public int hashCode() 
 public  void setConstructorArguments(Object[] constructorArgs,
    Class[] constructorArgTypes) 
    Set constructor arguments to use for creating the proxy.