程序包 org.springframework.transaction.interceptor
AOP-based solution for declarative transaction demarcation. Builds on the AOP infrastructure in org.springframework.aop.framework. Any POJO can be transactionally advised with Spring.
The TransactionFactoryProxyBean can be used to create transactional AOP proxies transparently to code that uses them.
The TransactionInterceptor is the AOP Alliance MethodInterceptor that delivers transactional advice, based on the Spring transaction abstraction. This allows declarative transaction management in any environment, even without JTA if an application uses only a single database.
接口概要 接口 说明 TransactionalProxy A marker interface for manually created transactional proxies.TransactionAspectSupport.InvocationCallback Simple callback interface for proceeding with the target invocation.TransactionAttribute This interface adds arollbackOn
specification toTransactionDefinition
.TransactionAttributeSource Strategy interface used byTransactionInterceptor
for metadata retrieval.类概要 类 说明 AbstractFallbackTransactionAttributeSource Abstract implementation ofTransactionAttributeSource
that caches attributes for methods and implements a fallback policy: 1. specific target method; 2. target class; 3. declaring method; 4. declaring class/interface.BeanFactoryTransactionAttributeSourceAdvisor Advisor driven by aTransactionAttributeSource
, used to include a transaction advice bean for methods that are transactional.CompositeTransactionAttributeSource CompositeTransactionAttributeSource
implementation that iterates over a given array ofTransactionAttributeSource
instances.DefaultTransactionAttribute Spring's common transaction attribute implementation.DelegatingTransactionAttribute TransactionAttribute
implementation that delegates all calls to a given targetTransactionAttribute
instance.MatchAlwaysTransactionAttributeSource Very simple implementation of TransactionAttributeSource which will always return the same TransactionAttribute for all methods fed to it.MethodMapTransactionAttributeSource SimpleTransactionAttributeSource
implementation that allows attributes to be stored per method in aMap
.NameMatchTransactionAttributeSource SimpleTransactionAttributeSource
implementation that allows attributes to be matched by registered name.NoRollbackRuleAttribute Tag subclass ofRollbackRuleAttribute
that has the opposite behavior to theRollbackRuleAttribute
superclass.RollbackRuleAttribute Rule determining whether or not a given exception (and any subclasses) should cause a rollback.RuleBasedTransactionAttribute TransactionAttribute implementation that works out whether a given exception should cause transaction rollback by applying a number of rollback rules, both positive and negative.TransactionAspectSupport Base class for transactional aspects, such as theTransactionInterceptor
or an AspectJ aspect.TransactionAttributeEditor PropertyEditor forTransactionAttribute
objects.TransactionAttributeSourceAdvisor Advisor driven by aTransactionAttributeSource
, used to include aTransactionInterceptor
only for methods that are transactional.TransactionAttributeSourceEditor Property editor that converts a String into aTransactionAttributeSource
.TransactionInterceptor AOP Alliance MethodInterceptor for declarative transaction management using the common Spring transaction infrastructure (PlatformTransactionManager
).TransactionProxyFactoryBean Proxy factory bean for simplified declarative transaction handling.