Code example for ModelAndView

Methods: getModel

0
 
  @RequestMapping("/about") 
  public ModelAndView serverInfo() {
    List<User> moderators = userDao.getModerators();
 
    ModelAndView mv = new ModelAndView("server");
    mv.getModel().put("moderators", moderators);
 
    List<User> correctors = userDao.getCorrectors();
 
    mv.getModel().put("correctors", correctors);
 
    return mv;
  } 
} 
Connect your IDE to all the code out there  Get Codota for Java