-
Dec 2nd, 2010, 12:31 AM
#1
Spring Android Resttemplate postforobject
Hi all,
I'm trying to use android spring rest template to do a post request. And i need to return the status code. This is my approach.
<code>
RestTemplate restTemplate = new RestTemplate();
MultiValueMap mvm = new LinkedMultiValueMap();
mvm.add("login", "100"); // and some more paramters
String result = restTemplate.postForObject("http://localhost:8080/security_check", mvm, String.class);
</code>
But this approach doesn't work for me. It generates an error saying no suitable message converter found. And i need to know can i use the resttemplate to manage my sessions. I need to manage the session from the android client side.
If any one come across android resttemplate post method and session management please help me. Any help would be greatly appreciated.
Thanks in advance.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules