harmony 鸿蒙Mission and Launch Type

  • 2023-02-03
  • 浏览 (676)

Mission and Launch Type

One UIAbility instance corresponds to one mission. The number of UIAbility instances is related to the UIAbility launch type, specified by launchType, which is configured in the config.json file in the FA model and the module.json5 file in the stage model.

The following describes how the mission list manager manages the UIAbility instanced started in different modes. - singleton: Only one UIAbility instance exists for an application.

Figure 1 Missions and singleton mode

mission-and-singleton

  • multiton: Each time startAbility() is called, a UIAbility instance is created in the application process.

Figure 2 Missions and multiton mode

mission-and-multiton

Figure 3 Missions and specified mode

mission-and-specified

Each UIAbility instance corresponds to a mission displayed in Recents.

Every mission retains a snapshot of the UIAbility instance. After the UIAbility instance is destroyed, the mission information (including the ability information and mission snapshot) is retained until the mission is deleted.

NOTE

The specified mode is supported in the stage model only.

你可能感兴趣的鸿蒙文章

harmony 鸿蒙Application Models

harmony 鸿蒙Using Explicit Want to Start an Application Component

harmony 鸿蒙Using Implicit Want to Open a Website

harmony 鸿蒙AbilityStage Component Container

harmony 鸿蒙Accessing a DataAbility

harmony 鸿蒙Accessing a DataShareExtensionAbility from the FA Model

harmony 鸿蒙AccessibilityExtensionAbility

harmony 鸿蒙Common action and entities Values

harmony 鸿蒙API Switching Overview

harmony 鸿蒙Switching of app and deviceConfig

0  赞