Latest Google Play Services SDK Includes LocationServices APIs

Google's 11.0.0 release of its Google Play services SDK reduces tedious, error-prone tasks through new location APIs. The new LocationServices APIs enable developers to retrieve device location, create geofences, trigger users to enable location services, and more. The LocationServices APIs streamline, and automate these processes which makes their use more beneficial, and less error-prone than continuing to do so through GoogleApiClient.

Prior to the new APIs, connections to such services required manual management. The new APIs automates the task, which eliminates some of the most common errors. Even if common code errors are avoided, certain limitations within the GoogleApiClient make the solution less than ideal. Setting up access in multiple activities is difficult; if the app doesn't connect to Google Play services, the case isn't handled; quite a bit of boilerplate connection logic is required; and much more makes the new release a welcome site.

Google lists a number of ways in which the new LocationServices APIs will benefit code immediately. First, API calls automatically wait for service connection, so there is no longer a need for onConnected. Next, the Task API is used which streamlines asynchronous operation creation. Third, the code is self-contained which makes for simple sharing and movement. Finally, the need to understand underlying connection processes has gone away.

For those ready to jump in, check out the location samples on GitHub. Review the reference docs for specific details. For some quick examples of how code can be dramatically improved with the new APIs, check out Google's blog post announcement.

Eric Carter Eric the founder of Dartsand and Corporate Counsel for a specialty technology distributor. He is a frequent contributor to technology media outlets and also serves as primary legal counsel for multiple startups in the Real Estate, Virtual Assistant, and Software Development Industries. Follow me on Google+

Comments

Comments(1)

tutu18

That is a cool news, Eric. You shared cool stuff today.