org.springframework.transaction.interceptor
Class TransactionAttributeSourceAdvisor

java.lang.Object
  extended byorg.springframework.aop.support.StaticMethodMatcher
      extended byorg.springframework.aop.support.StaticMethodMatcherPointcut
          extended byorg.springframework.aop.support.StaticMethodMatcherPointcutAdvisor
              extended byorg.springframework.transaction.interceptor.TransactionAttributeSourceAdvisor
All Implemented Interfaces:
Advisor, MethodMatcher, Ordered, Pointcut, PointcutAdvisor, java.io.Serializable

public class TransactionAttributeSourceAdvisor
extends StaticMethodMatcherPointcutAdvisor

Advisor driven by a TransactionAttributeSource, used to exclude a TransactionInterceptor from methods that are non-transactional.

Because the AOP framework caches advice calculations, this is normally faster than just letting the TransactionInterceptor run and find out itself that it has no work to do.

Author:
Rod Johnson
See Also:
TransactionInterceptor, TransactionProxyFactoryBean, Serialized Form

Field Summary
 
Fields inherited from interface org.springframework.aop.Pointcut
TRUE
 
Fields inherited from interface org.springframework.aop.MethodMatcher
TRUE
 
Constructor Summary
TransactionAttributeSourceAdvisor(TransactionInterceptor ti)
           
 
Method Summary
 boolean matches(java.lang.reflect.Method m, java.lang.Class targetClass)
          Perform static checking.
 
Methods inherited from class org.springframework.aop.support.StaticMethodMatcherPointcutAdvisor
getAdvice, getOrder, getPointcut, isPerInstance, setAdvice, setOrder
 
Methods inherited from class org.springframework.aop.support.StaticMethodMatcherPointcut
getClassFilter, getMethodMatcher
 
Methods inherited from class org.springframework.aop.support.StaticMethodMatcher
isRuntime, matches
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TransactionAttributeSourceAdvisor

public TransactionAttributeSourceAdvisor(TransactionInterceptor ti)
Method Detail

matches

public boolean matches(java.lang.reflect.Method m,
                       java.lang.Class targetClass)
Description copied from interface: MethodMatcher
Perform static checking. If this returns false, or if the isRuntime() method returns false, no runtime check will be made.

Parameters:
m - candidate method
targetClass - target class (may be null, in which case the candidate class must be taken to be the method's declaring class)
Returns:
whether or not this method matches statically


Copyright (C) 2003-2004 The Spring Framework Project.