BeanDefinitionParser implementations that
need to parse and define just a single BeanDefinition.
Extend this parser class when you want to create a single bean definition
from an arbitrarily complex XML element. You may wish to consider extending
the AbstractSimpleBeanDefinitionParser when you want to create a
single bean definition from a relatively simple custom XML element.
The resulting BeanDefinition will be automatically registered
with the org..
Your job simply is to parse the custom XML Element
into a single BeanDefinition.
getBeanClass, getBeanClassName, doParse
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| 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 builder)BeanDefinitionParse the supplied |
| protected void | doParse(Element
the XML element being parsed element, BeanDefinitionBuilder used to define the builder)BeanDefinitionParse the supplied |
| protected Class | Returns: theClass of the bean that is being defined via parsing
the supplied Element, or null if nonethe element)Element that is being parsedDetermine the bean class corresponding to the supplied |
| protected String | Returns: the class name of the bean that is being defined via parsing the suppliedElement, or null if nonethe element)Element that is being parsedDetermine the bean class name corresponding to the supplied |
| protected String | Returns: the name of the parent bean for the currently parsed bean, ornull if nonethe element)Element that is being parsedDetermine the name for the parent of the currently parsed bean, in case of the current bean being defined as a child bean. |
| protected final AbstractBeanDefinition | Returns: the BeanDefinition resulting from the parsing of the suppliedElementthe element that is to be parsed into a single BeanDefinition element, ParserContext the object encapsulating the current state of the parsing process parserContext)Implements abstract org. BeanDefinitionBuilder instance for the
bean Class and passes it to the
doParse strategy method.
|
| AbstractSingleBeanDefinitionParser | back to summary |
|---|---|
| public AbstractSingleBeanDefinitionParser() | |
| doParse | back to summary |
|---|---|
| protected void doParse(Element element, ParserContext parserContext, BeanDefinitionBuilder builder) Parse the supplied The default implementation delegates to the
| |
| doParse | back to summary |
|---|---|
| protected void doParse(Element element, BeanDefinitionBuilder builder) Parse the supplied The default implementation does nothing.
| |
| getBeanClass | back to summary |
|---|---|
| protected Class Determine the bean class corresponding to the supplied Note that, for application classes, it is generally preferable to
override
| |
| getBeanClassName | back to summary |
|---|---|
| protected String getBeanClassName(Element element) Determine the bean class name corresponding to the supplied
| |
| getParentName | back to summary |
|---|---|
| protected String getParentName(Element element) Determine the name for the parent of the currently parsed bean, in case of the current bean being defined as a child bean. The default implementation returns | |
| parseInternal | back to summary |
|---|---|
| protected final AbstractBeanDefinition parseInternal(Element element, ParserContext parserContext) Implements abstract org. Creates a
| |