users@jax-rpc.java.net

Re: naming conflict

From: Doug Kohlert <Doug.Kohlert_at_Sun.COM>
Date: Wed, 26 Jan 2005 08:14:26 -0800

Sels,

You can add a <namespaceMappingRegistry> to the config.xml file that you
pass to wscompile. This will allow you to map namespaces to
Java packages or vis versa. You can add as many <namespaceMapping>s as
you need in the <namespaceMapping>. The entry looks like:

<?xml version="1.0" encoding="UTF-8"?>
<configuration
xmlns="http://java.sun.com/xml/ns/jax-rpc/ri/config">
<wsdl location="test/src/stub_tie_generator_wsdl_test/header.wsdl"
packageName="stub_tie_generator_wsdl_test">
<namespaceMappingRegistry>
<namespaceMapping
namespace="http://soapinterop.org"
packageName="stub_tie_generator_wsdl_test.header"/>
</namespaceMappingRegistry>
</wsdl>
</configuration>

Sels Wannes wrote:

> I’m generating Ties based on wsdl (see attachment). The wsdl has 3 xsd
> schemas. When wscompiling I get the following error:
>
> the following naming conflicts occurred:
> com.xti.xml.CargoResponse_Type, com.xti.xml.InsuranceResponse_Type,
> com.xti.xml.OwnerResponse_Type, com.xti.xml.InsuranceRequest_Type,
> com.xti.xml.OwnerRequest_Type, com.xti.xml.CargoRequest_Type
>
> at
> com.sun.xml.rpc.processor.modeler.wsdl.WSDLModelerBase.buildModel(WSDLModelerBase.java:267)
>
> at
> com.sun.xml.rpc.processor.config.ModelInfo.buildModel(ModelInfo.java:88)
>
> at com.sun.xml.rpc.processor.Processor.runModeler(Processor.java:63)
>
> at com.sun.xml.rpc.tools.wscompile.CompileTool.run(CompileTool.java:714)
>
> The conflicts occurs because these types exist in different schemas
> with the same name. A possible solution would be to turn of data
> binding, however I could really use the bindings as the types will get
> more detailed over time.
>
> What I want to do now is to put the generated classes in separate
> packages, one for each schema. Can anyone please provide
> suggestions/guidelines on how to do this? I assume I will have to
> write my own WSDLModeler. Also I would like to know if this would be
> out of spec.
>
> Kind Regards,
>
> Wannes Sels
>
>------------------------------------------------------------------------
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: users-unsubscribe_at_jax-rpc.dev.java.net
>For additional commands, e-mail: users-help_at_jax-rpc.dev.java.net
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_jax-rpc.dev.java.net
For additional commands, e-mail: users-help_at_jax-rpc.dev.java.net