When you deploy a service as a POJO it generates a WSDL in a standard manner. If it is not the one you want you have to change the wsdl/xsd accordingly and regenerate the code. you can use wsdl2java tool to generate the code.
thanks, Amila. On Sun, Jun 15, 2008 at 8:35 PM, Anne Thomas Manes <[EMAIL PROTECTED]> wrote: > You will need to customize the WSDL generated by NetBeans. > Currently your types section maps each Java object attribute to an XSD > element. You need to redefine them as XSD attributes. > > Anne > > On Tue, Jun 10, 2008 at 11:33 AM, Alessio Brescia > <[EMAIL PROTECTED]> wrote: > > Hi everyone! > > > > I've got a little question. > > > > I created a Web service with NetBeans that returns an array of custom > > objects. > > Every custom object is an array of little custom objects. > > I tested the service into Internet Explorer 7 and this is a piece of the > > response: > > > > - <ns:contenutoTabellaResponse xmlns:ns="http://nuovoRitorno" > > xmlns:ax21="http://nuovoRitorno/xsd"> > > - <ns:return type="nuovoRitorno.RigaQuery"> > > - <ax21:campiValori type="nuovoRitorno.CellaQuery"> > > <ax21:nomeCampo>id</ax21:nomeCampo> > > <ax21:valoreCampo>1</ax21:valoreCampo> > > </ax21:campiValori> > > - <ax21:campiValori type="nuovoRitorno.CellaQuery"> > > <ax21:nomeCampo>descrizione</ax21:nomeCampo> > > <ax21:valoreCampo>ADMIN SITO</ax21:valoreCampo> > > </ax21:campiValori> > > - <ax21:campiValori type="nuovoRitorno.CellaQuery"> > > <ax21:nomeCampo>idMenu</ax21:nomeCampo> > > <ax21:valoreCampo>3</ax21:valoreCampo> > > </ax21:campiValori> > > </ns:return> > > - <ns:return type="nuovoRitorno.RigaQuery"> > > - <ax21:campiValori type="nuovoRitorno.CellaQuery"> > > <ax21:nomeCampo>id</ax21:nomeCampo> > > <ax21:valoreCampo>4</ax21:valoreCampo> > > </ax21:campiValori> > > - <ax21:campiValori type="nuovoRitorno.CellaQuery"> > > <ax21:nomeCampo>descrizione</ax21:nomeCampo> > > <ax21:valoreCampo>PROGRAMMATORI</ax21:valoreCampo> > > </ax21:campiValori> > > - <ax21:campiValori type="nuovoRitorno.CellaQuery"> > > <ax21:nomeCampo>idMenu</ax21:nomeCampo> > > <ax21:valoreCampo>1</ax21:valoreCampo> > > </ax21:campiValori> > > </ns:return> > > > > etc. > > > > I want to reduce the size of the XML returned by the service, above all > > because I work with large databases. > > How can I tell Axis2 to return a similar XML: > > > > <ns:contenutoTabellaResponse xmlns:ns="http://nuovoRitorno" > > xmlns:ax21="http://nuovoRitorno/xsd"> > > - <ns:return type="nuovoRitorno.RigaQuery"> > > - <ax21:campiValori type="nuovoRitorno.CellaQuery" ax21:nomeCampo="id" > > ax21:valoreCampo="1" /> > > <ax21:campiValori type="nuovoRitorno.CellaQuery" > > ax21:nomeCampo="descrizione" ax21:valoreCampo="ADMIN SITO" /> > > <ax21:campiValori type="nuovoRitorno.CellaQuery" ax21:nomeCampo="idMenu" > > ax21:valoreCampo="3" /> > > </ns:return> > > > > etc. > > > > > > Thanks in advance! > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Amila Suriarachchi, WSO2 Inc.
