I reading spring 3.0.x reference but I don't know how to use ,can you paste a full example?
A:
If you do a search for
spring @ResponseBody lang:java
and
in Google Code Search, you can see numerous usages of @ResponseBody
and @RequestBody
there that might help you understand it better.
Bytecode Ninja
2010-08-03 11:46:24
+1
A:
Use @ResponseBody if you want to return the content directy whitout any JSPs.
@RequestMapping("blubber")
@ResponseBody
public String blubber() {
return "<html><body>Hello World</body></html>
}
Ralph
2010-08-03 12:18:47