Hi, when I use that,
StringWriter writer = new
StringWriter();
IOUtils.copy(socket.getInputStream(),writer,HTTP.UTF_8);
String string = writer.toString();
Log.d("Writer value is : ",writer.toString());
Nothing is getting printed in console. Can you provide an example link?
On Wednesday, October 24, 2012 3:48:24 AM UTC+3, skink wrote:
>
>
>
> Archana wrote:
> > Hi, I did a HTTP Post from client. In server, I am able to see like,
> > POST /HTTP/ 1.1
> > Content Length: 41
> > Content-type: application/json
> > Host:10.0.2.15:5001
> > Connection: Keep Alive
> >
> > How do I retrieve the content of JSON using socket.getInputStream()?
> >
> > Any example/help is appreciated. Thanks in advance!
>
> http://www.google.com/search?q=inputstream+to+string
>
> pskink
>
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en