title: Spring MVC Controllers Return Type
body: <p>I've seen examples where a controller returns a String (which indicates the view)</p>
  
  <pre><code>@RequestMapping(value="/owners/{ownerId}", method=RequestMethod.GET)
  public String findOwner(@PathVariable String ownerId, Model model) {
    Owner owner = ownerService.findOwner(ownerId);  
    model.addAttribute("owner", owner);  
    return "displayOwner"
  }
  </code></pre>
  
  <p>And I also see examples where a controller returns a "ModelAndView" object type</p>
  
  <pre><code>public ModelAndView helloWorld() {
      ModelAndView mav = new ModelAndView();
      mav.setViewName("helloWorld");
      mav.addObject("message", "Hello World!");
      return mav;
  }
  </code></pre>
  
  <p>What is the difference between the two and which should I use? Cause either way I can get my view resolved.</p>