SpringMVC 返回数据(持续更新)

来源:互联网 发布:dede淘宝客api采集 编辑:程序博客网 时间:2024/05/22 10:29

spring mvc处理方法支持如下的返回方式:ModelAndView, Model, ModelMap, Map,View, String, void。
下面将对具体的一一进行说明:
ModelAndView
Spring Description:Holder for both Model and View in the web MVC framework. Note that these are entirely distinct. This class merely holds both to make it possible for a controller to return both model and view in a single return value.
Constructors:默认构造器 ModelAndView();ModelAndView(String viewName);ModelAndView(String viewName, Map

原创粉丝点击