I do not know it is correct or not. But I did so:
@Post
public void login(JacksonRepresentation<Authentication> jackObj) throws
IOException {
Representation rep = jackObj;
JsonRepresentation jsonRep = new JsonRepresentation(rep);
try {
JSONObject jsonObj = jsonRep.getJsonObject();
String str = jsonObj.getString("login");
String str2 = jsonObj.getString("password");
System.out.println(str);
System.out.println(str2);
} catch (JSONException e) {
e.printStackTrace();
}
}
I think this is not effective, but I have no other choice
If anyone have suggestions on how to do it differently, write to, I will
try.
Let me remind you: GAE - server side, Android - client side
--
View this message in context:
http://restlet-discuss.1400322.n2.nabble.com/Restlet-Framework-Serialization-Don-t-understand-how-send-and-receive-object-tp7451788p7462149.html
Sent from the Restlet Discuss mailing list archive at Nabble.com.
------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2947990