How to make a request for sending a list of rows in a rest client -Android
I am working on a REST client in android.My web service开发者_如何学Go is based on Rails.My scenario is that I have an class named user which has attributes like age,name,gender etc.I want to send a list of user objects to the server so that i can insert it into the database.Can someone let me know how i can do this using json?
Have your user class be a JSONObject and then post the objects to your server as JSON strings using JSONObject.quote()
and turn those strings back into arrays/objects at the server end.
精彩评论