Methods Summary |
---|
protected ListenerOperation | getHandlerOperation(int result)
final int status;
switch (result) {
case RESULT_SUCCESS:
status = GpsMeasurementsEvent.STATUS_READY;
break;
case RESULT_NOT_AVAILABLE:
case RESULT_NOT_SUPPORTED:
case RESULT_INTERNAL_ERROR:
status = GpsMeasurementsEvent.STATUS_NOT_SUPPORTED;
break;
case RESULT_GPS_LOCATION_DISABLED:
status = GpsMeasurementsEvent.STATUS_GPS_LOCATION_DISABLED;
break;
default:
Log.v(TAG, "Unhandled addListener result: " + result);
return null;
}
return new StatusChangedOperation(status);
|
protected void | handleGpsEnabledChanged(boolean enabled)
int status = enabled ?
GpsMeasurementsEvent.STATUS_READY :
GpsMeasurementsEvent.STATUS_GPS_LOCATION_DISABLED;
foreach(new StatusChangedOperation(status));
|
public void | onCapabilitiesUpdated(boolean isGpsMeasurementsSupported)
int status = isGpsMeasurementsSupported ?
GpsMeasurementsEvent.STATUS_READY :
GpsMeasurementsEvent.STATUS_NOT_SUPPORTED;
setSupported(isGpsMeasurementsSupported, new StatusChangedOperation(status));
|
public void | onMeasurementsAvailable(android.location.GpsMeasurementsEvent event)
ListenerOperation<IGpsMeasurementsListener> operation =
new ListenerOperation<IGpsMeasurementsListener>() {
@Override
public void execute(IGpsMeasurementsListener listener) throws RemoteException {
listener.onGpsMeasurementsReceived(event);
}
};
foreach(operation);
|