Начиная с 27 марта 2025 г. мы рекомендуем использовать android-latest-release
вместо aosp-main
для создания и участия в AOSP. Дополнительные сведения см. в разделе Изменения в AOSP .
Оптимизируйте свои подборки
Сохраняйте и классифицируйте контент в соответствии со своими настройками.
Справочник по структуре GeofenceOptions
#include < fused_location.h >
Параметры геозоны
Определение в строке 714 файла Fused_location.h .
Текущее состояние геозоны. Например, если система уже знает, что пользователь находится внутри геозоны, для этого параметра будет установлено значение FLP_GEOFENCE_TRANSITION_ENTERED. В большинстве случаев это будет FLP_GEOFENCE_TRANSITION_UNCERTAIN.
Определение в строке 720 файла Fused_location.h .
Переходы для мониторинга. Побитовое ИЛИ для FLP_GEOFENCE_TRANSITION_ENTERED, FLP_GEOFENCE_TRANSITION_EXITED и FLP_GEOFENCE_TRANSITION_UNCERTAIN.
Определение в строке 727 файла Fused_location.h .
int Notification_Responsenes_ms |
Определяет максимально возможное описание того, как скоро должен быть вызван обратный вызов при срабатывании перехода, связанного с геозоной . Например, если с помощью FLP_GEOFENCE_TRANSITION_ENTERED установлено значение 1000 миллисекунд, обратный вызов должен быть вызван через 1000 миллисекунд при входе в геозону. Этот параметр определяется в миллисекундах. ПРИМЕЧАНИЕ. Не следует путать это значение со скоростью опроса GPS. Допускается динамическое изменение частоты выборки GPS из соображений энергосбережения; таким образом, скорость выборки может быть выше или медленнее этой.
Определение в строке 741 файла Fused_location.h .
Источники, используемые для мониторинга геозон. Это побитовое ИЛИ флагов FLP_TECH_MASK.
Определение в строке 753 файла Fused_location.h .
интервал неизвестного_таймер_мс |
Ограничение времени, по истечении которого должен сработать переход НЕОПРЕДЕЛЕННО. Этот параметр определяется в миллисекундах.
Определение в строке 747 файла Fused_location.h .
Документация для этой структуры была создана из следующего файла:
Контент и образцы кода на этой странице предоставлены по лицензиям. Java и OpenJDK – это зарегистрированные товарные знаки корпорации Oracle и ее аффилированных лиц.
Последнее обновление: 2025-07-29 UTC.
[[["Прост для понимания","easyToUnderstand","thumb-up"],["Помог мне решить мою проблему","solvedMyProblem","thumb-up"],["Другое","otherUp","thumb-up"]],[["Отсутствует нужная мне информация","missingTheInformationINeed","thumb-down"],["Слишком сложен/слишком много шагов","tooComplicatedTooManySteps","thumb-down"],["Устарел","outOfDate","thumb-down"],["Проблема с переводом текста","translationIssue","thumb-down"],["Проблемы образцов/кода","samplesCodeIssue","thumb-down"],["Другое","otherDown","thumb-down"]],["Последнее обновление: 2025-07-29 UTC."],[],[],null,["# Android Hardware Abstraction Layer: GeofenceOptions Struct Reference\n\nGeofenceOptions Struct Reference\n================================\n\n[Data Fields](#pub-attribs) \nGeofenceOptions Struct Reference \n\n`\n#include \u003c\n`[fused_location.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)`\n\u003e\n`\n\n|----------|-----------------------------------------------------------------------------------------------------------|\n| Data Fields ----------- ||\n| int | [last_transition](/reference/hal/struct_geofence_options#ac9f3044df5a350d9a141c36631daa4d8) |\n| ||\n| int | [monitor_transitions](/reference/hal/struct_geofence_options#a0c48726615ba0e8f18e47cbe3d6e7873) |\n| ||\n| int | [notification_responsivenes_ms](/reference/hal/struct_geofence_options#a759888e878e11256a8021d3cd3d8e12a) |\n| ||\n| int | [unknown_timer_ms](/reference/hal/struct_geofence_options#a2d1b6a36f124a618cbebc3f79977233b) |\n| ||\n| uint32_t | [sources_to_use](/reference/hal/struct_geofence_options#a352dd652f7b9c6033433ad53089fe281) |\n| ||\n\n\nDetailed Description\n--------------------\n\n\n[Geofence](/reference/hal/struct_geofence)\nOptions\n\n\nDefinition at line\n[714](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\nof file\n[fused_location.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\n.\n\nField Documentation\n-------------------\n\n\n|---------------------|\n| int last_transition |\n\n\nThe current state of the geofence. For example, if the system already knows that the user is inside the geofence, this will be set to FLP_GEOFENCE_TRANSITION_ENTERED. In most cases, it will be FLP_GEOFENCE_TRANSITION_UNCERTAIN.\n\n\nDefinition at line\n[720](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\nof file\n[fused_location.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\n.\n\n|-------------------------|\n| int monitor_transitions |\n\n\nTransitions to monitor. Bitwise OR of FLP_GEOFENCE_TRANSITION_ENTERED, FLP_GEOFENCE_TRANSITION_EXITED and FLP_GEOFENCE_TRANSITION_UNCERTAIN.\n\n\nDefinition at line\n[727](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\nof file\n[fused_location.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\n.\n\n|-----------------------------------|\n| int notification_responsivenes_ms |\n\n\nDefines the best-effort description of how soon should the callback be called when the transition associated with the\n[Geofence](/reference/hal/struct_geofence)\nis triggered. For instance, if set to 1000 millseconds with FLP_GEOFENCE_TRANSITION_ENTERED, the callback should be called 1000 milliseconds within entering the geofence. This parameter is defined in milliseconds. NOTE: This is not to be confused with the rate that the GPS is polled at. It is acceptable to dynamically vary the rate of sampling the GPS for power-saving reasons; thus the rate of sampling may be faster or slower than this.\n\n\nDefinition at line\n[741](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\nof file\n[fused_location.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\n.\n\n|-------------------------|\n| uint32_t sources_to_use |\n\n\nThe sources to use for monitoring geofences. Its a BITWISE-OR of FLP_TECH_MASK flags.\n\n\nDefinition at line\n[753](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\nof file\n[fused_location.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\n.\n\n|----------------------|\n| int unknown_timer_ms |\n\n\nThe time limit after which the UNCERTAIN transition should be triggered. This paramter is defined in milliseconds.\n\n\nDefinition at line\n[747](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\nof file\n[fused_location.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)\n.\n\n*** ** * ** ***\n\nThe documentation for this struct was generated from the following file:\n\n- hardware/libhardware/include/hardware/ [fused_location.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/fused_location.h)"]]