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

pack-priv Class TxAdviceBeanDefinitionParser

extends AbstractSingleBeanDefinitionParser
Class Inheritance
Imports
java.util.ArrayList, .List, org.w3c.dom.Element, org.springframework.beans.factory.config.TypedStringValue, org.springframework.beans.factory.support.BeanDefinitionBuilder, .ManagedMap, .RootBeanDefinition, org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser, .ParserContext, org.springframework.transaction.interceptor.NameMatchTransactionAttributeSource, .NoRollbackRuleAttribute, .RollbackRuleAttribute, .RuleBasedTransactionAttribute, .TransactionInterceptor, org.springframework.util.StringUtils, org.springframework.util.xml.DomUtils

BeanDefinitionParser for the <tx:advice/> tag.
Authors
Rob Harrop, Juergen Hoeller, Adrian Colyer, Chris Beams
Since
2.0

Field Summary

Modifier and TypeField and Description
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
private void
addNoRollbackRuleAttributesTo(List<RollbackRuleAttribute> rollbackRules, String noRollbackForValue)

private void
protected void
doParse(Element
the XML element being parsed
element
,
ParserContext
the object encapsulating the current state of the parsing process
parserContext
,
BeanDefinitionBuilder
used to define the BeanDefinition
builder
)

Overrides org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser.doParse.

Parse the supplied Element and populate the supplied BeanDefinitionBuilder as required.

protected Class<?>
getBeanClass(Element
the Element that is being parsed
element
)

Overrides org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser.getBeanClass.

Determine the bean class corresponding to the supplied Element.

private RootBeanDefinition
parseAttributeSource(Element attrEle, ParserContext parserContext)

Inherited from org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser:
doParsegetBeanClassNamegetParentNameparseInternal

Field Detail

ATTRIBUTES_ELEMENTback to summary
private static final String ATTRIBUTES_ELEMENT
ISOLATION_ATTRIBUTEback to summary
private static final String ISOLATION_ATTRIBUTE
METHOD_ELEMENTback to summary
private static final String METHOD_ELEMENT
METHOD_NAME_ATTRIBUTEback to summary
private static final String METHOD_NAME_ATTRIBUTE
NO_ROLLBACK_FOR_ATTRIBUTEback to summary
private static final String NO_ROLLBACK_FOR_ATTRIBUTE
PROPAGATION_ATTRIBUTEback to summary
private static final String PROPAGATION_ATTRIBUTE
READ_ONLY_ATTRIBUTEback to summary
private static final String READ_ONLY_ATTRIBUTE
ROLLBACK_FOR_ATTRIBUTEback to summary
private static final String ROLLBACK_FOR_ATTRIBUTE
TIMEOUT_ATTRIBUTEback to summary
private static final String TIMEOUT_ATTRIBUTE

Constructor Detail

TxAdviceBeanDefinitionParserback to summary
pack-priv TxAdviceBeanDefinitionParser()

Method Detail

addNoRollbackRuleAttributesToback to summary
private void addNoRollbackRuleAttributesTo(List<RollbackRuleAttribute> rollbackRules, String noRollbackForValue)
addRollbackRuleAttributesToback to summary
private void addRollbackRuleAttributesTo(List<RollbackRuleAttribute> rollbackRules, String rollbackForValue)
doParseback to summary
protected void doParse(Element element, ParserContext parserContext, BeanDefinitionBuilder builder)

Overrides org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser.doParse.

Doc from org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser.doParse.

Parse the supplied Element and populate the supplied BeanDefinitionBuilder as required.

The default implementation delegates to the doParse version without ParserContext argument.

Parameters
element:Element

the XML element being parsed

parserContext:ParserContext

the object encapsulating the current state of the parsing process

builder:BeanDefinitionBuilder

used to define the BeanDefinition

Annotations
@Override
getBeanClassback to summary
protected Class<?> getBeanClass(Element element)

Overrides org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser.getBeanClass.

Doc from org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser.getBeanClass.

Determine the bean class corresponding to the supplied Element.

Note that, for application classes, it is generally preferable to override getBeanClassName instead, in order to avoid a direct dependence on the bean implementation class. The BeanDefinitionParser and its NamespaceHandler can be used within an IDE plugin then, even if the application classes are not available on the plugin's classpath.

Parameters
element:Element

the Element that is being parsed

Returns:Class<?>

the Class of the bean that is being defined via parsing the supplied Element, or null if none

Annotations
@Override
parseAttributeSourceback to summary
private RootBeanDefinition parseAttributeSource(Element attrEle, ParserContext parserContext)