当前位置: 首页>>代码示例>>Java>>正文


Java MatrixVariableMethodArgumentResolver类代码示例

本文整理汇总了Java中org.springframework.web.servlet.mvc.method.annotation.MatrixVariableMethodArgumentResolver的典型用法代码示例。如果您正苦于以下问题:Java MatrixVariableMethodArgumentResolver类的具体用法?Java MatrixVariableMethodArgumentResolver怎么用?Java MatrixVariableMethodArgumentResolver使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


MatrixVariableMethodArgumentResolver类属于org.springframework.web.servlet.mvc.method.annotation包,在下文中一共展示了MatrixVariableMethodArgumentResolver类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getArgumentResolvers

import org.springframework.web.servlet.mvc.method.annotation.MatrixVariableMethodArgumentResolver; //导入依赖的package包/类
private List<HandlerMethodArgumentResolver> getArgumentResolvers(List<HttpMessageConverter<?>> messageConverters) {
	List<HandlerMethodArgumentResolver> resolvers = new LinkedList<>();

	resolvers.add(new RequestParamMethodArgumentResolver(beanFactory, false));
	resolvers.add(new RequestParamMapMethodArgumentResolver());
	resolvers.add(new MatrixVariableMethodArgumentResolver());
	resolvers.add(new MatrixVariableMapMethodArgumentResolver());
	resolvers.add(new ServletModelAttributeMethodProcessor(false));
	resolvers.add(new RequestResponseBodyMethodProcessor(messageConverters));
	resolvers.add(new RequestPartMethodArgumentResolver(messageConverters));
	resolvers.add(new RequestHeaderMethodArgumentResolver(beanFactory));
	resolvers.add(new RequestHeaderMapMethodArgumentResolver());
	resolvers.add(new ServletCookieValueMethodArgumentResolver(beanFactory));
	resolvers.add(new ExpressionValueMethodArgumentResolver(beanFactory));

	resolvers.add(new ServletRequestMethodArgumentResolver());
	resolvers.add(new ServletResponseMethodArgumentResolver());
	resolvers.add(new HttpEntityMethodProcessor(messageConverters));
	resolvers.add(new RedirectAttributesMethodArgumentResolver());
	resolvers.add(new ModelMethodProcessor());
	resolvers.add(new MapMethodProcessor());
	resolvers.add(new ErrorsMethodArgumentResolver());
	resolvers.add(new SessionStatusMethodArgumentResolver());
	resolvers.add(new UriComponentsBuilderMethodArgumentResolver());

	resolvers.add(new RequestParamMethodArgumentResolver(beanFactory, true));
	resolvers.add(new ServletModelAttributeMethodProcessor(true));

	return resolvers;
}
 
开发者ID:crnk-project,项目名称:crnk-framework,代码行数:31,代码来源:SpringParameterProvider.java

示例2: getUifArgumentResolvers

import org.springframework.web.servlet.mvc.method.annotation.MatrixVariableMethodArgumentResolver; //导入依赖的package包/类
/**
 * Return the list of argument resolvers to use including built-in resolvers
 * and custom resolvers provided via {@link #setCustomArgumentResolvers}.
 */
protected List<HandlerMethodArgumentResolver> getUifArgumentResolvers() {
    List<HandlerMethodArgumentResolver> resolvers = new ArrayList<HandlerMethodArgumentResolver>();

    resolvers.add(new UifDefaultFormMethodArgumentResolver());

    // Annotation-based argument resolution
    resolvers.add(new RequestParamMethodArgumentResolver(getBeanFactory(), false));
    resolvers.add(new RequestParamMapMethodArgumentResolver());
    resolvers.add(new PathVariableMethodArgumentResolver());
    resolvers.add(new PathVariableMapMethodArgumentResolver());
    resolvers.add(new MatrixVariableMethodArgumentResolver());
    resolvers.add(new MatrixVariableMapMethodArgumentResolver());
    resolvers.add(new ServletModelAttributeMethodProcessor(false));
    resolvers.add(new RequestResponseBodyMethodProcessor(getMessageConverters()));
    resolvers.add(new RequestPartMethodArgumentResolver(getMessageConverters()));
    resolvers.add(new RequestHeaderMethodArgumentResolver(getBeanFactory()));
    resolvers.add(new RequestHeaderMapMethodArgumentResolver());
    resolvers.add(new ServletCookieValueMethodArgumentResolver(getBeanFactory()));
    resolvers.add(new ExpressionValueMethodArgumentResolver(getBeanFactory()));

    // Type-based argument resolution
    resolvers.add(new ServletRequestMethodArgumentResolver());
    resolvers.add(new ServletResponseMethodArgumentResolver());
    resolvers.add(new HttpEntityMethodProcessor(getMessageConverters()));
    resolvers.add(new RedirectAttributesMethodArgumentResolver());
    resolvers.add(new ModelMethodProcessor());
    resolvers.add(new MapMethodProcessor());
    resolvers.add(new ErrorsMethodArgumentResolver());
    resolvers.add(new SessionStatusMethodArgumentResolver());
    resolvers.add(new UriComponentsBuilderMethodArgumentResolver());

    // Custom arguments
    if (getCustomArgumentResolvers() != null) {
        resolvers.addAll(getCustomArgumentResolvers());
    }

    // Catch-all
    resolvers.add(new RequestParamMethodArgumentResolver(getBeanFactory(), true));
    resolvers.add(new ServletModelAttributeMethodProcessor(true));

    return resolvers;
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:47,代码来源:UifRequestMappingHandlerAdapter.java


注:本文中的org.springframework.web.servlet.mvc.method.annotation.MatrixVariableMethodArgumentResolver类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。