Spring ConversionService adding Converters

后端 未结 9 798
别那么骄傲
别那么骄傲 2020-12-31 03:47

I searched for the below problem, but couldn\'t find an answer.

I want to use spring\'s conversion service by writing my custom converter that implements org.spri

9条回答
  •  梦谈多话
    2020-12-31 04:34

    For anyone who stumbles on this now via a google search or similar 2+ years after the question was originally posted, adding converters has been made much easier through Java Config: WebMvcConfigurerAdapter provides the addFormatters(FormatterRegistry) method that can be used to specify additional custom converters.

提交回复
热议问题