Specify a package instead of “classesToBeBound” for spring Jaxb2Marshaller

前端 未结 3 517
深忆病人
深忆病人 2021-02-13 13:21

I am trying to use Jaxb2Marshaller to marshal a set of java classes using spring. I know this can be done using the following code



        
3条回答
  •  余生分开走
    2021-02-13 14:09

    If you are using the new version of JAXB then you can use something like this in your application context if you add the oxm namespace to your xml file.

    
    
      
      
    
    

    I have a production level program running with these, so let me know if you have any more questions.

    Good Luck.

提交回复
热议问题