Re: problem with String [] in axis 1.3 and .net client

2008-10-14 Thread jayalal jayarathna
This is the C# request which is not working,


http://schemas.xmlsoap.org/soap/envelope/";
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"; xmlns:tns="
http://external.soap.service.cps.moota.com"; xmlns:types="
http://external.soap.service.cps.moota.com/encodedTypes"; xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"; xmlns:xsd="
http://www.w3.org/2001/XMLSchema";>
http://schemas.xmlsoap.org/soap/encoding/";>

   
 http://dto.service.cps.moota.com";>
   
   
   
   
   
   
   
   
   

   
  123456

  



but for following Axis 1.3 client request it works fine

http://schemas.xmlsoap.org/soap/envelope/"; xmlns:xsd="
http://www.w3.org/2001/XMLSchema"; xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance";>
 http://schemas.xmlsoap.org/soap/encoding/"; xmlns:ns1="
http://soap.service.cps.moota.com";>
 
 
  http://schemas.xmlsoap.org/soap/encoding/"; xsi:type="ns2:SmsRequestDto"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"; xmlns:ns2="
http://dto.service.cps.moota.com";>
  
  
  
  
 http://webservice.clientprovisioning.moota.com";>123456789
  
  
   
   
   
   
   

   http://schemas.xmlsoap.org/soap/encoding/"; xsi:type="xsd:long"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/";>
   10
   






http://schemas.xmlsoap.org/soap/envelope/";
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"; xmlns:tns="
http://external.soap.service.cps.moota.com"; xmlns:types="
http://external.soap.service.cps.moota.com/encodedTypes"; xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"; xmlns:xsd="
http://www.w3.org/2001/XMLSchema";>http://schemas.xmlsoap.org/soap/encoding/";>
http://dto.service.cps.moota.com";>123456






http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance";>

soapenv:Server.userException
java.lang.IllegalArgumentException: array element type
mismatch
http://xml.apache.org/axis/
">jayalal-PC


2008/10/13 Deepal Jayasinghe <[EMAIL PROTECTED]>

> Did you check whether it sends the correct request , I mean is it valid
> according to the WSDL ?
> You can see the message if you send that via TCP Monitor.
>
> -Deepal
>
> jayalal jayarathna wrote:
> > Hi,
> > I have a web service developed on Axis 1.3, and it has following method.
> > SendTaskResponseDto sendSmsMessage(SmsRequestDto in0)
> >
> > SmsRequestDto has an string array
> >
> > public class SmsRequestDto implements java.io.Serializable {
> > private java.lang.Long projectId;
> >
> > private java.lang.String user;
> >
> > private java.lang.String message;
> >
> > private java.lang.String[] msisdn;
> >
> > private java.lang.Integer applicationId;
> >
> > .
> >
> >
> > when I try to call SendTaskResponseDto sendSmsMessage(SmsRequestDto
> > in0) through C#.net client it gives following exception at server
> >
> > 13 Oct 2008 11:03:00,015 ERROR BeanPropertyTarget - Could not convert
> > [Ljava.lang.String; to bean field 'msisdn[0]', type java.lang.String
> > 13 Oct 2008 11:03:00,028 INFO EXCEPTIONS - AxisFault:
> > AxisFault
> > faultCode:
> > {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
> > 
> > faultSubcode:
> > faultString: java.lang.IllegalArgumentException: array element type
> > mismatch
> > faultActor:
> > faultNode:
> > faultDetail:
> > {
> http://xml.apache.org/axis/}stackTrace:java.lang.IllegalArgumentException
> > <
> http://xml.apache.org/axis/%7DstackTrace:java.lang.IllegalArgumentException
> >:
> > array element type mismatch
> > at java.lang.reflect.Array.set(Native Method)
> > at
> >
> org.apache.axis.utils.BeanPropertyDescriptor.set(BeanPropertyDescriptor.java:195)
> >
> >
> >
> >
> >
> >
> > WSDL as follows
> >
> > http://schemas.xmlsoap.org/soap/encoding/"/>
> > −
> > 
> > −
> > 
> > −
> > 
> > 
> > 
> > 
> > 
> >
> >
> > 
> > 
> > 
> > 
> > 
> >  > type="impl:ArrayOf_soapenc_string"/>
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> >
> >
> > c# code
> > static void Main(string[] args)
> > {
> > lh.CPSWebServiceService service = new
> > ConsoleApplication1.lh.CPSWebServiceService();
> > lh.SmsRequestDto request = new ConsoleApplication1.lh.SmsRequestDto();
> > string[] msisdn = new string[1];
> > msisdn[0] = "123456";
> > // msisdn[1] = "456";
> > request.msisdn = msisdn;
> > service.sendSmsMessage(request);
> >
> > }
> >
> >
> >
> > Please help me. Thank you,
> >
> > Jayalal
>
> --
> Thank you!
>
>
> http://blogs.deepal.org
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: problem with String [] in axis 1.3 and .net client

2008-10-13 Thread Deepal Jayasinghe
Did you check whether it sends the correct request , I mean is it valid
according to the WSDL ?
You can see the message if you send that via TCP Monitor.

-Deepal

jayalal jayarathna wrote:
> Hi,
> I have a web service developed on Axis 1.3, and it has following method.
> SendTaskResponseDto sendSmsMessage(SmsRequestDto in0)
>
> SmsRequestDto has an string array
>
> public class SmsRequestDto implements java.io.Serializable {
> private java.lang.Long projectId;
>
> private java.lang.String user;
>
> private java.lang.String message;
>
> private java.lang.String[] msisdn;
>
> private java.lang.Integer applicationId;
>
> .
>
>
> when I try to call SendTaskResponseDto sendSmsMessage(SmsRequestDto
> in0) through C#.net client it gives following exception at server
>
> 13 Oct 2008 11:03:00,015 ERROR BeanPropertyTarget - Could not convert
> [Ljava.lang.String; to bean field 'msisdn[0]', type java.lang.String
> 13 Oct 2008 11:03:00,028 INFO EXCEPTIONS - AxisFault:
> AxisFault
> faultCode:
> {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
> 
> faultSubcode:
> faultString: java.lang.IllegalArgumentException: array element type
> mismatch
> faultActor:
> faultNode:
> faultDetail:
> {http://xml.apache.org/axis/}stackTrace:java.lang.IllegalArgumentException
> :
> array element type mismatch
> at java.lang.reflect.Array.set(Native Method)
> at
> org.apache.axis.utils.BeanPropertyDescriptor.set(BeanPropertyDescriptor.java:195)
>
>
>
>
>
>
> WSDL as follows
>
> http://schemas.xmlsoap.org/soap/encoding/"/>
> −
> 
> −
> 
> −
> 
> 
> 
> 
> 
>
>
> 
> 
> 
> 
> 
>  type="impl:ArrayOf_soapenc_string"/>
> 
> 
> 
> 
> 
> 
> 
>
>
> c# code
> static void Main(string[] args)
> {
> lh.CPSWebServiceService service = new
> ConsoleApplication1.lh.CPSWebServiceService();
> lh.SmsRequestDto request = new ConsoleApplication1.lh.SmsRequestDto();
> string[] msisdn = new string[1];
> msisdn[0] = "123456";
> // msisdn[1] = "456";
> request.msisdn = msisdn;
> service.sendSmsMessage(request);
>
> }
>
>
>
> Please help me. Thank you,
>
> Jayalal

-- 
Thank you!


http://blogs.deepal.org


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



problem with String [] in axis 1.3 and .net client

2008-10-13 Thread jayalal jayarathna
Hi,
I have a web service developed on Axis 1.3, and it has following method.
SendTaskResponseDto sendSmsMessage(SmsRequestDto in0)

SmsRequestDto has an string array

public class SmsRequestDto  implements java.io.Serializable {
private java.lang.Long projectId;

private java.lang.String user;

private java.lang.String message;

private java.lang.String[] msisdn;

private java.lang.Integer applicationId;

.


when I try to call SendTaskResponseDto sendSmsMessage(SmsRequestDto in0)
through C#.net client it gives following exception at server

13 Oct 2008 11:03:00,015 ERROR BeanPropertyTarget - Could not convert
[Ljava.lang.String; to bean field 'msisdn[0]', type java.lang.String
13 Oct 2008 11:03:00,028 INFO  EXCEPTIONS - AxisFault:
AxisFault
 faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
 faultSubcode:
 faultString: java.lang.IllegalArgumentException: array element type
mismatch
 faultActor:
 faultNode:
 faultDetail:
{
http://xml.apache.org/axis/}stackTrace:java.lang.IllegalArgumentException:
array element type mismatch
at java.lang.reflect.Array.set(Native Method)
at
org.apache.axis.utils.BeanPropertyDescriptor.set(BeanPropertyDescriptor.java:195)






WSDL as follows

http://schemas.xmlsoap.org/soap/encoding/"/>
−

−

−






















c# code
static void Main(string[] args)
{
lh.CPSWebServiceService service = new
ConsoleApplication1.lh.CPSWebServiceService();
lh.SmsRequestDto request = new
ConsoleApplication1.lh.SmsRequestDto();
string[] msisdn = new string[1];
msisdn[0] = "123456";
   // msisdn[1] = "456";
request.msisdn = msisdn;
service.sendSmsMessage(request);

}



Please help me. Thank you,

Jayalal