What is the purpose and usage of @ModelAttribute
in Spring MVC?
For my style, I always use @ModelAttribute to catch object from spring form jsp. for example, I design form on jsp page, that form exist with commandName
and I catch the object on controller with follow code
public String controllerPost(@ModelAttribute("Book") Book book)
and every field name of book must be match with path in sub-element of form