Skip to main content

Mini Project: Data Binding: Converters, Formatters and Safe Fields

Learn Mini Project: Data Binding: Converters, Formatters and Safe Fields (Data Binding, Spring MVC) with worked examples, diagrams and interview questions. Free on JavaSchoolLab.

Mini Real-Time Project: Data Binding: Converters, Formatters and Safe Fields Problem Request parameters are text. The framework must turn them into numbers, dates, money objects and nested objects, trim blanks, and must not let a user set fields that should be private (mass assignment). Requirements Bind nested properties (address.city) and indexed lists (items[0].name). Add a custom Converter from text like "INR 250" to a Money object. Trim strings and turn blank into null with an @InitBinder. Block a dangerous field (isAdmin) with allowed fields. Concepts Used WebDataBinder @InitBinder...

More lessons in Data Binding