Skip to main content

Automatic Binding

Learn Automatic Binding (Data Binding, Spring MVC) with worked examples, diagrams and interview questions. Free on JavaSchoolLab.

Fresher Notes Automatic binding is what Spring MVC does without extra code: any controller argument that is not a simple type or a special type is bound from the request as a model attribute. Implicit @ModelAttribute : save(UserForm form) works exactly like save(@ModelAttribute UserForm form) . Simple types (int, String, and so on) are treated as @RequestParam by default, with the parameter name taken from the argument name.

More lessons in Data Binding