axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Charak, Vikas" <vikas.cha...@cns-inc.com>
Subject RE: Axis2: how to use Java POJO beans
Date Wed, 16 Aug 2006 21:34:14 GMT
My Mistake. My WSDL was wrong. For some reason Axis2 Eclipse plugin
generates wrong WSDL (from Java code) if you have a Java Bean as input
or output parameter. I have to manually modify it to deploy the service.
Any one else faces such a problem?


-----Original Message-----
From: Charak, Vikas 
Sent: Wednesday, August 16, 2006 12:49 PM
To: 'axis-user@ws.apache.org'
Subject: RE: Axis2: how to use Java POJO beans

Sorry here is the correct method
Method1:
>         public Client getClient() {
>                 // Client is a simple java class with getter and
setter.
>                 Client client= new Client();
>                 client.setIdentifier("123");
>                 return client;
>         }
>

-----Original Message-----
From: robert lazarski [mailto:robertlazarski@gmail.com] 
Sent: Wednesday, August 16, 2006 12:46 PM
To: axis-user@ws.apache.org
Subject: Re: Axis2: how to use Java POJO beans

You're setting:

 client.setIdentifier("123");

But returning:

 return l_ client;

Is that what you intended to do ?

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

On 8/16/06, Charak, Vikas <vikas.charak@cns-inc.com> wrote:
> Hi ,
>
> I have created a web service with the following two simple methods
>
> Method1:
>         public Client getClient() {
>                 // Client is a simple java class with getter and
setter.
>                 Client client= new Client();
>                 client.setIdentifier("123");
>                 return l_ client;
>         }
>
>
>
> Method2:
> The second method uses java primitives
>         public String getValue(String para) {
>                 return para;
>         }
>
>
> On the client side when I invoke method method2 , I did get the value
> "para" where as invoking method1 returns nothing. Do I need to do any
> mapping on my custom class "Client" somewhere?
>
>
> Code snippet to print outpuit on client side
> ...
>
>         OMElement result = serviceClient.sendReceive(getPayload());
>         System.out.println("Result=="+ l_ result);
> ..
>
> Here is my xml output (system out) on client side for method1
> <ns:getClientResponse xmlns:ns="http://org.apache.axis2/xsd"><return
> /><return /></ns: getClientResponse >
>
> (No data "123" in this XML)
>
>
> Any help is appreciated.
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Mime
View raw message