Re: Help with old service that uses soap encoding
Thiago Milczarek Sayão <[email protected]> Wed, 7 Dec 2022 09:43:21 -0300
| Newsgroups | gmane.text.xml.axis.user |
|---|---|
| Message-ID | <CAAP_wu=Za8vKBcHdt5=CWgxXvF42SrF5S-=5OuGOgnJpZTNbHg@mail.gmail.com> |
--0000000000009760de05ef3c4446 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Robert, Thanks for the reply. I still didn't have success. I'm thinking about using axis 1.4. Cheers. Em ter., 6 de dez. de 2022 =C3=A0s 11:13, robertlazarski < [email protected]> escreveu: > I mean to include this link, which at the end of a page there is a better > xmlbeans example. > > https://axis.apache.org/axis2/java/core/tools/CodegenToolReference.html > > On Tue, Dec 6, 2022 at 4:04 AM robertlazarski <[email protected]> > wrote: > >> Did you ever figure this out? >> >> I got busy this past week, however I am interested in seeing how this >> could work. >> >> I'd start here, by running this xmlbeans example with wsdl2java. Then >> compare your wsdl with soap encoding to see what is missing. >> >> >> https://axis.apache.org/axis2/java/core/docs/userguide-creatingclients-x= mlbeans.html >> >> On Wed, Nov 30, 2022 at 3:25 AM Thiago Milczarek Say=C3=A3o < >> [email protected]> wrote: >> >>> Robert, >>> >>> Thanks for the reply. >>> >>> I will try with xmlbeans as databinding. >>> >>> One question: >>> >>> >>> cur.insertElementWithText("processSyncReturn","this is array elemen= t 2"); >>> >>> >>> This is the example on stackoverflow. >>> >>> How would I insert a complex type, instead of a string? My guess it to >>> serialize de XmlObject and insert as string. How would I do that? >>> >>> Thanks. >>> >>> >>> Em ter., 29 de nov. de 2022 =C3=A0s 17:59, robertlazarski < >>> [email protected]> escreveu: >>> >>>> Sorry, wrong link: >>>> >>>> >>>> https://stackoverflow.com/questions/11561194/how-can-i-get-axis2-to-ha= ndle-an-array >>>> >>>> On Tue, Nov 29, 2022 at 10:56 AM robertlazarski < >>>> [email protected]> wrote: >>>> >>>>> Axis2 doesn't support soapenc. >>>>> >>>>> Axis 1.x does, but you likely don't want to use that. >>>>> >>>>> Some have claimed that you can use the XMLBeans API directly, after >>>>> you run wsdl2code. >>>>> >>>>> See the bottom of this link for an example. >>>>> >>>>> >>>>> https://stackoverflow.com/questions/74577973/how-to-use-array-soap-en= coding-type-with-axis2-xmlbeans >>>>> >>>>> If you get that to work, I'd document it if you could provide a >>>>> working example. >>>>> >>>>> >>>>> On Tue, Nov 29, 2022 at 8:27 AM Thiago Milczarek Say=C3=A3o < >>>>> [email protected]> wrote: >>>>> >>>>>> Hello, >>>>>> >>>>>> I've posted the question here: >>>>>> >>>>>> https://stackoverflow.com/questions/74577973/how-to-use-array-soap-e= ncoding-type-with-axis2-xmlbeans >>>>>> >>>>>> I want to use this service: >>>>>> >>>>>> https://farmaciapopular-autorizador.saude.gov.br/farmaciapopular-aut= orizador/services/ServicoSolicitacaoWS?wsdl >>>>>> >>>>>> <complexType name=3D"ArrayOfMedicamentoDTO"> >>>>>> <complexContent> >>>>>> <restriction base=3D"soapenc:Array"> >>>>>> <attribute ref=3D"soapenc:arrayType" >>>>>> wsdl:arrayType=3D"impl:MedicamentoDTO[]"/> >>>>>> </restriction> >>>>>> </complexContent> >>>>>> </complexType> >>>>>> >>>>>> It generates a class ArrayOfMedicamentoDTO that extentds Array, but >>>>>> there's no way to add items to it. >>>>>> >>>>>> Thanks. >>>>>> >>>>> --0000000000009760de05ef3c4446 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr">Hi Robert,<div><br></div><div>Thanks for the reply. I stil= l didn't have success. I'm thinking about using axis 1.4.</div><div= ><br></div><div>Cheers.</div></div><br><div class=3D"gmail_quote"><div dir= =3D"ltr" class=3D"gmail_attr">Em ter., 6 de dez. de 2022 =C3=A0s 11:13, rob= ertlazarski <<a href=3D"mailto:[email protected]">robertlazarski@= gmail.com</a>> escreveu:<br></div><blockquote class=3D"gmail_quote" styl= e=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);paddin= g-left:1ex"><div dir=3D"ltr"><div>I mean to include this link, which at the= end of a page there is a better xmlbeans example. <br></div><div><br></div= ><div><a href=3D"https://axis.apache.org/axis2/java/core/tools/CodegenToolR= eference.html" target=3D"_blank">https://axis.apache.org/axis2/java/core/to= ols/CodegenToolReference.html</a></div></div><br><div class=3D"gmail_quote"= ><div dir=3D"ltr" class=3D"gmail_attr">On Tue, Dec 6, 2022 at 4:04 AM rober= tlazarski <<a href=3D"mailto:[email protected]" target=3D"_blank"= >[email protected]</a>> wrote:<br></div><blockquote class=3D"gmai= l_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,20= 4,204);padding-left:1ex"><div dir=3D"ltr"><div>Did you ever figure this out= ? <br></div><div><br></div><div>I got busy this past week, however I am int= erested in seeing how this could work. <br></div><div><br></div><div>I'= d start here, by running this xmlbeans example with wsdl2java. Then compare= your wsdl with soap encoding to see what is missing. <br></div><div><br></= div><div><a href=3D"https://axis.apache.org/axis2/java/core/docs/userguide-= creatingclients-xmlbeans.html" target=3D"_blank">https://axis.apache.org/ax= is2/java/core/docs/userguide-creatingclients-xmlbeans.html</a> <br></div></= div><br><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">On= Wed, Nov 30, 2022 at 3:25 AM Thiago Milczarek Say=C3=A3o <<a href=3D"ma= ilto:[email protected]" target=3D"_blank">[email protected]</a>&g= t; wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0p= x 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div d= ir=3D"ltr"><div>Robert,</div><div><br></div>Thanks for the reply.<div><br><= /div><div>I will try with xmlbeans as databinding.</div><div><br></div><div= >One question:</div><div><br></div><div><br></div><div><pre style=3D"margin= -top:0px;border:0px none;font-variant-numeric:inherit;font-variant-east-asi= an:inherit;font-stretch:inherit;vertical-align:baseline;box-sizing:inherit;= width:auto;max-height:600px;overflow:auto"><code style=3D"margin:0px;paddin= g:0px;border:0px none;font-style:inherit;font-variant:inherit;font-weight:i= nherit;font-stretch:inherit;line-height:inherit;font-family:inherit;vertica= l-align:baseline;box-sizing:inherit;background-color:transparent;white-spac= e:inherit"> cur.insertElementWithText("processSyncReturn",&quo= t;this is array element 2"); </code></pre><br></div><div>This is the example on stackoverflow.</div><div= ><br></div><div>How would I insert a complex type, instead of a string? My = guess it to serialize de XmlObject and insert as string. How would I do tha= t?</div><div><br></div><div>Thanks.</div><div><br></div></div><br><div clas= s=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">Em ter., 29 de nov.= de 2022 =C3=A0s 17:59, robertlazarski <<a href=3D"mailto:robertlazarski= @gmail.com" target=3D"_blank">[email protected]</a>> escreveu:<br= ></div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;= border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir=3D"ltr"><= div>Sorry, wrong link: <br></div><div><br></div><div><a href=3D"https://sta= ckoverflow.com/questions/11561194/how-can-i-get-axis2-to-handle-an-array" t= arget=3D"_blank">https://stackoverflow.com/questions/11561194/how-can-i-get= -axis2-to-handle-an-array</a></div></div><br><div class=3D"gmail_quote"><di= v dir=3D"ltr" class=3D"gmail_attr">On Tue, Nov 29, 2022 at 10:56 AM robertl= azarski <<a href=3D"mailto:[email protected]" target=3D"_blank">r= [email protected]</a>> wrote:<br></div><blockquote class=3D"gmail_= quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,= 204);padding-left:1ex"><div dir=3D"ltr"><div>Axis2 doesn't support soap= enc. <br></div><div><br></div><div>Axis 1.x does, but you likely don't = want to use that. <br></div><div><br></div><div>Some have claimed that you = can use the XMLBeans API directly, after you run wsdl2code. <br></div><div>= <br></div><div>See the bottom of this link for an example. <br></div><div><= br></div><div><a href=3D"https://stackoverflow.com/questions/74577973/how-t= o-use-array-soap-encoding-type-with-axis2-xmlbeans" target=3D"_blank">https= ://stackoverflow.com/questions/74577973/how-to-use-array-soap-encoding-type= -with-axis2-xmlbeans</a></div><div><br></div><div>If you get that to work, = I'd document it if you could provide a working example.=C2=A0 <br></div= ><div><br></div></div><br><div class=3D"gmail_quote"><div dir=3D"ltr" class= =3D"gmail_attr">On Tue, Nov 29, 2022 at 8:27 AM Thiago Milczarek Say=C3=A3o= <<a href=3D"mailto:[email protected]" target=3D"_blank">thiago.say= [email protected]</a>> wrote:<br></div><blockquote class=3D"gmail_quote" styl= e=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);paddin= g-left:1ex"><div dir=3D"ltr">Hello,<div><br></div><div>I've posted the = question here:</div><div><a href=3D"https://stackoverflow.com/questions/745= 77973/how-to-use-array-soap-encoding-type-with-axis2-xmlbeans" target=3D"_b= lank">https://stackoverflow.com/questions/74577973/how-to-use-array-soap-en= coding-type-with-axis2-xmlbeans</a><br></div><div><br></div><div>I want to = use this service:</div><div><a href=3D"https://farmaciapopular-autorizador.= saude.gov.br/farmaciapopular-autorizador/services/ServicoSolicitacaoWS?wsdl= " target=3D"_blank">https://farmaciapopular-autorizador.saude.gov.br/farmac= iapopular-autorizador/services/ServicoSolicitacaoWS?wsdl</a><br></div><div>= <br></div><div><complexType name=3D"ArrayOfMedicamentoDTO">= <br><complexContent><br><restriction base=3D"soapenc:Array&qu= ot;><br><attribute ref=3D"soapenc:arrayType" wsdl:arrayType= =3D"impl:MedicamentoDTO[]"/><br></restriction><br></c= omplexContent><br></complexType><br></div><div><br></div><div>It g= enerates=C2=A0a class=C2=A0 ArrayOfMedicamentoDTO that extentds Array, but there's no way to add it= ems to it.</div><div><br></div><div>Thanks.</div></div> </blockquote></div> </blockquote></div> </blockquote></div> </blockquote></div> </blockquote></div> </blockquote></div> --0000000000009760de05ef3c4446--