Top Description Fields Constructors Methods
org.springframework.transaction.interceptor

public abstract Class DelegatingTransactionAttribute

extends DelegatingTransactionDefinition
implements TransactionAttribute, Serializable
Class Inheritance
All Implemented Interfaces
java.io.Serializable, org.springframework.transaction.interceptor.TransactionAttribute, org.springframework.transaction.TransactionDefinition
Annotations
@SuppressWarnings:serial
Imports
java.io.Serializable, java.util.Collection, org.springframework.lang.Nullable, org.springframework.transaction.support.DelegatingTransactionDefinition

TransactionAttribute implementation that delegates all calls to a given target TransactionAttribute instance. Abstract because it is meant to be subclassed, with subclasses overriding specific methods that are not supposed to simply delegate to the target instance.
Authors
Juergen Hoeller, Mark Paluch
Since
1.2

Field Summary

Modifier and TypeField and Description
private final TransactionAttribute

Constructor Summary

AccessConstructor and Description
public
DelegatingTransactionAttribute(TransactionAttribute
the target TransactionAttribute to delegate to
targetAttribute
)

Create a DelegatingTransactionAttribute for the given target attribute.

Method Summary

Modifier and TypeMethod and Description
public Collection<String>
getLabels()

Implements org.springframework.transaction.interceptor.TransactionAttribute.getLabels.

Return labels associated with this transaction attribute.
public String
getQualifier()

Implements org.springframework.transaction.interceptor.TransactionAttribute.getQualifier.

Return a qualifier value associated with this transaction attribute.
public boolean
rollbackOn(Throwable
the exception to evaluate
ex
)

Implements org.springframework.transaction.interceptor.TransactionAttribute.rollbackOn.

Should we roll back on the given exception?
Inherited from org.springframework.transaction.support.DelegatingTransactionDefinition:
equalsgetIsolationLevelgetNamegetPropagationBehaviorgetTimeouthashCodeisReadOnlytoString

Field Detail

targetAttributeback to summary
private final TransactionAttribute targetAttribute

Constructor Detail

DelegatingTransactionAttributeback to summary
public DelegatingTransactionAttribute(TransactionAttribute targetAttribute)

Create a DelegatingTransactionAttribute for the given target attribute.

Parameters
targetAttribute:TransactionAttribute

the target TransactionAttribute to delegate to

Method Detail

getLabelsback to summary
public Collection<String> getLabels()

Implements org.springframework.transaction.interceptor.TransactionAttribute.getLabels.

Doc from org.springframework.transaction.interceptor.TransactionAttribute.getLabels.

Return labels associated with this transaction attribute.

This may be used for applying specific transactional behavior or follow a purely descriptive nature.

Annotations
@Override
getQualifierback to summary
public String getQualifier()

Implements org.springframework.transaction.interceptor.TransactionAttribute.getQualifier.

Doc from org.springframework.transaction.interceptor.TransactionAttribute.getQualifier.

Return a qualifier value associated with this transaction attribute.

This may be used for choosing a corresponding transaction manager to process this specific transaction.

Annotations
@Override
@Nullable
rollbackOnback to summary
public boolean rollbackOn(Throwable ex)

Implements org.springframework.transaction.interceptor.TransactionAttribute.rollbackOn.

Doc from org.springframework.transaction.interceptor.TransactionAttribute.rollbackOn.

Should we roll back on the given exception?

Parameters
ex:Throwable

the exception to evaluate

Returns:boolean

whether to perform a rollback or not

Annotations
@Override