mode Introduction [1] Standard mode This is the default mode, the activity instance is created each time the activity is activated and placed in the task stack. [2] singletop mode If there is an instance of the activity at the top of the stack, the instance is reused (the onnewintent () of the instance is invoked), otherwise a new instance is created and placed on top of the stack. Even if an instance of the activity already exists in the stack, a new instance will be created as long as it is not on top of the stack. [3] Singletask mode If there is already an instance of the activity in the stack, the instance is reused (the onnewintent () of the instance is invoked). When reused, the instance is returned to the top of the stack, so instances above it will be moved out of the stack. If the instance does not exist in the stack, a new instance is created to be put into the stack. [4] singleinstance mode creates an instance of the activity in a new stack and lets multiple apps share the activity instance in that stack. Once the activity instance of the pattern already exists in a stack, any application that activates the activity will reuse the instance in that stack (the onnewintent () of the instance is invoked). The effect is that multiple apps share an app, regardless of who activates the Activity into the same app. Sets the location of the startup mode in the Androidmanifest.xml file for the Activity element's Android:launchmode property.
Application Scenario http: // www.intridea.com/blog/2011/6/16/android-understanding-activity-launchmodehttp:// Stackoverflow.com/questions/2626218/examples-for-android-launch-modes, B (singleinstance) C, after completely exiting, start here, first Open is B. Google Maps is used in an app, and when you exit the app, you get to Google Maps or just the interface
Android Launchmode (four startup modes) application scenarios and examples