Guys,
I am having issues to retrieve the output
parameters(ParameterMode.OUT/ParameterMode.INOUT) after calling invoke
().
Appreciate if anyone can tell me what I am doing wrong or point me to a
sample code.
Thanks a ton,
Venu.
My code looks as follows:
Service service = new Service();
Call perCall = (Call) service.createCall();
QName personqn = new QName( "urn:DBInsertService", "Person"
);
perCall.registerTypeMapping(Person.class, personqn,
new
org.apache.axis.encoding.ser.BeanSerializerFactory(Person.class, personqn),
new
org.apache.axis.encoding.ser.BeanDeserializerFactory(Person.class,
personqn));
perCall.setTargetEndpointAddress( new java.net.URL(endpoint) );
perCall.setOperationName( new QName("DBInsertService", "insertPerson"
) );
perCall.addParameter( "person", personqn, ParameterMode.IN );
perCall.addParameter( "serviceTimes", XMLType.XSD_STRING,
ParameterMode.OUT );
perCall.setReturnType( XMLType.XSD_BOOLEAN ); // set
return type
Person dbP = new Person();
String str = null; // also tried with new, the result was that
there was no value.
// This method sets the result to str;
boolean l_result = ((Boolean)perCall.invoke(new Object[] {dbP,
str})).booleanValue();
System.out.println("Output: " + str); // this line showed up str as
null.
_____________________________________________________
SIEMENS Medical Solutions - Health Services
Venu Ambekar
Software Engineer, DC6 - Architecture
51 Valley Stream Parkway, Malvern, PA, 19355-1406
Phone: +01 610 219 7982
Fax: +01 610 219 8470
E-Mail: [EMAIL PROTECTED]
_______________________________________________________
-------------------------------------------------------------------------------
This message and any included attachments are from Siemens Medical Solutions
USA, Inc. and are intended only for the addressee(s).
The information contained herein may include trade secrets or privileged or
otherwise confidential information. Unauthorized review, forwarding, printing,
copying, distributing, or using such information is strictly prohibited and may
be unlawful. If you received this message in error, or have reason to believe
you are not authorized to receive it, please promptly delete this message and
notify the sender by e-mail with a copy to [EMAIL PROTECTED] Thank you