AI-generated Key Takeaways
-
Navigator.TaskRemovedBehaviordefines how the navigation service behaves when the user removes the app from the recents screen. -
It offers two constants:
CONTINUE_SERVICE(default) which keeps navigation running, andQUIT_SERVICEwhich stops it immediately. -
This behavior is controlled using
Navigator.setTaskRemovedBehavior(int). -
CONTINUE_SERVICEensures navigation guidance, location updates, and notifications continue even after the app is removed from recents. -
QUIT_SERVICEimmediately shuts down navigation guidance, location updates, and notifications upon app removal from recents.
TaskRemovedBehavior is a set of constants that may be passed to Navigator.setTaskRemovedBehavior(int) to configure how the background service responds when the user
removes away the application's task from Android's recents screen.
Constant Summary
| int | CONTINUE_SERVICE | The default state, indicating that navigation guidance, location updates, and notification should persist after the user removes the task. |
| int | QUIT_SERVICE | Indicates that navigation guidance, location updates, and notification should shut down immediately when the user removes the task. |
Inherited Method Summary
Constants
public static final int CONTINUE_SERVICE
The default state, indicating that navigation guidance, location updates, and notification should persist after the user removes the task.
public static final int QUIT_SERVICE
Indicates that navigation guidance, location updates, and notification should shut down immediately when the user removes the task.