Hi. If its the old Axis 1.4, then I can't be of much help. A few thoughts;
1. The stub contains the classes you need to use in your client. I don't think its meant to be modified.
qName = new javax.xml.namespace.QName("urn:PosadasMailSender", "ArrayOf_xsd_string");
2. I don't know if the above is valid, but I am not sure.
For this type:
<complexType name="RequestMailVO">
<sequence>
<element name="attachmentByte" nillable="true" type="xsd:string"/>
<element name="attachmentName" nillable="true" type="xsd:string"/>
<element name="code" nillable="true" type="xsd:string"/>
<element name="datosPlantillas" nillable="true" type="apachesoap:Map"/>
<element name="idioma" nillable="true" type="xsd:string"/>
<element name="mailFormat" type="xsd:int"/>
<element name="to" nillable="true" type="impl:ArrayOf_xsd_string"/>
</sequence>
</complexType>
RequestMailVO mail = new RequestMailVO();
final String[] policies=new String[]{"POLICY1","POLICY2"};
******************Why are you doing this:*******************
mail.setDatosPlantillas((HashMap)mapping);
*****************Instead of:**********************
mail.setTo(new ArrayOf_xsd_string().set(policies)) or something like that
3. In the above example you have shown, per the wsdl, in RequestMailVO:
-- to is of type ArrayOf_xsd_string
-- datosPlantillas is of type Map.
So then why are you adding the string array to datosPlantillas? Maybe I am missing something. Shouldn't the string array be added to the "to" property?
Can you try this approach:
- use the generated stub
- in the stub, take a look at the public inner classes that can be accessed from your client code
- For a service called "Your", you should be able to say something like this:
yourUrl = "http://yoururl/";
QName myQname = new QName("http://yournamespaceurl/", "YourService");
YourService service = new YourService(yourUrl, myQname);
binding = service.getYourPort();
RequestMailVO mail = new RequestMailVO();
final String[] policies=new String[]{"POLICY1","POLICY2"};
mail.setTo(policies in string array type)
mail.set other values also
binding.sendMail(mail);
Best of luck! Please do post your solution once you have it.