[
https://issues.apache.org/jira/browse/MUSE-214?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12482854
]
Jose Antonio commented on MUSE-214:
-----------------------------------
Also there's a problem with how methods are generated in the stub. I have the
following operations:
<wsdl:message name="CompletedMessage">
<wsdl:part element="wsctx:completed" name="content"/>
</wsdl:message>
<wsdl:operation name="completed">
<wsdl:input
wsa:Action="http://docs.oasis-open.org/schemas/2005/10/wsctx/completed"
message="tns:CompletedMessage"/>
</wsdl:operation>
and
<wsdl:message name="CompensatorCompletedMessage">
<wsdl:part name="content" element="lra:completed"/>
</wsdl:message>
<wsdl:operation name="CompensatorCompleted">
<wsdl:input
wsa:Action="http://www.webservicestransactions.org/schemas/wstxm/tx-lra/2003/03/completed"
message="tns:CompensatorCompletedMessage"/>
</wsdl:operation>
They both map to the completed() operation but there's no problem in the server
as both elements (lra:completed and wsctx:completed) are in different
namespaces and so, they are generated in different capabilities. The problem is
with the stub, as all operations goes to the same class, both of them are
called completed() and so, there is a collision. I had to change the name by
hand. Using the wsdl:operation name for method names is a better way to deal
with this, as they are in the same namespace and they must be different.
> XML element name could lead to invalid operation generation.
> ------------------------------------------------------------
>
> Key: MUSE-214
> URL: https://issues.apache.org/jira/browse/MUSE-214
> Project: Muse
> Issue Type: Bug
> Components: Tooling - Code Generation
> Affects Versions: 2.2.0
> Environment: Ubuntu Edgy 6.10, JDK 1.5.0
> Reporter: Jose Antonio
> Assigned To: Dan Jemiolo
> Priority: Minor
> Fix For: 2.3.0
>
>
> Some valid elements named as <element name="this-is-valid"> could lead to the
> generation of invalid function names like
> public void this-is-valid() throws Exception
> Which is not a valid java function name. When dealing with such names, upper
> dashes should be substituted with lower dashes so it generates a valid name:
> public void this_is_valid()
> I've found this while dealing with a wsdl that I have no control over it, so
> I cannot change the element's format because it's from a server that's
> deployed and is going to invoke me with that message.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]