Announcement Announcement Module
Collapse
No announcement yet.
global property editor registration Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • global property editor registration

    is there any way to globally register common property editors, for all controllers? other way then creating base controller classes?

  • #2
    You can also register a customEditor at the applicationContext level by following the description there :
    http://www.springframework.org/docs/...-customeditors
    However, I'm not sure at 100% it gets propagated to the servlet property editors.
    Have a try.

    Olivier

    Comment


    • #3
      it doesn't

      Comment


      • #4
        ok, sorry
        Still, instead of inheriting from a common controller, I suggest to have delegation and actually have an utility class with a static initBinder method which actually add your custom editors. This way, you're free to use inheritance for other purpose than a mere factorisation of property editor registration.
        Actually, the auto registration of propertyEditor from applicationContext to controller could be an interesting feature.

        Olivier

        Comment

        Working...
        X