org.springframework.jee.interfaces.intercept
Interface InterceptionMetadataI

All Superinterfaces:
Jsr250MetadataI
All Known Subinterfaces:
EjbProxyMetadataI
All Known Implementing Classes:
EjbInjectionMetadata, EjbMetadata, EjbProxyMetadata, InterceptionMetadata, TransactionalMetadata

public interface InterceptionMetadataI
extends Jsr250MetadataI

Author:
Safin Li, Michael Chen

Method Summary
 void addBusinessInterface(Class<?> businessInterface)
          Add a business interface for the singleton.
 Object createProxyIfNecessary(Object target)
          Use Spring AOP to create a proxy invoking the JEE-style interceptors and any Spring-style interceptors.
 Object createProxyIfNecessary(Object target, Map<Class,Object> interceptorInstancesForClass)
          Use Spring AOP to create a proxy invoking the JEE-style interceptors and any Spring-style interceptors.
 List<Class<?>> findBusinessInterfacesFromClassOrAnnotation(Class<?> clazz)
           
 List<InterceptorMetadataI> getInterceptorMetadata()
           
 void registerInterceptorMetadata(InterceptorMetadataI im)
          Add interceptor metadata.
 void registerInterceptorOrder(InterceptorMetadataI im, Object object)
           
 void registerSelfInterceptorMethod(Method selfInterceptorMethod)
          Set the self interceptor method for this component
 void setBeanControlInterface(Class beanControlInterface)
           
 void setBeanControlInterfaceMethods(Set<Method> beanControlInterfaceMethods)
           
 void setExcludeClassInterceptors(Object methodOrClass)
           
 void setExcludeDefaultInterceptors(Object methodOrClass)
           
 
Methods inherited from interface org.springframework.jee.interfaces.inject.Jsr250MetadataI
addInjection, getComponentClass, getComponentName, getDeploymentUnitMetadata, getInjections, getLifecycleEventCallbackMethod, inject, invokeLifecycleMethods, refresh, registerLifecycleEventCallbackMethod
 

Method Detail

registerSelfInterceptorMethod

void registerSelfInterceptorMethod(Method selfInterceptorMethod)
Set the self interceptor method for this component

Parameters:
selfInterceptorMethod - the self interceptor method for this component

setBeanControlInterface

void setBeanControlInterface(Class beanControlInterface)

setBeanControlInterfaceMethods

void setBeanControlInterfaceMethods(Set<Method> beanControlInterfaceMethods)

setExcludeClassInterceptors

void setExcludeClassInterceptors(Object methodOrClass)

setExcludeDefaultInterceptors

void setExcludeDefaultInterceptors(Object methodOrClass)

registerInterceptorMetadata

void registerInterceptorMetadata(InterceptorMetadataI im)
Add interceptor metadata. Whether it's a class or method level interceptor will be defined by whether the matchingMethod it returns is null. Following the EJB 3.0 specification, method level interceptors will be added after all class level interceptors.

Parameters:
im - interceptor
matchingMethod - method to match on

registerInterceptorOrder

void registerInterceptorOrder(InterceptorMetadataI im,
                              Object object)

addBusinessInterface

void addBusinessInterface(Class<?> businessInterface)
Add a business interface for the singleton. If no business methods are added, default to using introspection to find all interfaces on the class

Parameters:
businessInterface - business interface to add

findBusinessInterfacesFromClassOrAnnotation

List<Class<?>> findBusinessInterfacesFromClassOrAnnotation(Class<?> clazz)

createProxyIfNecessary

Object createProxyIfNecessary(Object target)
Use Spring AOP to create a proxy invoking the JEE-style interceptors and any Spring-style interceptors. Create new instances of the given interceptors.

Parameters:
instance - the singleton instance to wrap in a proxy
Returns:
a Spring AOP proxy-control interface allowing subsequent changes to the proxy, if the object was proxied at all

createProxyIfNecessary

Object createProxyIfNecessary(Object target,
                              Map<Class,Object> interceptorInstancesForClass)
Use Spring AOP to create a proxy invoking the JEE-style interceptors and any Spring-style interceptors. Allows the creation of a fresh proxy wrapping a given target singleton instance and set of interceptors: for example, in the case where we have passivated a SFSB and now need to create a new proxy given activated interceptors and target instance state.

Parameters:
instance - the singleton instance to wrap in a proxy
interceptorInstancesForClass - map from interceptor class to instance of JEE interceptors
Returns:
a Spring AOP proxy-control interface allowing subsequent changes to the proxy, if the object was proxied at all

getInterceptorMetadata

List<InterceptorMetadataI> getInterceptorMetadata()


Copyright © 2006-2008 SpringSource (formerly Interface21). All Rights Reserved.