Announcement Announcement Module
Collapse
No announcement yet.
Apply a WebBindingInitializer for some controller Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Apply a WebBindingInitializer for some controller

    The petclinic sample in the 2.5.x version shows how to apply a WebBindingInitializer for all controllers with the @Controller annotation. How to applying a specific PropertyEditors for request parameter binding for some controllers but not all with the @Controller annotation?

    Thanks in advance for your inputs.

  • #2
    In those @Controllers create a method annotated with @InitBinder (chapter 13 of the reference guide explains this).

    Comment


    • #3
      Originally posted by Marten Deinum View Post
      In those @Controllers create a method annotated with @InitBinder (chapter 13 of the reference guide explains this).
      I know that @InitBinder can be defined in a controller class. My thought was to configure in a single place and apply to several classes. If the approach is not doable, an abstract controller class with @InitBinder defined is a solution then.

      Comment

      Working...
      X