• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2009 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package android.location;
18 
19 import android.location.Location;
20 import android.net.NetworkInfo;
21 import android.os.Bundle;
22 
23 /**
24  * Binder interface for location providers.
25  *
26  * {@hide}
27  */
28 interface ILocationProvider {
requiresNetwork()29     boolean requiresNetwork();
requiresSatellite()30     boolean requiresSatellite();
requiresCell()31     boolean requiresCell();
hasMonetaryCost()32     boolean hasMonetaryCost();
supportsAltitude()33     boolean supportsAltitude();
supportsSpeed()34     boolean supportsSpeed();
supportsBearing()35     boolean supportsBearing();
getPowerRequirement()36     int getPowerRequirement();
getAccuracy()37     int getAccuracy();
enable()38     void enable();
disable()39     void disable();
isEnabled()40     boolean isEnabled();
getStatus(out Bundle extras)41     int getStatus(out Bundle extras);
getStatusUpdateTime()42     long getStatusUpdateTime();
enableLocationTracking(boolean enable)43     void enableLocationTracking(boolean enable);
setMinTime(long minTime)44     void setMinTime(long minTime);
updateNetworkState(int state, in NetworkInfo info)45     void updateNetworkState(int state, in NetworkInfo info);
updateLocation(in Location location)46     void updateLocation(in Location location);
sendExtraCommand(String command, inout Bundle extras)47     boolean sendExtraCommand(String command, inout Bundle extras);
addListener(int uid)48     void addListener(int uid);
removeListener(int uid)49     void removeListener(int uid);
50 }
51