Code example for ModelAndView

Methods: addAllObjectssetViewsetViewName

1
					return null; 
				} 
			} 
		} 
 
		ModelAndView modelAndView = new ModelAndView(); 
		modelAndView.addAllObjects(RequestContextUtils.getInputFlashMap(request)); 
 
		if (getViewName() != null) { 
			modelAndView.setViewName(viewName); 
		} 
		else { 
			modelAndView.setView(getView()); 
		} 
 
		return (isStatusOnly() ? null : modelAndView); 
	} 
 
}