0 Replies Latest reply on Oct 22, 2008 8:31 AM by mpelze

    custom java type mapping in WS in JBoss

    mpelze

      Hello,

      is it possible to customize the JAXB mapping Jboss uses when deserializing an incoming SOAP message for a web service or serializing an outgoing message?

      My problem is that I want to send and receive maps containing lists over a web service (implemented as EJB stateless session bean annotated as @WebService) in JBoss. JBoss uses jax-ws for web services and jax-ws uses jaxb for mapping Java classes to XML structures. Jaxb is not able to handle maps containing lists, so I have to define a custom mapping providing custom serializers / deserializers. I found out that there is the possibility in jaxb to write a configuration file for custom mappings that can look like this:

      <bindings xmlns="http://java.sun.com/xml/ns/jaxb" version="2.0" xmlns:xs="http://www.w3.org/2001/XMLSchema">
       <globalBindings>
       <javaType name="my.package.MyClas" xmlType="xs:someName"
       parseMethod="my.package.MyParser.parse"
       printMethod="my.package.MyParser.print"
       />
       </globalBindings>
      </bindings>


      Ist there a possibility to provide such a file to JBoss so that it will be used when (de-)serializing SOAP messages for or from my web services?