Hi
On 26/03/12 16:49, Ganesan, Chandru wrote:

Hi

I'm using a simple rest client that executes a query and gets String response. 
I'm using WebClient.get(...) to execute the REST call as follows.

Response jsonResponse = oneViewWebClient.get();

I do see the response code of 200 in the jsonResponse object but unable to 
access the string value from the returned response. In this case, I'd like to 
parse the response using jsonResponse.getEntity(..) I'm not using JAXB to 
deserialize the object, since it's a string is there a simple method to parse 
the response?


String str = oneViewWebClient.get(String.class);
should do it, you can also get the Response:
oneViewWebClient.getResponse()

Cheers, Sergey

Thanks
Chandru




--
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Blog: http://sberyozkin.blogspot.com

Reply via email to