I want to write a location based Client/Server application - Java/Android. I'm new to this field. The application use the user location to provide it some information when he ask it. Should I run the "client" object that interacts with the server as a "service" from the main thread - UI thread of android app? (I thought maybe it can be useful for synching information with the server, like updating the server with GPS location and save the information relevant to this location in cache in the device, maybe update application version, and maybe things that will be useful and I cannot think about them now)
First, is this the right way to do it - using service class? Basically, the information can be given to the client only when he asks it specifically, but I thought maybe this way, I can improve the client experience (of course in the limits of the server ability to process the information from all the users)
second, is updating the server with the location is an operation that consumes a lot of battery? more than "regular applications" running on the device, like email, facebook, waze in non-navigating mode etc?
Aucun commentaire:
Enregistrer un commentaire