LocationManager.RequestLocationUpdates メソッド

定義

オーバーロード

RequestLocationUpdates(String, LocationRequest, PendingIntent)

指定した プロバイダーから、指定された を介して配信された コールバックを使用して LocationRequest、場所の更新に PendingIntent登録します。

RequestLocationUpdates(Int64, Single, Criteria, PendingIntent)

指定された条件で選択されたプロバイダーと、指定 PendingIntentされた を介して配信されるコールバックを使用して、場所の更新に登録します。

RequestLocationUpdates(String, LocationRequest, IExecutor, ILocationListener)

を使用して、指定したプロバイダーからの場所の更新に登録し、指定した に対するコールバックを使用 LocationRequestします Executor

RequestLocationUpdates(String, Int64, Single, PendingIntent)

指定されたプロバイダーを使用して場所の更新を登録し、指定された を介して配信されるコールバックを登録 PendingIntentします。

RequestLocationUpdates(String, Int64, Single, ILocationListener)

指定されたプロバイダーからの場所の更新に、指定された引数と呼び出し元スレッドの コールバックを Looper 登録します。

RequestLocationUpdates(Int64, Single, Criteria, ILocationListener, Looper)

指定した抽出条件で選択したプロバイダーと、指定した に対するコールバックを使用して、場所の更新に登録します Looper

RequestLocationUpdates(Int64, Single, Criteria, IExecutor, ILocationListener)

指定した抽出条件で選択したプロバイダーと、指定した に対するコールバックを使用して、場所の更新に登録します Executor

RequestLocationUpdates(String, Int64, Single, ILocationListener, Looper)

指定したプロバイダーからの場所の更新に、指定された引数と、指定した に対するコールバックを登録します Looper

RequestLocationUpdates(String, Int64, Single, IExecutor, ILocationListener)

名前付きプロバイダーと、指定した に対するコールバックを使用して、場所の更新に登録します Executor

RequestLocationUpdates(String, LocationRequest, PendingIntent)

指定した プロバイダーから、指定された を介して配信された コールバックを使用して LocationRequest、場所の更新に PendingIntent登録します。

[Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;Landroid/location/LocationRequest;Landroid/app/PendingIntent;)V", "GetRequestLocationUpdates_Ljava_lang_String_Landroid_location_LocationRequest_Landroid_app_PendingIntent_Handler", ApiSince=31)]
public virtual void RequestLocationUpdates (string provider, Android.Locations.LocationRequest locationRequest, Android.App.PendingIntent pendingIntent);
[<Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;Landroid/location/LocationRequest;Landroid/app/PendingIntent;)V", "GetRequestLocationUpdates_Ljava_lang_String_Landroid_location_LocationRequest_Landroid_app_PendingIntent_Handler", ApiSince=31)>]
abstract member RequestLocationUpdates : string * Android.Locations.LocationRequest * Android.App.PendingIntent -> unit
override this.RequestLocationUpdates : string * Android.Locations.LocationRequest * Android.App.PendingIntent -> unit

パラメーター

provider
String

一覧表示されるプロバイダー #getAllProviders()

locationRequest
LocationRequest

場所パラメーターを含む場所要求

pendingIntent
PendingIntent

場所の更新を送信する保留中の意図

属性

注釈

指定した プロバイダーから、指定された を介して配信された コールバックを使用して LocationRequest、場所の更新に PendingIntent登録します。

配信された保留中の意図には、コールバック情報を含む追加情報が含まれます。 extras に使用されるキーは と #KEY_PROVIDER_ENABLEDです#KEY_LOCATION_CHANGED。 値の詳細については、それぞれの追加キーのドキュメントを参照してください。

場所の更新の登録を解除するには、 を使用します #removeUpdates(PendingIntent)

の Java ドキュメント android.location.LocationManager.requestLocationUpdates(java.lang.String, android.location.LocationRequest, android.app.PendingIntent)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象

RequestLocationUpdates(Int64, Single, Criteria, PendingIntent)

指定された条件で選択されたプロバイダーと、指定 PendingIntentされた を介して配信されるコールバックを使用して、場所の更新に登録します。

[Android.Runtime.Register("requestLocationUpdates", "(JFLandroid/location/Criteria;Landroid/app/PendingIntent;)V", "GetRequestLocationUpdates_JFLandroid_location_Criteria_Landroid_app_PendingIntent_Handler")]
public virtual void RequestLocationUpdates (long minTimeMs, float minDistanceM, Android.Locations.Criteria criteria, Android.App.PendingIntent pendingIntent);
[<Android.Runtime.Register("requestLocationUpdates", "(JFLandroid/location/Criteria;Landroid/app/PendingIntent;)V", "GetRequestLocationUpdates_JFLandroid_location_Criteria_Landroid_app_PendingIntent_Handler")>]
abstract member RequestLocationUpdates : int64 * single * Android.Locations.Criteria * Android.App.PendingIntent -> unit
override this.RequestLocationUpdates : int64 * single * Android.Locations.Criteria * Android.App.PendingIntent -> unit

パラメーター

minTimeMs
Int64

場所の更新間隔の最小時間間隔 (ミリ秒単位)

minDistanceM
Single

場所の更新間の最小距離 (メートル単位)

criteria
Criteria

には、場所の更新に適したプロバイダーを選択するためのパラメーターが含まれています

pendingIntent
PendingIntent

場所の更新を送信する保留中の意図

属性

例外

criteria が null の場合

意図が null の場合

適切なアクセス許可がない場合

注釈

指定された条件で選択されたプロバイダーと、指定 PendingIntentされた を介して配信されるコールバックを使用して、場所の更新に登録します。

注: Android KitKat 以降、Criteria 要求では常に が使用されます #FUSED_PROVIDER

このメソッドの動作の詳細については、 を参照してください #requestLocationUpdates(String, long, float, PendingIntent)

このメンバーは非推奨とされます。 代わりに を使用 #requestLocationUpdates(String, long, float, PendingIntent) して、プロバイダーを明示的に選択します。

の Java ドキュメント android.location.LocationManager.requestLocationUpdates(long, float, android.location.Criteria, android.app.PendingIntent)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象

RequestLocationUpdates(String, LocationRequest, IExecutor, ILocationListener)

を使用して、指定したプロバイダーからの場所の更新に登録し、指定した に対するコールバックを使用 LocationRequestします Executor

[Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;Landroid/location/LocationRequest;Ljava/util/concurrent/Executor;Landroid/location/LocationListener;)V", "GetRequestLocationUpdates_Ljava_lang_String_Landroid_location_LocationRequest_Ljava_util_concurrent_Executor_Landroid_location_LocationListener_Handler", ApiSince=31)]
public virtual void RequestLocationUpdates (string provider, Android.Locations.LocationRequest locationRequest, Java.Util.Concurrent.IExecutor executor, Android.Locations.ILocationListener listener);
[<Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;Landroid/location/LocationRequest;Ljava/util/concurrent/Executor;Landroid/location/LocationListener;)V", "GetRequestLocationUpdates_Ljava_lang_String_Landroid_location_LocationRequest_Ljava_util_concurrent_Executor_Landroid_location_LocationListener_Handler", ApiSince=31)>]
abstract member RequestLocationUpdates : string * Android.Locations.LocationRequest * Java.Util.Concurrent.IExecutor * Android.Locations.ILocationListener -> unit
override this.RequestLocationUpdates : string * Android.Locations.LocationRequest * Java.Util.Concurrent.IExecutor * Android.Locations.ILocationListener -> unit

パラメーター

provider
String

一覧表示されるプロバイダー #getAllProviders()

locationRequest
LocationRequest

場所パラメーターを含む場所要求

executor
IExecutor

Executor でリスナー コールバックを処理する

listener
ILocationListener

場所の更新を受信するリスナー

属性

注釈

を使用して、指定したプロバイダーからの場所の更新に登録し、指定した に対するコールバックを使用 LocationRequestします Executor

一意のリスナーとプロバイダーのペアごとに登録できる要求は 1 つだけであるため、同じプロバイダーとリスナーを持つ後続の要求では、関連付けられているすべての引数が上書きされます。 同じリスナーは、プロバイダーごとに異なる要求を持つ複数のプロバイダーで使用できます。

デバイスが自身を見つける条件によっては、最初の場所の更新プログラムを受信するまでに時間がかかる場合があります。 キャッシュされた場所を利用するために、アプリケーションでは、 または #getCurrentLocation(String, LocationRequest, CancellationSignal, Executor, Consumer) を代わりに使用#getLastKnownLocation(String)することを検討できます。

さまざまな要求パラメーターの説明と、それらが受信した場所に与える影響については、ドキュメントを参照 LocationRequest してください。

アプリケーションで、すべてのプロバイダーからの場所の更新を受動的に監視する場合は、 を使用します #PASSIVE_PROVIDER。 このプロバイダーはアクティブな場所プロバイダーをオンまたは変更しないため、最小時間と最小距離のパラメーターに注意する必要はありません。 ただし、アプリケーションが場所の更新 (ネットワーク アクティビティなど) に対して大量の作業を実行する場合は、別のアプリケーションで非常に高速な更新プログラムを使用して場所プロバイダーを有効にした場合に備えて、場所要求に明示的に最速の間隔を設定する必要があります。

選択したプロバイダーが無効になっている場合、場所の更新は中止され、プロバイダーの可用性更新プログラムが送信されます。 プロバイダーが再度有効になるとすぐに、別のプロバイダーの可用性更新プログラムが送信され、場所の更新が再開されます。

から #GPS_PROVIDER 返される場所は、デバイス内のプライマリ GNSS アンテナ位置に関してです。 #getGnssAntennaInfos() は、Android 座標系に関して GNSS アンテナの位置を決定し、必要に応じてそれらの間で変換するために使用できます。 これは一般に、高い精度のアプリケーションにのみ必要です。

場所のコールバックが呼び出されると、システムはアプリケーションの代わりに一定期間ウェイクロックを保持しますが、無期限ではありません。 アプリケーションで場所コールバック内で実行時間の長いウェイクロックが必要な場合は、自分で取得する必要があります。

場所の要求のスパミングはシステム リソースのドレインであり、システムには予防措置が講じられ、この動作により、1 つの場所要求で達成できる場所よりも多くの場所が発生することがないようにするための予防措置が講じられ、同じ間隔で全体の時間が残ります。 この改善の一環として、Android S 以上を対象とするアプリケーションは、リスナーを介してキャッシュされた場所または履歴の場所を受け取る可能性があります。 これらの場所は、場所要求の間隔よりも古くはありません。

場所の更新の登録を解除するには、 を使用します #removeUpdates(LocationListener)

の Java ドキュメント android.location.LocationManager.requestLocationUpdates(java.lang.String, android.location.LocationRequest, java.util.concurrent.Executor, android.location.LocationListener)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象

RequestLocationUpdates(String, Int64, Single, PendingIntent)

指定されたプロバイダーを使用して場所の更新を登録し、指定された を介して配信されるコールバックを登録 PendingIntentします。

[Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;JFLandroid/app/PendingIntent;)V", "GetRequestLocationUpdates_Ljava_lang_String_JFLandroid_app_PendingIntent_Handler")]
public virtual void RequestLocationUpdates (string provider, long minTimeMs, float minDistanceM, Android.App.PendingIntent pendingIntent);
[<Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;JFLandroid/app/PendingIntent;)V", "GetRequestLocationUpdates_Ljava_lang_String_JFLandroid_app_PendingIntent_Handler")>]
abstract member RequestLocationUpdates : string * int64 * single * Android.App.PendingIntent -> unit
override this.RequestLocationUpdates : string * int64 * single * Android.App.PendingIntent -> unit

パラメーター

provider
String

一覧表示されるプロバイダー #getAllProviders()

minTimeMs
Int64

場所の更新間隔の最小時間間隔 (ミリ秒単位)

minDistanceM
Single

場所の更新間の最小距離 (メートル単位)

pendingIntent
PendingIntent

場所の更新を送信する保留中の意図

属性

例外

プロバイダーが null であるか、このデバイスに存在しない場合

意図が null の場合

適切なアクセス許可がない場合

注釈

指定されたプロバイダーを使用して場所の更新を登録し、指定された を介して配信されるコールバックを登録 PendingIntentします。

このメソッドの動作の詳細については、 を参照してください #requestLocationUpdates(String, LocationRequest, PendingIntent)

の Java ドキュメント android.location.LocationManager.requestLocationUpdates(java.lang.String, long, float, android.app.PendingIntent)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象

RequestLocationUpdates(String, Int64, Single, ILocationListener)

指定されたプロバイダーからの場所の更新に、指定された引数と呼び出し元スレッドの コールバックを Looper 登録します。

[Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;JFLandroid/location/LocationListener;)V", "GetRequestLocationUpdates_Ljava_lang_String_JFLandroid_location_LocationListener_Handler")]
public virtual void RequestLocationUpdates (string provider, long minTimeMs, float minDistanceM, Android.Locations.ILocationListener listener);
[<Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;JFLandroid/location/LocationListener;)V", "GetRequestLocationUpdates_Ljava_lang_String_JFLandroid_location_LocationListener_Handler")>]
abstract member RequestLocationUpdates : string * int64 * single * Android.Locations.ILocationListener -> unit
override this.RequestLocationUpdates : string * int64 * single * Android.Locations.ILocationListener -> unit

パラメーター

provider
String

一覧表示されるプロバイダー #getAllProviders()

minTimeMs
Int64

場所の更新間隔の最小時間間隔 (ミリ秒単位)

minDistanceM
Single

場所の更新間の最小距離 (メートル単位)

listener
ILocationListener

場所の更新を受信するリスナー

属性

例外

プロバイダーが null であるか、このデバイスに存在しない場合

リスナーが null の場合

呼び出し元のスレッドにルーパーがない場合

適切なアクセス許可がない場合

注釈

指定されたプロバイダーからの場所の更新に、指定された引数と呼び出し元スレッドの コールバックを Looper 登録します。

このメソッドの動作の詳細については、 を参照してください #requestLocationUpdates(String, LocationRequest, Executor, LocationListener)

<p class="note"> Jellybean より前では、minTime パラメーターはヒントのみで、一部の場所プロバイダーの実装では無視されていました。 ただし、Jellybean 以降では、Android 互換デバイスでは minTime パラメーターと minDistance パラメーターの両方を確認する必要があります。

の Java ドキュメント android.location.LocationManager.requestLocationUpdates(java.lang.String, long, float, android.location.LocationListener)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象

RequestLocationUpdates(Int64, Single, Criteria, ILocationListener, Looper)

指定した抽出条件で選択したプロバイダーと、指定した に対するコールバックを使用して、場所の更新に登録します Looper

[Android.Runtime.Register("requestLocationUpdates", "(JFLandroid/location/Criteria;Landroid/location/LocationListener;Landroid/os/Looper;)V", "GetRequestLocationUpdates_JFLandroid_location_Criteria_Landroid_location_LocationListener_Landroid_os_Looper_Handler")]
public virtual void RequestLocationUpdates (long minTimeMs, float minDistanceM, Android.Locations.Criteria criteria, Android.Locations.ILocationListener listener, Android.OS.Looper? looper);
[<Android.Runtime.Register("requestLocationUpdates", "(JFLandroid/location/Criteria;Landroid/location/LocationListener;Landroid/os/Looper;)V", "GetRequestLocationUpdates_JFLandroid_location_Criteria_Landroid_location_LocationListener_Landroid_os_Looper_Handler")>]
abstract member RequestLocationUpdates : int64 * single * Android.Locations.Criteria * Android.Locations.ILocationListener * Android.OS.Looper -> unit
override this.RequestLocationUpdates : int64 * single * Android.Locations.Criteria * Android.Locations.ILocationListener * Android.OS.Looper -> unit

パラメーター

minTimeMs
Int64

場所の更新間隔の最小時間間隔 (ミリ秒単位)

minDistanceM
Single

場所の更新間の最小距離 (メートル単位)

criteria
Criteria

には、場所の更新に適したプロバイダーを選択するためのパラメーターが含まれています

listener
ILocationListener

場所の更新を受信するリスナー

looper
Looper

メッセージ キューを使用してコールバック メカニズムを実装する Looper オブジェクト、または呼び出し元のスレッドでコールバックを行う場合は null

属性

例外

criteria が null の場合

リスナーが null の場合

適切なアクセス許可がない場合

注釈

指定した抽出条件で選択したプロバイダーと、指定した に対するコールバックを使用して、場所の更新に登録します Looper

注: Android KitKat 以降、Criteria 要求では常に が使用されます #FUSED_PROVIDER

このメソッドの動作の詳細については、 を参照してください #requestLocationUpdates(String, LocationRequest, Executor, LocationListener)

このメンバーは非推奨とされます。 代わりに を使用 #requestLocationUpdates(String, long, float, LocationListener, Looper) して、プロバイダーを明示的に選択します。

の Java ドキュメント android.location.LocationManager.requestLocationUpdates(long, float, android.location.Criteria, android.location.LocationListener, android.os.Looper)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象

RequestLocationUpdates(Int64, Single, Criteria, IExecutor, ILocationListener)

指定した抽出条件で選択したプロバイダーと、指定した に対するコールバックを使用して、場所の更新に登録します Executor

[Android.Runtime.Register("requestLocationUpdates", "(JFLandroid/location/Criteria;Ljava/util/concurrent/Executor;Landroid/location/LocationListener;)V", "GetRequestLocationUpdates_JFLandroid_location_Criteria_Ljava_util_concurrent_Executor_Landroid_location_LocationListener_Handler", ApiSince=30)]
public virtual void RequestLocationUpdates (long minTimeMs, float minDistanceM, Android.Locations.Criteria criteria, Java.Util.Concurrent.IExecutor executor, Android.Locations.ILocationListener listener);
[<Android.Runtime.Register("requestLocationUpdates", "(JFLandroid/location/Criteria;Ljava/util/concurrent/Executor;Landroid/location/LocationListener;)V", "GetRequestLocationUpdates_JFLandroid_location_Criteria_Ljava_util_concurrent_Executor_Landroid_location_LocationListener_Handler", ApiSince=30)>]
abstract member RequestLocationUpdates : int64 * single * Android.Locations.Criteria * Java.Util.Concurrent.IExecutor * Android.Locations.ILocationListener -> unit
override this.RequestLocationUpdates : int64 * single * Android.Locations.Criteria * Java.Util.Concurrent.IExecutor * Android.Locations.ILocationListener -> unit

パラメーター

minTimeMs
Int64

場所の更新間隔の最小時間間隔 (ミリ秒単位)

minDistanceM
Single

場所の更新間の最小距離 (メートル単位)

criteria
Criteria

には、場所の更新に適したプロバイダーを選択するためのパラメーターが含まれています

executor
IExecutor

Executor でリスナー コールバックを処理する

listener
ILocationListener

場所の更新を受信するリスナー

属性

注釈

指定した抽出条件で選択したプロバイダーと、指定した に対するコールバックを使用して、場所の更新に登録します Executor

注: Android KitKat 以降、Criteria 要求では常に が使用されます #FUSED_PROVIDER

このメソッドの動作の詳細については、 を参照してください #requestLocationUpdates(String, LocationRequest, Executor, LocationListener)

このメンバーは非推奨とされます。 代わりに を使用 #requestLocationUpdates(String, long, float, Executor, LocationListener) して、プロバイダーを明示的に選択します。

の Java ドキュメント android.location.LocationManager.requestLocationUpdates(long, float, android.location.Criteria, java.util.concurrent.Executor, android.location.LocationListener)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象

RequestLocationUpdates(String, Int64, Single, ILocationListener, Looper)

指定したプロバイダーからの場所の更新に、指定された引数と、指定した に対するコールバックを登録します Looper

[Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;JFLandroid/location/LocationListener;Landroid/os/Looper;)V", "GetRequestLocationUpdates_Ljava_lang_String_JFLandroid_location_LocationListener_Landroid_os_Looper_Handler")]
public virtual void RequestLocationUpdates (string provider, long minTimeMs, float minDistanceM, Android.Locations.ILocationListener listener, Android.OS.Looper? looper);
[<Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;JFLandroid/location/LocationListener;Landroid/os/Looper;)V", "GetRequestLocationUpdates_Ljava_lang_String_JFLandroid_location_LocationListener_Landroid_os_Looper_Handler")>]
abstract member RequestLocationUpdates : string * int64 * single * Android.Locations.ILocationListener * Android.OS.Looper -> unit
override this.RequestLocationUpdates : string * int64 * single * Android.Locations.ILocationListener * Android.OS.Looper -> unit

パラメーター

provider
String

一覧表示されるプロバイダー #getAllProviders()

minTimeMs
Int64

場所の更新間隔の最小時間間隔 (ミリ秒単位)

minDistanceM
Single

場所の更新間の最小距離 (メートル単位)

listener
ILocationListener

場所の更新を受信するリスナー

looper
Looper

呼び出し元スレッドのルーパーを使用する場合は、ルーパー処理リスナー コールバック、または null

属性

例外

プロバイダーが null であるか、存在しない場合

リスナーが null の場合

適切なアクセス許可がない場合

注釈

指定したプロバイダーからの場所の更新に、指定された引数と、指定した に対するコールバックを登録します Looper

このメソッドの動作の詳細については、 を参照してください #requestLocationUpdates(String, LocationRequest, Executor, LocationListener)

<p class="note">Jellybean より前のバージョンでは、minTime パラメーターはヒントのみで、一部の場所プロバイダーの実装では無視されていました。 ただし、Jellybean 以降では、Android 互換デバイスでは minTime パラメーターと minDistance パラメーターの両方を確認する必要があります。

の Java ドキュメント android.location.LocationManager.requestLocationUpdates(java.lang.String, long, float, android.location.LocationListener, android.os.Looper)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象

RequestLocationUpdates(String, Int64, Single, IExecutor, ILocationListener)

名前付きプロバイダーと、指定した に対するコールバックを使用して、場所の更新に登録します Executor

[Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;JFLjava/util/concurrent/Executor;Landroid/location/LocationListener;)V", "GetRequestLocationUpdates_Ljava_lang_String_JFLjava_util_concurrent_Executor_Landroid_location_LocationListener_Handler", ApiSince=30)]
public virtual void RequestLocationUpdates (string provider, long minTimeMs, float minDistanceM, Java.Util.Concurrent.IExecutor executor, Android.Locations.ILocationListener listener);
[<Android.Runtime.Register("requestLocationUpdates", "(Ljava/lang/String;JFLjava/util/concurrent/Executor;Landroid/location/LocationListener;)V", "GetRequestLocationUpdates_Ljava_lang_String_JFLjava_util_concurrent_Executor_Landroid_location_LocationListener_Handler", ApiSince=30)>]
abstract member RequestLocationUpdates : string * int64 * single * Java.Util.Concurrent.IExecutor * Android.Locations.ILocationListener -> unit
override this.RequestLocationUpdates : string * int64 * single * Java.Util.Concurrent.IExecutor * Android.Locations.ILocationListener -> unit

パラメーター

provider
String

一覧表示されるプロバイダー #getAllProviders()

minTimeMs
Int64

場所の更新間隔の最小時間間隔 (ミリ秒単位)

minDistanceM
Single

場所の更新間の最小距離 (メートル単位)

executor
IExecutor

Executor でリスナー コールバックを処理する

listener
ILocationListener

場所の更新を受信するリスナー

属性

注釈

名前付きプロバイダーと、指定した に対するコールバックを使用して、場所の更新に登録します Executor

このメソッドの動作の詳細については、 を参照してください #requestLocationUpdates(String, LocationRequest, Executor, LocationListener)

<p class="note">Jellybean より前のバージョンでは、minTime パラメーターはヒントのみで、一部の場所プロバイダーの実装では無視されていました。 ただし、Jellybean 以降では、Android 互換デバイスでは minTime パラメーターと minDistance パラメーターの両方を確認する必要があります。

の Java ドキュメント android.location.LocationManager.requestLocationUpdates(java.lang.String, long, float, java.util.concurrent.Executor, android.location.LocationListener)

このページの一部は、によって作成および共有され、に記載されている条件に従って使用される作業に基づく変更です。

適用対象