JAXB External Custom Binding XJC Issue - Parsing results in empty node

后端 未结 2 849
不知归路
不知归路 2020-12-09 21:32

Forgive me if this is a duplicate. Here is my binding.xjb file. But now i am getting the regular error that the complex type target \"AddBankVaultRplyType\" is not found. I

2条回答
  •  孤城傲影
    2020-12-09 21:45

    I finally got mine workign with subclassing as well as adding @XmlRootElement to those dang complexTypes that are used by a root element(I don't get why JAXB doesn't add it for me, but this does the trick of doing that since JAXB doesn't)

    
    
    
      
        
        
        
        
        
        
      
    
    
    
      
    
      
      
        
            
        
    
      
    
      
        
            
        
    
        
          
            
          
        
      
    
      
        
            
        
    
        
    
    
    

    Of course I struggled with the pom.xml alot but finally came to this solution which worked for me.

            
                org.jvnet.jaxb2.maven2
                maven-jaxb2-plugin
                0.8.1
                
                    
                        process-xsd
                        
                            generate
                        
                        generate-sources
                        
                            
                                schemas/*.xsd
                            
                            
                                schemas/*.xjb.xml
                            
                            ${project.build.directory}/generated-sources
                            true
                            
                                -Xannotate
                            
                            
                                
                                    org.jvnet.jaxb2_commons
                                    jaxb2-basics-annotate
                                    0.6.3
                                
                                
                                    org.jvnet.jaxb2_commons
                                    jaxb2-basics
                                    0.6.3
                                                               
                            
                        
                    
                
                       
    

    later, Dean

提交回复
热议问题