You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by "Edgardo Ibañez O." <ed...@gmail.com> on 2009/01/26 21:47:58 UTC

Parameter order vs parameter name problem

Hi All,

    I'am testing my service with the eclipse Web service Explorer and 
when put null arguments values, the service "shift" the parameter 
values. Example:

public int function(int param1, int param2, int param3){

}


Eclipse soap request:

<   <soapenv:Envelope 
xmlns:soapenv="*http://schemas.xmlsoap.org/soap/envelope/*" 
xmlns:q0="*http://example.net*" 
xmlns:xsd="*http://www.w3.org/2001/XMLSchema*" 
xmlns:xsi="*http://www.w3.org/2001/XMLSchema-instance*">
- <#>    <soapenv:Body>
- <#>    <q0:function>
          <q0:param1>valor1</q0:param1>
          <q0:param3>valor2</q0:param3>

  </q0:function>
  </soapenv:Body>
  </soapenv:Envelope>

With this soap request I get in the function:

param1 = valor1
param2= valor3
param3=null

How I fix this for I will get:

param1 = valor1
param2= null
param3=valor3

Thanks.

Re: Parameter order vs parameter name problem

Posted by ibrahim demir <ib...@yahoo.com>.
Try to set the parameter3 as Integer.MIN_VALUE. 



 Ibrahim DEMIR
CyberSoft Yazilim Muh.
http://www.ibrahimdemir.org

     
           
     




________________________________
From: Edgardo Ibañez O. <ed...@gmail.com>
To: axis-user@ws.apache.org
Sent: Monday, January 26, 2009 10:47:58 PM
Subject: Parameter order vs parameter name problem

Hi All,

    I'am testing my service with the eclipse Web service Explorer and
when put null arguments values, the service "shift" the parameter
values. Example:

public int function(int param1, int param2, int param3){

}


Eclipse soap request:


<   <soapenv:Envelopexmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"xmlns:q0="http://example.net"xmlns:xsd="http://www.w3.org/2001/XMLSchema"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
-    <soapenv:Body>
-    <q0:function>
          <q0:param1>valor1</q0:param1> 
          <q0:param3>valor2</q0:param3> 

  </q0:function>
  </soapenv:Body>
  </soapenv:Envelope>
With this soap request I get in the function:

param1 = valor1 
param2= valor3
param3=null

How I fix this for I will get:

param1 = valor1 
param2= null
param3=valor3

Thanks.