hi.
please see the issue https://issues.apache.org/jira/browse/AXIS2-2246

For rpc/literal messages, we have to generate the wrapper elements. i.e we
have to generate an outer element with local part equals to operation name
and namespace equals to operation target name space. But the part accesser
element should not be namespace qualified.

When generating the code first we generate the Element in normal way.
Lets say we have an message as follows and we generated an element like this

<message name="requestMessage">
       <part name="part1" type="xs:string"/>
       <part name="part2" type="xs:int"/>
   </message>

  <xs:element name="echo">
               <xs:complexType>
                   <xs:sequence>
                       <xs:element name="part1" type="xs:string"/>
                       <xs:element name="part2" type="xs:int"/>
                   </xs:sequence>
               </xs:complexType>
           </xs:element>

After that
1. if there is no schema then create new schema and put the element.
        In this case, we can set the 'elementFormDefault="unqualified"' and
put both part1 and part2 to no namespace.
2. if there is an schema with the same target name space then add the
element to the existing schema.
        in this case, we have to add the generated element to existing
schema and  if the existing schema has elementFormDefault="qualified" then
the both part1 and part2 automatically assigned to the same target name as
the 'echo' element. (But this is totally wrong)

       Can someone please sudjest a solution for this? How can we make
part1 and part2 unqualified in latter case?


--
Amila Suriarachchi,
WSO2 Inc.

Reply via email to