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 Pedro Alves <pe...@neraka.no-ip.org> on 2006/03/09 19:52:26 UTC

Re: in Arrays - -


    Hum... I dunno about that. But that is the output I'm getting. Apparently
axis is beeing smart and realizing that I dont need 2 objects for that --
and he is right, he doesnt even creates a ArrayHB24ILISTA1Stub.java -- but
I really need him to be dumb :)

On Thu, Mar 09, 2006 at 12:54:23PM -0600, Kiran Kumar wrote:
> Hi,
> 
> In the generated output, <LISTA1> element is pointing to "ArrayHB24ILISTA1", it is supposed to point "ArrayHB24ILISTA1Stub". 
> 
>         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">         =====> supposed to be "ArrayHB24ILISTA1Stub"..        
>           <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>           <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>         </LISTA1>
> 
> Kiran
>  
> On Wed, Mar 08, 2006 at 09:39:07AM -0600, Kiran Kumar wrote:
> > Hi,
> > 
> > As per the definition of type'ArrayHB24ILISTA1' is not 'Array'.. You have to define array of your complex type (ArrayHB24ILISTA1).. It would be something like this :
> > 
> > 	<xsd:complexType name="LISTA1Type">
> > 		<xsd:sequence>
> > 			<xsd:element name="item" type="transactionHB24:ArrayHB24ILISTA1" maxOccurs="unbounded"/>
> > 		</xsd:sequence>
> > 	</xsd:complexType>
> > 
> >        <xsd:element name="LISTA1" type="LISTA1Type" />
> > 
> > 
> > Name of the your complex type (ArrayHB24ILISTA1) is confusing..Its not an array.. its just a complex type.
> > 
> 
> Reopening this subject:
> 
> I followed your suggestion. My wsdl now reads:
> 
>       <complexType name="ArrayHB24ILISTA1Stub">
>         <sequence>
>           <element name="item" nillable="true" maxOccurs="unbounded" type="transactionHB24:ArrayHB24ILISTA1" />
>         </sequence>
>       </complexType>
>       <complexType name="RequestBeanHB24">
>         <sequence>
>           <element name="cancelTrxId" nillable="true" type="string" />
>           <element name="LISTA1" nillable="true" type="transactionHB24:ArrayHB24ILISTA1Stub" />
>         </sequence>
>       </complexType>
> 
> But the output is still:
> 
>       <arg0 xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" xsi:type="ns2:RequestBeanHB24">
>         <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
>         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
>           <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>           <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>         </LISTA1>
>         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
>           <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>           <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>         </LISTA1>
>         <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
>         <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
>       </arg0>
> 
> 
> The other side (a desperately outdated weblogic...) requires a form like:
> 
>       <arg0 xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" xsi:type="ns2:RequestBeanHB24">
>         <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
>         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1[2]">
>             <item xsi:type="ns2:ArrayHB24ILISTA1">
>               <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>               <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>             </item>
>             <item xsi:type="ns2:ArrayHB24ILISTA1">
>               <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>               <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>             </item>
>         </LISTA1>
>         <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
>         <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
>       </arg0>
> 
> 
> How can I force axis to send the request in this form? (even if I have to
> change the wsdl).
> 
> Thanks
> 
> -- 
> Pedro Alves
> pedro.alves@zmail.pt
> 
> 
> ------------------------------------------------
> 
> This e-mail, and any attachments thereto, is confidential and is intended only for the individual(s) named.  If you are not the intended recipient, please let us know by e-mail reply and delete it from your system; do not copy/save this e-mail or disclose its contents to anyone.  E-mail transmissions cannot be guaranteed to be secure or error-free as the transmission could be interrupted, corrupted, lost, destroyed, altered, arrive late or contain viruses.  ObjectWave does not accept liability for any errors or omissions in the contents of this e-mail which arise as a result of e-mail transmission.  The views expressed in this e-mail do not necessarily reflect those of ObjectWave or its affiliates.
> 
> ------------------------------------------------
> 
> 



-- 
Pedro Alves
pedro.alves@zmail.pt

Re: in Arrays - -

Posted by robert <ro...@gmail.com>.
The nowrapped option in the 1.3 ant task looks like: 

<target name="wsdl2java">
       <delete dir="output" />
       <mkdir dir="output" />
       <axis-wsdl2java
         output="output"
         verbose="true"
         url="wsdl/simple.wsdl"
         serverside="true"
         skeletondeploy="true"
         nowrapped="true"
         >
       </axis-wsdl2java>
   </target>

HTH,
Robert 
http://www.braziloutsource.com/


Em Sexta 10 Março 2006 08:32, o Dies Koper escreveu:
> I've never tried from ant but I suppose you'd need to change
> wrapArrays="no" to wrapArrays="true" and take out noWrapped="true".
>
> -wrapArrays is a new option, since Axis 1.3, and maybe it wasn't
> implemented into the ant task (few people need it anyway).
>
> If the above doesn't work, you'd either have to use ant's "exec" task,
> or supply a patch yourself.
>
> Good luck,
> Dies
>
> Pedro Alves wrote:
> > Hum... How do I pass that option into the ant task? Found nothing in the
> > documentation.
> >
> > However, I search in the sources for examples and I used this:
> >
> >         <wsdl2java url="${filename}"
> >             output="${build.stubs}"
> >             deployscope="session"
> >             serverSide="no"
> >             noimports="no"
> >             skeletonDeploy="no"
> >             verbose="no"
> >             typeMappingVersion="1.1"
> >             testcase="no"
> >             noWrapped="true"
> >             wrapArrays="no"
> >
> >
> > However, I cant find any differences... it generates the same thing. (at
> > least, if I got it right, it should generate the stubs without the need
> > for me to make the changes in wsdl).
> >
> > I'm using axis 1.3
> >
> >
> > Thanks
> >
> > On Fri, Mar 10, 2006 at 11:11:59AM +0900, Dies Koper wrote:
> >> Hello Pedro,
> >>
> >> I didn't think it would affect your SOAP message but if you just want
> >> the ArrayHB24ILISTA1Stub class with a definition as the following to be
> >> generated, use the -wrapArrays option (by default Axis "unwraps" the
> >> complexType).
> >>
> >> <complexType name="ArrayHB24ILISTA1Stub">
> >>   <sequence>
> >>     <element name="item" nillable="true" maxOccurs="unbounded"
> >> type="transactionHB24:ArrayHB24ILISTA1" />
> >>   </sequence>
> >> </complexType>
> >>
> >> Regards,
> >> Dies
> >>
> >> Pedro Alves wrote:
> >>> I found a way to force the "<item>" to be sent, but I dont think it
> >>> will work, since the namespace is different. Adding an element "test",
> >>> it forces axis to build the Stub object:
> >>>
> >>> <complexType name="ArrayHB24ILISTA1Stub">
> >>>  <sequence>
> >>>    <element name="item" nillable="true" maxOccurs="unbounded"
> >>>    type="transactionHB24:ArrayHB24ILISTA1" />
> >>>    <element name="TEST" minOccurs="0" type="string"/>
> >>>  </sequence>
> >>> </complexType>
> >>> <complexType name="RequestBeanHB24">
> >>>  <sequence>
> >>>    <element name="cancelTrxId" nillable="true" type="string" />
> >>>    <element name="LISTA1" nillable="true"
> >>>    type="transactionHB24:ArrayHB24ILISTA1Stub" />
> >>>  </sequence>
> >>> </complexType>
> >>>
> >>> , and the output is:
> >>>
> >>> <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1Stub">
> >>>  <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>    <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>    <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>  </item>
> >>>  <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>    <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>    <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>  </item>
> >>>  <TEST xsi:type="xsd:string" xsi:nil="true"/>
> >>> </LISTA1>
> >>>
> >>> However, I'm almost sure that the server will complain about that
> >>> unknown ArrayHB24ILISTA1Stub (since I changed the wsdl but only at
> >>> client side). Will test it and say if it works
> >>>
> >>> []
> >>>
> >>> Pedro
> >>>
> >>> On Thu, Mar 09, 2006 at 06:52:26PM +0000, Pedro Alves wrote:
> >>>>    Hum... I dunno about that. But that is the output I'm getting.
> >>>>    Apparently
> >>>> axis is beeing smart and realizing that I dont need 2 objects for that
> >>>> -- and he is right, he doesnt even creates a ArrayHB24ILISTA1Stub.java
> >>>> -- but I really need him to be dumb :)
> >>>>
> >>>> On Thu, Mar 09, 2006 at 12:54:23PM -0600, Kiran Kumar wrote:
> >>>>> Hi,
> >>>>>
> >>>>> In the generated output, <LISTA1> element is pointing to
> >>>>> "ArrayHB24ILISTA1", it is supposed to point "ArrayHB24ILISTA1Stub".
> >>>>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">         =====>
> >>>>> supposed to be "ArrayHB24ILISTA1Stub"..        <ACCAO
> >>>>>          xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>          <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>        </LISTA1>
> >>>>>
> >>>>> Kiran
> >>>>>
> >>>>> On Wed, Mar 08, 2006 at 09:39:07AM -0600, Kiran Kumar wrote:
> >>>>>> Hi,
> >>>>>>
> >>>>>> As per the definition of type'ArrayHB24ILISTA1' is not 'Array'.. You
> >>>>>> have to define array of your complex type (ArrayHB24ILISTA1).. It
> >>>>>> would be something like this :
> >>>>>>
> >>>>>> 	<xsd:complexType name="LISTA1Type">
> >>>>>> 		<xsd:sequence>
> >>>>>> 			<xsd:element name="item"
> >>>>>> 			type="transactionHB24:ArrayHB24ILISTA1"
> >>>>>> 			maxOccurs="unbounded"/>
> >>>>>> 		</xsd:sequence>
> >>>>>> 	</xsd:complexType>
> >>>>>>
> >>>>>>       <xsd:element name="LISTA1" type="LISTA1Type" />
> >>>>>>
> >>>>>>
> >>>>>> Name of the your complex type (ArrayHB24ILISTA1) is confusing..Its
> >>>>>> not an array.. its just a complex type.
> >>>>>
> >>>>> Reopening this subject:
> >>>>>
> >>>>> I followed your suggestion. My wsdl now reads:
> >>>>>
> >>>>>      <complexType name="ArrayHB24ILISTA1Stub">
> >>>>>        <sequence>
> >>>>>          <element name="item" nillable="true" maxOccurs="unbounded"
> >>>>>          type="transactionHB24:ArrayHB24ILISTA1" />
> >>>>>        </sequence>
> >>>>>      </complexType>
> >>>>>      <complexType name="RequestBeanHB24">
> >>>>>        <sequence>
> >>>>>          <element name="cancelTrxId" nillable="true" type="string" />
> >>>>>          <element name="LISTA1" nillable="true"
> >>>>>          type="transactionHB24:ArrayHB24ILISTA1Stub" />
> >>>>>        </sequence>
> >>>>>      </complexType>
> >>>>>
> >>>>> But the output is still:
> >>>>>
> >>>>>      <arg0
> >>>>>      xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24"
> >>>>>      xsi:type="ns2:RequestBeanHB24">
> >>>>>        <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
> >>>>>          <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>          <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>        </LISTA1>
> >>>>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
> >>>>>          <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>          <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>        </LISTA1>
> >>>>>        <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>        <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>      </arg0>
> >>>>>
> >>>>>
> >>>>> The other side (a desperately outdated weblogic...) requires a form
> >>>>> like:
> >>>>>
> >>>>>      <arg0
> >>>>>      xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24"
> >>>>>      xsi:type="ns2:RequestBeanHB24">
> >>>>>        <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1[2]">
> >>>>>            <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>>>              <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>              <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>            </item>
> >>>>>            <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>>>              <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>              <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>            </item>
> >>>>>        </LISTA1>
> >>>>>        <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>        <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>      </arg0>
> >>>>>
> >>>>>
> >>>>> How can I force axis to send the request in this form? (even if I
> >>>>> have to change the wsdl).
> >>>>>
> >>>>> Thanks

-- 

Re: in Arrays - -

Posted by Pedro Alves <pe...@neraka.no-ip.org>.
I got it working, just like I needed, but with a different approach. Here
is the diff file regarding the original wsdl (for future reference):

3a4,10
>       <complexType name="MyArray">
>         <complexContent>
>           <restriction base="soap:Array">
>             <attribute ref="soap:arrayType" wsdl:arrayType="transactionHB24:ArrayHB24ILISTA1[]" />
>           </restriction>
>         </complexContent>
>       </complexType>
82c89
<           <element name="LISTA1" nillable="true" type="transactionHB24:ArrayHB24ILISTA1" maxOccurs="unbounded" />
---
>           <element name="LISTA1" nillable="true" type="transactionHB24:MyArray" />



Thanks


On Fri, Mar 10, 2006 at 08:32:54PM +0900, Dies Koper wrote:
> I've never tried from ant but I suppose you'd need to change 
> wrapArrays="no" to wrapArrays="true" and take out noWrapped="true".
> 
> -wrapArrays is a new option, since Axis 1.3, and maybe it wasn't 
> implemented into the ant task (few people need it anyway).
> 
> If the above doesn't work, you'd either have to use ant's "exec" task, 
> or supply a patch yourself.
> 
> Good luck,
> Dies
> 
> Pedro Alves wrote:
> >Hum... How do I pass that option into the ant task? Found nothing in the
> >documentation.
> >
> >However, I search in the sources for examples and I used this:
> >
> >        <wsdl2java url="${filename}"
> >            output="${build.stubs}"
> >            deployscope="session"
> >            serverSide="no"
> >            noimports="no"
> >            skeletonDeploy="no"
> >            verbose="no"
> >            typeMappingVersion="1.1"
> >            testcase="no"
> >            noWrapped="true"
> >            wrapArrays="no"
> >            >
> >
> >However, I cant find any differences... it generates the same thing. (at
> >least, if I got it right, it should generate the stubs without the need
> >for me to make the changes in wsdl).
> >
> >I'm using axis 1.3
> >
> >
> >Thanks
> >
> >On Fri, Mar 10, 2006 at 11:11:59AM +0900, Dies Koper wrote:
> >>Hello Pedro,
> >>
> >>I didn't think it would affect your SOAP message but if you just want 
> >>the ArrayHB24ILISTA1Stub class with a definition as the following to be 
> >>generated, use the -wrapArrays option (by default Axis "unwraps" the 
> >>complexType).
> >>
> >><complexType name="ArrayHB24ILISTA1Stub">
> >>  <sequence>
> >>    <element name="item" nillable="true" maxOccurs="unbounded" 
> >>type="transactionHB24:ArrayHB24ILISTA1" />
> >>  </sequence>
> >></complexType>
> >>
> >>Regards,
> >>Dies
> >>
> >>
> >>Pedro Alves wrote:
> >>>I found a way to force the "<item>" to be sent, but I dont think it will
> >>>work, since the namespace is different. Adding an element "test", it
> >>>forces axis to build the Stub object:
> >>>
> >>><complexType name="ArrayHB24ILISTA1Stub">
> >>> <sequence>
> >>>   <element name="item" nillable="true" maxOccurs="unbounded" 
> >>>   type="transactionHB24:ArrayHB24ILISTA1" />
> >>>   <element name="TEST" minOccurs="0" type="string"/>
> >>> </sequence>
> >>></complexType>
> >>><complexType name="RequestBeanHB24">
> >>> <sequence>
> >>>   <element name="cancelTrxId" nillable="true" type="string" />
> >>>   <element name="LISTA1" nillable="true" 
> >>>   type="transactionHB24:ArrayHB24ILISTA1Stub" />
> >>> </sequence>
> >>></complexType>
> >>>
> >>>, and the output is:
> >>>
> >>><LISTA1 xsi:type="ns2:ArrayHB24ILISTA1Stub">
> >>> <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>   <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>   <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>> </item>
> >>> <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>   <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>   <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>> </item>
> >>> <TEST xsi:type="xsd:string" xsi:nil="true"/>
> >>></LISTA1>
> >>>
> >>>However, I'm almost sure that the server will complain about that unknown
> >>>ArrayHB24ILISTA1Stub (since I changed the wsdl but only at client side).
> >>>Will test it and say if it works
> >>>
> >>>[]
> >>>
> >>>Pedro
> >>>
> >>>
> >>>On Thu, Mar 09, 2006 at 06:52:26PM +0000, Pedro Alves wrote:
> >>>>   Hum... I dunno about that. But that is the output I'm getting. 
> >>>>   Apparently
> >>>>axis is beeing smart and realizing that I dont need 2 objects for that 
> >>>>--
> >>>>and he is right, he doesnt even creates a ArrayHB24ILISTA1Stub.java -- 
> >>>>but
> >>>>I really need him to be dumb :)
> >>>>
> >>>>On Thu, Mar 09, 2006 at 12:54:23PM -0600, Kiran Kumar wrote:
> >>>>>Hi,
> >>>>>
> >>>>>In the generated output, <LISTA1> element is pointing to 
> >>>>>"ArrayHB24ILISTA1", it is supposed to point "ArrayHB24ILISTA1Stub". 
> >>>>>       <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">         =====> 
> >>>>>       supposed to be "ArrayHB24ILISTA1Stub"..        <ACCAO 
> >>>>>         xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>         <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>       </LISTA1>
> >>>>>
> >>>>>Kiran
> >>>>>
> >>>>>On Wed, Mar 08, 2006 at 09:39:07AM -0600, Kiran Kumar wrote:
> >>>>>>Hi,
> >>>>>>
> >>>>>>As per the definition of type'ArrayHB24ILISTA1' is not 'Array'.. You 
> >>>>>>have to define array of your complex type (ArrayHB24ILISTA1).. It 
> >>>>>>would be something like this :
> >>>>>>
> >>>>>>	<xsd:complexType name="LISTA1Type">
> >>>>>>		<xsd:sequence>
> >>>>>>			<xsd:element name="item" 
> >>>>>>			type="transactionHB24:ArrayHB24ILISTA1" 
> >>>>>>			maxOccurs="unbounded"/>
> >>>>>>		</xsd:sequence>
> >>>>>>	</xsd:complexType>
> >>>>>>
> >>>>>>      <xsd:element name="LISTA1" type="LISTA1Type" />
> >>>>>>
> >>>>>>
> >>>>>>Name of the your complex type (ArrayHB24ILISTA1) is confusing..Its 
> >>>>>>not an array.. its just a complex type.
> >>>>>>
> >>>>>Reopening this subject:
> >>>>>
> >>>>>I followed your suggestion. My wsdl now reads:
> >>>>>
> >>>>>     <complexType name="ArrayHB24ILISTA1Stub">
> >>>>>       <sequence>
> >>>>>         <element name="item" nillable="true" maxOccurs="unbounded" 
> >>>>>         type="transactionHB24:ArrayHB24ILISTA1" />
> >>>>>       </sequence>
> >>>>>     </complexType>
> >>>>>     <complexType name="RequestBeanHB24">
> >>>>>       <sequence>
> >>>>>         <element name="cancelTrxId" nillable="true" type="string" />
> >>>>>         <element name="LISTA1" nillable="true" 
> >>>>>         type="transactionHB24:ArrayHB24ILISTA1Stub" />
> >>>>>       </sequence>
> >>>>>     </complexType>
> >>>>>
> >>>>>But the output is still:
> >>>>>
> >>>>>     <arg0 
> >>>>>     xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" 
> >>>>>     xsi:type="ns2:RequestBeanHB24">
> >>>>>       <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>       <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
> >>>>>         <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>         <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>       </LISTA1>
> >>>>>       <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
> >>>>>         <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>         <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>       </LISTA1>
> >>>>>       <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>       <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>     </arg0>
> >>>>>
> >>>>>
> >>>>>The other side (a desperately outdated weblogic...) requires a form 
> >>>>>like:
> >>>>>
> >>>>>     <arg0 
> >>>>>     xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" 
> >>>>>     xsi:type="ns2:RequestBeanHB24">
> >>>>>       <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>       <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1[2]">
> >>>>>           <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>>>             <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>             <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>           </item>
> >>>>>           <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>>>             <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>             <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>           </item>
> >>>>>       </LISTA1>
> >>>>>       <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>       <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
> >>>>>     </arg0>
> >>>>>
> >>>>>
> >>>>>How can I force axis to send the request in this form? (even if I have 
> >>>>>to
> >>>>>change the wsdl).
> >>>>>
> >>>>>Thanks

-- 
Pedro Alves
pedro.alves@zmail.pt

Re: in Arrays - -

Posted by Dies Koper <di...@jp.fujitsu.com>.
I've never tried from ant but I suppose you'd need to change 
wrapArrays="no" to wrapArrays="true" and take out noWrapped="true".

-wrapArrays is a new option, since Axis 1.3, and maybe it wasn't 
implemented into the ant task (few people need it anyway).

If the above doesn't work, you'd either have to use ant's "exec" task, 
or supply a patch yourself.

Good luck,
Dies

Pedro Alves wrote:
> Hum... How do I pass that option into the ant task? Found nothing in the
> documentation.
> 
> However, I search in the sources for examples and I used this:
> 
>         <wsdl2java url="${filename}"
>             output="${build.stubs}"
>             deployscope="session"
>             serverSide="no"
>             noimports="no"
>             skeletonDeploy="no"
>             verbose="no"
>             typeMappingVersion="1.1"
>             testcase="no"
>             noWrapped="true"
>             wrapArrays="no"
>             >
> 
> However, I cant find any differences... it generates the same thing. (at
> least, if I got it right, it should generate the stubs without the need
> for me to make the changes in wsdl).
> 
> I'm using axis 1.3
> 
> 
> Thanks
> 
> On Fri, Mar 10, 2006 at 11:11:59AM +0900, Dies Koper wrote:
>> Hello Pedro,
>>
>> I didn't think it would affect your SOAP message but if you just want 
>> the ArrayHB24ILISTA1Stub class with a definition as the following to be 
>> generated, use the -wrapArrays option (by default Axis "unwraps" the 
>> complexType).
>>
>> <complexType name="ArrayHB24ILISTA1Stub">
>>   <sequence>
>>     <element name="item" nillable="true" maxOccurs="unbounded" 
>> type="transactionHB24:ArrayHB24ILISTA1" />
>>   </sequence>
>> </complexType>
>>
>> Regards,
>> Dies
>>
>>
>> Pedro Alves wrote:
>>> I found a way to force the "<item>" to be sent, but I dont think it will
>>> work, since the namespace is different. Adding an element "test", it
>>> forces axis to build the Stub object:
>>>
>>> <complexType name="ArrayHB24ILISTA1Stub">
>>>  <sequence>
>>>    <element name="item" nillable="true" maxOccurs="unbounded" 
>>>    type="transactionHB24:ArrayHB24ILISTA1" />
>>>    <element name="TEST" minOccurs="0" type="string"/>
>>>  </sequence>
>>> </complexType>
>>> <complexType name="RequestBeanHB24">
>>>  <sequence>
>>>    <element name="cancelTrxId" nillable="true" type="string" />
>>>    <element name="LISTA1" nillable="true" 
>>>    type="transactionHB24:ArrayHB24ILISTA1Stub" />
>>>  </sequence>
>>> </complexType>
>>>
>>> , and the output is:
>>>
>>> <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1Stub">
>>>  <item xsi:type="ns2:ArrayHB24ILISTA1">
>>>    <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>    <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>  </item>
>>>  <item xsi:type="ns2:ArrayHB24ILISTA1">
>>>    <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>    <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>  </item>
>>>  <TEST xsi:type="xsd:string" xsi:nil="true"/>
>>> </LISTA1>
>>>
>>> However, I'm almost sure that the server will complain about that unknown
>>> ArrayHB24ILISTA1Stub (since I changed the wsdl but only at client side).
>>> Will test it and say if it works
>>>
>>> []
>>>
>>> Pedro
>>>
>>>
>>> On Thu, Mar 09, 2006 at 06:52:26PM +0000, Pedro Alves wrote:
>>>>    Hum... I dunno about that. But that is the output I'm getting. 
>>>>    Apparently
>>>> axis is beeing smart and realizing that I dont need 2 objects for that --
>>>> and he is right, he doesnt even creates a ArrayHB24ILISTA1Stub.java -- but
>>>> I really need him to be dumb :)
>>>>
>>>> On Thu, Mar 09, 2006 at 12:54:23PM -0600, Kiran Kumar wrote:
>>>>> Hi,
>>>>>
>>>>> In the generated output, <LISTA1> element is pointing to 
>>>>> "ArrayHB24ILISTA1", it is supposed to point "ArrayHB24ILISTA1Stub". 
>>>>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">         =====> supposed 
>>>>>        to be "ArrayHB24ILISTA1Stub"..        <ACCAO 
>>>>>          xsi:type="xsd:string" xsi:nil="true"/>
>>>>>          <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>>>        </LISTA1>
>>>>>
>>>>> Kiran
>>>>>
>>>>> On Wed, Mar 08, 2006 at 09:39:07AM -0600, Kiran Kumar wrote:
>>>>>> Hi,
>>>>>>
>>>>>> As per the definition of type'ArrayHB24ILISTA1' is not 'Array'.. You 
>>>>>> have to define array of your complex type (ArrayHB24ILISTA1).. It would 
>>>>>> be something like this :
>>>>>>
>>>>>> 	<xsd:complexType name="LISTA1Type">
>>>>>> 		<xsd:sequence>
>>>>>> 			<xsd:element name="item" 
>>>>>> 			type="transactionHB24:ArrayHB24ILISTA1" 
>>>>>> 			maxOccurs="unbounded"/>
>>>>>> 		</xsd:sequence>
>>>>>> 	</xsd:complexType>
>>>>>>
>>>>>>       <xsd:element name="LISTA1" type="LISTA1Type" />
>>>>>>
>>>>>>
>>>>>> Name of the your complex type (ArrayHB24ILISTA1) is confusing..Its not 
>>>>>> an array.. its just a complex type.
>>>>>>
>>>>> Reopening this subject:
>>>>>
>>>>> I followed your suggestion. My wsdl now reads:
>>>>>
>>>>>      <complexType name="ArrayHB24ILISTA1Stub">
>>>>>        <sequence>
>>>>>          <element name="item" nillable="true" maxOccurs="unbounded" 
>>>>>          type="transactionHB24:ArrayHB24ILISTA1" />
>>>>>        </sequence>
>>>>>      </complexType>
>>>>>      <complexType name="RequestBeanHB24">
>>>>>        <sequence>
>>>>>          <element name="cancelTrxId" nillable="true" type="string" />
>>>>>          <element name="LISTA1" nillable="true" 
>>>>>          type="transactionHB24:ArrayHB24ILISTA1Stub" />
>>>>>        </sequence>
>>>>>      </complexType>
>>>>>
>>>>> But the output is still:
>>>>>
>>>>>      <arg0 
>>>>>      xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" 
>>>>>      xsi:type="ns2:RequestBeanHB24">
>>>>>        <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
>>>>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
>>>>>          <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>>>          <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>>>        </LISTA1>
>>>>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
>>>>>          <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>>>          <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>>>        </LISTA1>
>>>>>        <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
>>>>>        <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
>>>>>      </arg0>
>>>>>
>>>>>
>>>>> The other side (a desperately outdated weblogic...) requires a form like:
>>>>>
>>>>>      <arg0 
>>>>>      xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" 
>>>>>      xsi:type="ns2:RequestBeanHB24">
>>>>>        <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
>>>>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1[2]">
>>>>>            <item xsi:type="ns2:ArrayHB24ILISTA1">
>>>>>              <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>>>              <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>>>            </item>
>>>>>            <item xsi:type="ns2:ArrayHB24ILISTA1">
>>>>>              <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>>>              <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>>>            </item>
>>>>>        </LISTA1>
>>>>>        <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
>>>>>        <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
>>>>>      </arg0>
>>>>>
>>>>>
>>>>> How can I force axis to send the request in this form? (even if I have to
>>>>> change the wsdl).
>>>>>
>>>>> Thanks


Re: in Arrays - -

Posted by Pedro Alves <pe...@neraka.no-ip.org>.
Hum... How do I pass that option into the ant task? Found nothing in the
documentation.

However, I search in the sources for examples and I used this:

        <wsdl2java url="${filename}"
            output="${build.stubs}"
            deployscope="session"
            serverSide="no"
            noimports="no"
            skeletonDeploy="no"
            verbose="no"
            typeMappingVersion="1.1"
            testcase="no"
            noWrapped="true"
            wrapArrays="no"
            >

However, I cant find any differences... it generates the same thing. (at
least, if I got it right, it should generate the stubs without the need
for me to make the changes in wsdl).

I'm using axis 1.3


Thanks

On Fri, Mar 10, 2006 at 11:11:59AM +0900, Dies Koper wrote:
> Hello Pedro,
> 
> I didn't think it would affect your SOAP message but if you just want 
> the ArrayHB24ILISTA1Stub class with a definition as the following to be 
> generated, use the -wrapArrays option (by default Axis "unwraps" the 
> complexType).
> 
> <complexType name="ArrayHB24ILISTA1Stub">
>   <sequence>
>     <element name="item" nillable="true" maxOccurs="unbounded" 
> type="transactionHB24:ArrayHB24ILISTA1" />
>   </sequence>
> </complexType>
> 
> Regards,
> Dies
> 
> 
> Pedro Alves wrote:
> >I found a way to force the "<item>" to be sent, but I dont think it will
> >work, since the namespace is different. Adding an element "test", it
> >forces axis to build the Stub object:
> >
> ><complexType name="ArrayHB24ILISTA1Stub">
> >  <sequence>
> >    <element name="item" nillable="true" maxOccurs="unbounded" 
> >    type="transactionHB24:ArrayHB24ILISTA1" />
> >    <element name="TEST" minOccurs="0" type="string"/>
> >  </sequence>
> ></complexType>
> ><complexType name="RequestBeanHB24">
> >  <sequence>
> >    <element name="cancelTrxId" nillable="true" type="string" />
> >    <element name="LISTA1" nillable="true" 
> >    type="transactionHB24:ArrayHB24ILISTA1Stub" />
> >  </sequence>
> ></complexType>
> >
> >, and the output is:
> >
> ><LISTA1 xsi:type="ns2:ArrayHB24ILISTA1Stub">
> >  <item xsi:type="ns2:ArrayHB24ILISTA1">
> >    <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >    <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >  </item>
> >  <item xsi:type="ns2:ArrayHB24ILISTA1">
> >    <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >    <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >  </item>
> >  <TEST xsi:type="xsd:string" xsi:nil="true"/>
> ></LISTA1>
> >
> >However, I'm almost sure that the server will complain about that unknown
> >ArrayHB24ILISTA1Stub (since I changed the wsdl but only at client side).
> >Will test it and say if it works
> >
> >[]
> >
> >Pedro
> >
> >
> >On Thu, Mar 09, 2006 at 06:52:26PM +0000, Pedro Alves wrote:
> >>
> >>    Hum... I dunno about that. But that is the output I'm getting. 
> >>    Apparently
> >>axis is beeing smart and realizing that I dont need 2 objects for that --
> >>and he is right, he doesnt even creates a ArrayHB24ILISTA1Stub.java -- but
> >>I really need him to be dumb :)
> >>
> >>On Thu, Mar 09, 2006 at 12:54:23PM -0600, Kiran Kumar wrote:
> >>>Hi,
> >>>
> >>>In the generated output, <LISTA1> element is pointing to 
> >>>"ArrayHB24ILISTA1", it is supposed to point "ArrayHB24ILISTA1Stub". 
> >>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">         =====> supposed 
> >>>        to be "ArrayHB24ILISTA1Stub"..        <ACCAO 
> >>>          xsi:type="xsd:string" xsi:nil="true"/>
> >>>          <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>        </LISTA1>
> >>>
> >>>Kiran
> >>> 
> >>>On Wed, Mar 08, 2006 at 09:39:07AM -0600, Kiran Kumar wrote:
> >>>>Hi,
> >>>>
> >>>>As per the definition of type'ArrayHB24ILISTA1' is not 'Array'.. You 
> >>>>have to define array of your complex type (ArrayHB24ILISTA1).. It would 
> >>>>be something like this :
> >>>>
> >>>>	<xsd:complexType name="LISTA1Type">
> >>>>		<xsd:sequence>
> >>>>			<xsd:element name="item" 
> >>>>			type="transactionHB24:ArrayHB24ILISTA1" 
> >>>>			maxOccurs="unbounded"/>
> >>>>		</xsd:sequence>
> >>>>	</xsd:complexType>
> >>>>
> >>>>       <xsd:element name="LISTA1" type="LISTA1Type" />
> >>>>
> >>>>
> >>>>Name of the your complex type (ArrayHB24ILISTA1) is confusing..Its not 
> >>>>an array.. its just a complex type.
> >>>>
> >>>Reopening this subject:
> >>>
> >>>I followed your suggestion. My wsdl now reads:
> >>>
> >>>      <complexType name="ArrayHB24ILISTA1Stub">
> >>>        <sequence>
> >>>          <element name="item" nillable="true" maxOccurs="unbounded" 
> >>>          type="transactionHB24:ArrayHB24ILISTA1" />
> >>>        </sequence>
> >>>      </complexType>
> >>>      <complexType name="RequestBeanHB24">
> >>>        <sequence>
> >>>          <element name="cancelTrxId" nillable="true" type="string" />
> >>>          <element name="LISTA1" nillable="true" 
> >>>          type="transactionHB24:ArrayHB24ILISTA1Stub" />
> >>>        </sequence>
> >>>      </complexType>
> >>>
> >>>But the output is still:
> >>>
> >>>      <arg0 
> >>>      xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" 
> >>>      xsi:type="ns2:RequestBeanHB24">
> >>>        <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
> >>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
> >>>          <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>          <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>        </LISTA1>
> >>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
> >>>          <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>          <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>        </LISTA1>
> >>>        <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
> >>>        <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
> >>>      </arg0>
> >>>
> >>>
> >>>The other side (a desperately outdated weblogic...) requires a form like:
> >>>
> >>>      <arg0 
> >>>      xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" 
> >>>      xsi:type="ns2:RequestBeanHB24">
> >>>        <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
> >>>        <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1[2]">
> >>>            <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>              <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>              <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>            </item>
> >>>            <item xsi:type="ns2:ArrayHB24ILISTA1">
> >>>              <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >>>              <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >>>            </item>
> >>>        </LISTA1>
> >>>        <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
> >>>        <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
> >>>      </arg0>
> >>>
> >>>
> >>>How can I force axis to send the request in this form? (even if I have to
> >>>change the wsdl).
> >>>
> >>>Thanks
> 

-- 
Pedro Alves
pedro.alves@zmail.pt

Re: in Arrays - -

Posted by Dies Koper <di...@jp.fujitsu.com>.
Hello Pedro,

I didn't think it would affect your SOAP message but if you just want 
the ArrayHB24ILISTA1Stub class with a definition as the following to be 
generated, use the -wrapArrays option (by default Axis "unwraps" the 
complexType).

<complexType name="ArrayHB24ILISTA1Stub">
   <sequence>
     <element name="item" nillable="true" maxOccurs="unbounded" 
type="transactionHB24:ArrayHB24ILISTA1" />
   </sequence>
</complexType>

Regards,
Dies


Pedro Alves wrote:
> I found a way to force the "<item>" to be sent, but I dont think it will
> work, since the namespace is different. Adding an element "test", it
> forces axis to build the Stub object:
> 
> <complexType name="ArrayHB24ILISTA1Stub">
>   <sequence>
>     <element name="item" nillable="true" maxOccurs="unbounded" type="transactionHB24:ArrayHB24ILISTA1" />
>     <element name="TEST" minOccurs="0" type="string"/>
>   </sequence>
> </complexType>
> <complexType name="RequestBeanHB24">
>   <sequence>
>     <element name="cancelTrxId" nillable="true" type="string" />
>     <element name="LISTA1" nillable="true" type="transactionHB24:ArrayHB24ILISTA1Stub" />
>   </sequence>
> </complexType>
> 
> , and the output is:
> 
> <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1Stub">
>   <item xsi:type="ns2:ArrayHB24ILISTA1">
>     <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>     <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>   </item>
>   <item xsi:type="ns2:ArrayHB24ILISTA1">
>     <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>     <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>   </item>
>   <TEST xsi:type="xsd:string" xsi:nil="true"/>
> </LISTA1>
> 
> However, I'm almost sure that the server will complain about that unknown
> ArrayHB24ILISTA1Stub (since I changed the wsdl but only at client side).
> Will test it and say if it works
> 
> []
> 
> Pedro
> 
> 
> On Thu, Mar 09, 2006 at 06:52:26PM +0000, Pedro Alves wrote:
>>
>>     Hum... I dunno about that. But that is the output I'm getting. Apparently
>> axis is beeing smart and realizing that I dont need 2 objects for that --
>> and he is right, he doesnt even creates a ArrayHB24ILISTA1Stub.java -- but
>> I really need him to be dumb :)
>>
>> On Thu, Mar 09, 2006 at 12:54:23PM -0600, Kiran Kumar wrote:
>>> Hi,
>>>
>>> In the generated output, <LISTA1> element is pointing to "ArrayHB24ILISTA1", it is supposed to point "ArrayHB24ILISTA1Stub". 
>>>
>>>         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">         =====> supposed to be "ArrayHB24ILISTA1Stub"..        
>>>           <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>           <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>         </LISTA1>
>>>
>>> Kiran
>>>  
>>> On Wed, Mar 08, 2006 at 09:39:07AM -0600, Kiran Kumar wrote:
>>>> Hi,
>>>>
>>>> As per the definition of type'ArrayHB24ILISTA1' is not 'Array'.. You have to define array of your complex type (ArrayHB24ILISTA1).. It would be something like this :
>>>>
>>>> 	<xsd:complexType name="LISTA1Type">
>>>> 		<xsd:sequence>
>>>> 			<xsd:element name="item" type="transactionHB24:ArrayHB24ILISTA1" maxOccurs="unbounded"/>
>>>> 		</xsd:sequence>
>>>> 	</xsd:complexType>
>>>>
>>>>        <xsd:element name="LISTA1" type="LISTA1Type" />
>>>>
>>>>
>>>> Name of the your complex type (ArrayHB24ILISTA1) is confusing..Its not an array.. its just a complex type.
>>>>
>>> Reopening this subject:
>>>
>>> I followed your suggestion. My wsdl now reads:
>>>
>>>       <complexType name="ArrayHB24ILISTA1Stub">
>>>         <sequence>
>>>           <element name="item" nillable="true" maxOccurs="unbounded" type="transactionHB24:ArrayHB24ILISTA1" />
>>>         </sequence>
>>>       </complexType>
>>>       <complexType name="RequestBeanHB24">
>>>         <sequence>
>>>           <element name="cancelTrxId" nillable="true" type="string" />
>>>           <element name="LISTA1" nillable="true" type="transactionHB24:ArrayHB24ILISTA1Stub" />
>>>         </sequence>
>>>       </complexType>
>>>
>>> But the output is still:
>>>
>>>       <arg0 xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" xsi:type="ns2:RequestBeanHB24">
>>>         <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
>>>         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
>>>           <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>           <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>         </LISTA1>
>>>         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
>>>           <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>           <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>         </LISTA1>
>>>         <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
>>>         <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
>>>       </arg0>
>>>
>>>
>>> The other side (a desperately outdated weblogic...) requires a form like:
>>>
>>>       <arg0 xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" xsi:type="ns2:RequestBeanHB24">
>>>         <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
>>>         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1[2]">
>>>             <item xsi:type="ns2:ArrayHB24ILISTA1">
>>>               <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>               <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>             </item>
>>>             <item xsi:type="ns2:ArrayHB24ILISTA1">
>>>               <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
>>>               <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
>>>             </item>
>>>         </LISTA1>
>>>         <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
>>>         <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
>>>       </arg0>
>>>
>>>
>>> How can I force axis to send the request in this form? (even if I have to
>>> change the wsdl).
>>>
>>> Thanks



Re: in Arrays - -

Posted by Pedro Alves <pe...@neraka.no-ip.org>.
I found a way to force the "<item>" to be sent, but I dont think it will
work, since the namespace is different. Adding an element "test", it
forces axis to build the Stub object:

<complexType name="ArrayHB24ILISTA1Stub">
  <sequence>
    <element name="item" nillable="true" maxOccurs="unbounded" type="transactionHB24:ArrayHB24ILISTA1" />
    <element name="TEST" minOccurs="0" type="string"/>
  </sequence>
</complexType>
<complexType name="RequestBeanHB24">
  <sequence>
    <element name="cancelTrxId" nillable="true" type="string" />
    <element name="LISTA1" nillable="true" type="transactionHB24:ArrayHB24ILISTA1Stub" />
  </sequence>
</complexType>

, and the output is:

<LISTA1 xsi:type="ns2:ArrayHB24ILISTA1Stub">
  <item xsi:type="ns2:ArrayHB24ILISTA1">
    <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
    <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
  </item>
  <item xsi:type="ns2:ArrayHB24ILISTA1">
    <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
    <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
  </item>
  <TEST xsi:type="xsd:string" xsi:nil="true"/>
</LISTA1>

However, I'm almost sure that the server will complain about that unknown
ArrayHB24ILISTA1Stub (since I changed the wsdl but only at client side).
Will test it and say if it works

[]

Pedro


On Thu, Mar 09, 2006 at 06:52:26PM +0000, Pedro Alves wrote:
> 
> 
>     Hum... I dunno about that. But that is the output I'm getting. Apparently
> axis is beeing smart and realizing that I dont need 2 objects for that --
> and he is right, he doesnt even creates a ArrayHB24ILISTA1Stub.java -- but
> I really need him to be dumb :)
> 
> On Thu, Mar 09, 2006 at 12:54:23PM -0600, Kiran Kumar wrote:
> > Hi,
> > 
> > In the generated output, <LISTA1> element is pointing to "ArrayHB24ILISTA1", it is supposed to point "ArrayHB24ILISTA1Stub". 
> > 
> >         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">         =====> supposed to be "ArrayHB24ILISTA1Stub"..        
> >           <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >           <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >         </LISTA1>
> > 
> > Kiran
> >  
> > On Wed, Mar 08, 2006 at 09:39:07AM -0600, Kiran Kumar wrote:
> > > Hi,
> > > 
> > > As per the definition of type'ArrayHB24ILISTA1' is not 'Array'.. You have to define array of your complex type (ArrayHB24ILISTA1).. It would be something like this :
> > > 
> > > 	<xsd:complexType name="LISTA1Type">
> > > 		<xsd:sequence>
> > > 			<xsd:element name="item" type="transactionHB24:ArrayHB24ILISTA1" maxOccurs="unbounded"/>
> > > 		</xsd:sequence>
> > > 	</xsd:complexType>
> > > 
> > >        <xsd:element name="LISTA1" type="LISTA1Type" />
> > > 
> > > 
> > > Name of the your complex type (ArrayHB24ILISTA1) is confusing..Its not an array.. its just a complex type.
> > > 
> > 
> > Reopening this subject:
> > 
> > I followed your suggestion. My wsdl now reads:
> > 
> >       <complexType name="ArrayHB24ILISTA1Stub">
> >         <sequence>
> >           <element name="item" nillable="true" maxOccurs="unbounded" type="transactionHB24:ArrayHB24ILISTA1" />
> >         </sequence>
> >       </complexType>
> >       <complexType name="RequestBeanHB24">
> >         <sequence>
> >           <element name="cancelTrxId" nillable="true" type="string" />
> >           <element name="LISTA1" nillable="true" type="transactionHB24:ArrayHB24ILISTA1Stub" />
> >         </sequence>
> >       </complexType>
> > 
> > But the output is still:
> > 
> >       <arg0 xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" xsi:type="ns2:RequestBeanHB24">
> >         <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
> >         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
> >           <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >           <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >         </LISTA1>
> >         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1">
> >           <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >           <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >         </LISTA1>
> >         <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
> >         <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
> >       </arg0>
> > 
> > 
> > The other side (a desperately outdated weblogic...) requires a form like:
> > 
> >       <arg0 xmlns:ns2="java:com.altitude.tp.transactions.transactionHB24" xsi:type="ns2:RequestBeanHB24">
> >         <cancelTrxId xsi:type="xsd:string" xsi:nil="true"/>
> >         <LISTA1 xsi:type="ns2:ArrayHB24ILISTA1[2]">
> >             <item xsi:type="ns2:ArrayHB24ILISTA1">
> >               <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >               <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >             </item>
> >             <item xsi:type="ns2:ArrayHB24ILISTA1">
> >               <ACCAO xsi:type="xsd:string" xsi:nil="true"/>
> >               <CTCANAL_L xsi:type="xsd:string" xsi:nil="true"/>
> >             </item>
> >         </LISTA1>
> >         <codAmbiente xsi:type="xsd:string" xsi:nil="true"/>
> >         <autorizacoes xsi:type="xsd:string" xsi:nil="true"/>
> >       </arg0>
> > 
> > 
> > How can I force axis to send the request in this form? (even if I have to
> > change the wsdl).
> > 
> > Thanks
> > 
> > -- 
> > Pedro Alves
> > pedro.alves@zmail.pt
> > 
> > 
> > ------------------------------------------------
> > 
> > This e-mail, and any attachments thereto, is confidential and is intended only for the individual(s) named.  If you are not the intended recipient, please let us know by e-mail reply and delete it from your system; do not copy/save this e-mail or disclose its contents to anyone.  E-mail transmissions cannot be guaranteed to be secure or error-free as the transmission could be interrupted, corrupted, lost, destroyed, altered, arrive late or contain viruses.  ObjectWave does not accept liability for any errors or omissions in the contents of this e-mail which arise as a result of e-mail transmission.  The views expressed in this e-mail do not necessarily reflect those of ObjectWave or its affiliates.
> > 
> > ------------------------------------------------
> > 
> > 
> 
> 
> 
> -- 
> Pedro Alves
> pedro.alves@zmail.pt

-- 
Pedro Alves
pedro.alves@zmail.pt