summaryrefslogtreecommitdiffstats
path: root/docs/html/google/play-services/location.jd
blob: ddaa890c4893d54957c18f1b95fe5f552e598707 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
page.title=Location APIs
page.tags="location","geofence", "geofencing", "activity recognition", "activity detection", "gps"
header.hide=1
@jd:body


    <div class="landing-banner">

<div class="col-6">
    <img src="{@docRoot}images/google/gps-location.png" alt="Location APIs Logo">
</div>

<div class="col-6">

<h1 itemprop="name" style="margin-bottom:0;">Location APIs</h1>
<p itemprop="description">
    The location APIs make it easy for you to build location-aware applications, without needing to
    focus on the details of the underlying location technology. They also let you minimize
    power consumption by using all of the capabilities of the device hardware.
</p>

<p>
    To get started, first <a href="{@docRoot}google/play-services/setup.html">set up</a>
    the Google Play services SDK. You can learn how to use the APIs in the training
    class <a href="{@docRoot}training/location/index.html">Making Your App Location Aware</a>, 
    and details are available in the <a href="{@docRoot}reference/com/google/android/gms/location/package-summary.html">Location API reference</a>. <!-- To look at a code example, <a href="">download the sample app</a>. -->
</p>
</div>
</div>
<div class="landing-docs">
  <h3 style="clear:left">Key Developer Features</h3>
  <div class="layout-content-row">
  <div class="layout-content-col span-6">



<h4 style="font-weight:bold">Fused location provider</h4>

<p>The Fused Location Provider intelligently manages the underlying location technology and gives you the best location according to your needs. </p>

<ul>
    <li>
        <em>Simple APIs</em>: Lets you specify high-level needs like "high accuracy" or "low power", instead of
        having to worry about location providers.
    </li>
    <li>
        <em>Immediately available</em>: Gives your apps immediate access to the best, most recent location.
    </li>
    <li>
        <em>Power-efficiency</em>: Minimizes your app's use of power. Based on all incoming location requests and available sensors, fused location provider chooses the most efficient way to meet those needs.
    </li>
    <li>
        <em>Versatility</em>: Meets a wide range of needs, from foreground uses that need highly accurate
        location to background uses that need periodic location updates with negligible power impact.
    </li>

</ul>

<h4 style="font-weight:bold">Geofencing APIs</h4>

<p>Lets your app setup geographic boundaries around specific locations and then receive notifications when the user enters or leaves those areas. </p>

<ul>
    <li>
        <em>Simple but powerful APIs</em>: Allows batch addition and removal of geofences. Ability to manage
        multiple geofences at the same time. Ability to filter alerts for both entry and exit or
        entry only or exit only.
    </li>
    <li>
        <em>Optimized for battery</em>: Adjusts location updates based on user’s proximity to the geofence
        and user’s modality (still, walking, driving, and so on).
    </li>
</ul>
</div>

<div class="layout-content-col span-6">
<h4 style="font-weight:bold">Activity recognition</h4>

<p>With apps becoming increasingly contextual, understanding what the user is doing is critical to surfacing the right content. The Activity recognition API makes it easy to check the user’s current activity&mdash;still, walking, cycling, and in-vehicle&mdash;with very efficient use of the battery.</p>
<ul>
    <li>
        <em>Optimized for battery</em>: Uses low-power sensors to recognize the user's current physical activity.
    </li>
    <li>
        <em>Enhances other services with context</em>: Great for adding movement awareness to location awareness. Apps can adjust the amount of
        location awareness they provide, based on the current user movement. For example, a
        navigation app can request more frequent updates when the user is driving.
    </li>
    <li>
        <em>Features for advanced applications</em>: For advanced applications that want to do their own
        post-processing, this API also makes available confidence values for each of the activities.
        It also includes two activities that indicate unreliable measurements: unknown and tilt.
    </li>
</ul>
</div>
</div>