Language

LocationManager.RegisterGnssNavigationMessageCallback Method

Definition

Overloads

Name Description
RegisterGnssNavigationMessageCallback(GnssNavigationMessage+Callback, Handler)

Registers a GNSS navigation message callback which will run on a binder thread.

RegisterGnssNavigationMessageCallback(IExecutor, GnssNavigationMessage+Callback)

Registers a GNSS navigation message callback which will run on a binder thread.

RegisterGnssNavigationMessageCallback(GnssNavigationMessage+Callback)

Registers a GNSS navigation message callback which will run on a binder thread.

RegisterGnssNavigationMessageCallback(GnssNavigationMessage+Callback, Handler)

Registers a GNSS navigation message callback which will run on a binder thread.

[Android.Runtime.Register("registerGnssNavigationMessageCallback", "(Landroid/location/GnssNavigationMessage$Callback;Landroid/os/Handler;)Z", "GetRegisterGnssNavigationMessageCallback_Landroid_location_GnssNavigationMessage_Callback_Landroid_os_Handler_Handler", ApiSince=24)]
[Android.Runtime.RequiresPermission("android.permission.ACCESS_FINE_LOCATION")]
public virtual bool RegisterGnssNavigationMessageCallback(Android.Locations.GnssNavigationMessage.Callback callback, Android.OS.Handler? handler);
[<Android.Runtime.Register("registerGnssNavigationMessageCallback", "(Landroid/location/GnssNavigationMessage$Callback;Landroid/os/Handler;)Z", "GetRegisterGnssNavigationMessageCallback_Landroid_location_GnssNavigationMessage_Callback_Landroid_os_Handler_Handler", ApiSince=24)>]
[<Android.Runtime.RequiresPermission("android.permission.ACCESS_FINE_LOCATION")>]
abstract member RegisterGnssNavigationMessageCallback : Android.Locations.GnssNavigationMessage.Callback * Android.OS.Handler -> bool
override this.RegisterGnssNavigationMessageCallback : Android.Locations.GnssNavigationMessage.Callback * Android.OS.Handler -> bool

Parameters

callback
GnssNavigationMessage.Callback

the callback to register

handler
Handler

the handler that the callback runs on. This value may be null.

Returns

true always

Attributes

Remarks

Registers a GNSS navigation message callback.

See registerGnssNavigationMessageCallback(Executor,GnssNavigationMessage.Callback) for more detail on how this method works. Requires Manifest.permission.ACCESS_FINE_LOCATION

Android reference for android.location.LocationManager.registerGnssNavigationMessageCallback.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

RegisterGnssNavigationMessageCallback(IExecutor, GnssNavigationMessage+Callback)

Registers a GNSS navigation message callback which will run on a binder thread.

[Android.Runtime.Register("registerGnssNavigationMessageCallback", "(Ljava/util/concurrent/Executor;Landroid/location/GnssNavigationMessage$Callback;)Z", "GetRegisterGnssNavigationMessageCallback_Ljava_util_concurrent_Executor_Landroid_location_GnssNavigationMessage_Callback_Handler", ApiSince=30)]
[Android.Runtime.RequiresPermission("android.permission.ACCESS_FINE_LOCATION")]
public virtual bool RegisterGnssNavigationMessageCallback(Java.Util.Concurrent.IExecutor executor, Android.Locations.GnssNavigationMessage.Callback callback);
[<Android.Runtime.Register("registerGnssNavigationMessageCallback", "(Ljava/util/concurrent/Executor;Landroid/location/GnssNavigationMessage$Callback;)Z", "GetRegisterGnssNavigationMessageCallback_Ljava_util_concurrent_Executor_Landroid_location_GnssNavigationMessage_Callback_Handler", ApiSince=30)>]
[<Android.Runtime.RequiresPermission("android.permission.ACCESS_FINE_LOCATION")>]
abstract member RegisterGnssNavigationMessageCallback : Java.Util.Concurrent.IExecutor * Android.Locations.GnssNavigationMessage.Callback -> bool
override this.RegisterGnssNavigationMessageCallback : Java.Util.Concurrent.IExecutor * Android.Locations.GnssNavigationMessage.Callback -> bool

Parameters

executor
IExecutor

the executor that the callback runs on. This value cannot be null. Callback and listener events are dispatched through this Executor, providing an easy way to control which thread is used. To dispatch events through the main thread of your application, you can use Context.getMainExecutor(). Otherwise, provide an Executor that dispatches to an appropriate thread.

callback
GnssNavigationMessage.Callback

the callback to register

Returns

true always

Attributes

Remarks

Registers a GNSS navigation message callback. GNSS navigation messages will only be received while the GPS_PROVIDER is enabled, and while the client app is in the foreground.

Not all GNSS chipsets support navigation message updates, see getGnssCapabilities(). Requires Manifest.permission.ACCESS_FINE_LOCATION

Android reference for android.location.LocationManager.registerGnssNavigationMessageCallback.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

RegisterGnssNavigationMessageCallback(GnssNavigationMessage+Callback)

Registers a GNSS navigation message callback which will run on a binder thread.

[Android.Runtime.Register("registerGnssNavigationMessageCallback", "(Landroid/location/GnssNavigationMessage$Callback;)Z", "GetRegisterGnssNavigationMessageCallback_Landroid_location_GnssNavigationMessage_Callback_Handler", ApiSince=24)]
public virtual bool RegisterGnssNavigationMessageCallback(Android.Locations.GnssNavigationMessage.Callback callback);
[<Android.Runtime.Register("registerGnssNavigationMessageCallback", "(Landroid/location/GnssNavigationMessage$Callback;)Z", "GetRegisterGnssNavigationMessageCallback_Landroid_location_GnssNavigationMessage_Callback_Handler", ApiSince=24)>]
abstract member RegisterGnssNavigationMessageCallback : Android.Locations.GnssNavigationMessage.Callback -> bool
override this.RegisterGnssNavigationMessageCallback : Android.Locations.GnssNavigationMessage.Callback -> bool

Parameters

callback
GnssNavigationMessage.Callback

the callback to register

Returns

true always

Attributes

Remarks

Java documentation for android.location.LocationManager.registerGnssNavigationMessageCallback(android.location.Callback).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to