Top Description Fields Constructors Methods
org.springframework.web.servlet.config

pack-priv Class ViewControllerBeanDefinitionParser

extends Object
implements BeanDefinitionParser
Class Inheritance
All Implemented Interfaces
org.springframework.beans.factory.xml.BeanDefinitionParser
Imports
java.util.Map, org.w3c.dom.Element, org.springframework.beans.factory.config.BeanDefinition, .RuntimeBeanReference, org.springframework.beans.factory.parsing.BeanComponentDefinition, org.springframework.beans.factory.support.ManagedMap, .RootBeanDefinition, org.springframework.beans.factory.xml.BeanDefinitionParser, .ParserContext, org.springframework.http.HttpStatusCode, org.springframework.lang.Nullable, org.springframework.web.servlet.handler.SimpleUrlHandlerMapping, org.springframework.web.servlet.mvc.ParameterizableViewController, org.springframework.web.servlet.view.RedirectView

org.springframework.beans.factory.xml.BeanDefinitionParser that parses the following MVC namespace elements:

All elements result in the registration of a ParameterizableViewController with all controllers mapped using in a single SimpleUrlHandlerMapping.

Authors
Keith Donald, Christian Dupuis, Rossen Stoyanchev
Since
3.0

Field Summary

Modifier and TypeField and Description
private static final String

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
private RootBeanDefinition
getRedirectView(Element element, HttpStatusCode status, Object source)

public BeanDefinition
parse(Element
the element that is to be parsed into one or more BeanDefinitions
element
,
ParserContext
the object encapsulating the current state of the parsing process; provides access to a org.springframework.beans.factory.support.BeanDefinitionRegistry
parserContext
)

Implements org.springframework.beans.factory.xml.BeanDefinitionParser.parse.

Parse the specified Element and register the resulting BeanDefinition(s) with the BeanDefinitionRegistry embedded in the supplied ParserContext.

private BeanDefinition
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

HANDLER_MAPPING_BEAN_NAMEback to summary
private static final String HANDLER_MAPPING_BEAN_NAME

Constructor Detail

ViewControllerBeanDefinitionParserback to summary
pack-priv ViewControllerBeanDefinitionParser()

Method Detail

getRedirectViewback to summary
private RootBeanDefinition getRedirectView(Element element, HttpStatusCode status, Object source)
parseback to summary
public BeanDefinition parse(Element element, ParserContext parserContext)

Implements org.springframework.beans.factory.xml.BeanDefinitionParser.parse.

Doc from org.springframework.beans.factory.xml.BeanDefinitionParser.parse.

Parse the specified Element and register the resulting BeanDefinition(s) with the BeanDefinitionRegistry embedded in the supplied ParserContext.

Implementations must return the primary BeanDefinition that results from the parse if they will ever be used in a nested fashion (for example as an inner tag in a <property/> tag). Implementations may return null if they will not be used in a nested fashion.

Parameters
element:Element

the element that is to be parsed into one or more BeanDefinitions

parserContext:ParserContext

the object encapsulating the current state of the parsing process; provides access to a org.springframework.beans.factory.support.BeanDefinitionRegistry

Returns:BeanDefinition

the primary BeanDefinition

Annotations
@Override
@SuppressWarnings:unchecked
registerHandlerMappingback to summary
private BeanDefinition registerHandlerMapping(ParserContext context, Object source)