I need to access a web service from a J2ME application. Any good advice or example about how to consume web services from this framework?
Asked
Active
Viewed 1,445 times
2 Answers
4
For SOAP webservices: If you have a J2ME device which has JSR 172, you can create webservice client stubs and call the webservice methods on those stubs. However, JSR 172 is not widely available on most of the devices. The better way would be to use KSOAP2 to create SOAP requests and invoke your webservice methods.
For REST web services: You would just need to use HTTP Connection classes.
For parsing the XML response, you can use KXML2. Its a good third party library.

Hetal Vora
- 3,341
- 2
- 28
- 53
-
please could you give us an example for REST web services – eddy May 17 '14 at 12:32
-
1@Hetal Vora , please do you think you could help me with this question http://stackoverflow.com/questions/23696897/how-to-consume-asp-net-web-api-from-a-java-me-application – Axel May 17 '14 at 12:48