1/*
2 * Copyright (c) 2021-2023 Huawei Device Co., Ltd.
3 * Licensed under the Apache License, Version 2.0 (the "License"),
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 *
7 *     http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
14 */
15
16/**
17 * @file
18 * @kit AbilityKit
19 */
20
21import Want from '../@ohos.app.ability.Want';
22
23/**
24 * Mission information corresponding to ability.
25 *
26 * @typedef MissionInfo
27 * @syscap SystemCapability.Ability.AbilityRuntime.Mission
28 * @systemapi
29 * @since 8
30 */
31export interface MissionInfo {
32  /**
33   * Indicates mission id.
34   *
35   * @type { number }
36   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
37   * @systemapi
38   * @since 8
39   */
40  missionId: number;
41
42  /**
43   * Indicates running state.
44   *
45   * @type { number }
46   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
47   * @systemapi
48   * @since 8
49   */
50  runningState: number;
51
52  /**
53   * Indicates locked state.
54   *
55   * @type { boolean }
56   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
57   * @systemapi
58   * @since 8
59   */
60  lockedState: boolean;
61
62  /**
63   * Indicates the recent created or updated time of the mission.
64   *
65   * @type { string }
66   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
67   * @systemapi
68   * @since 8
69   */
70  timestamp: string;
71
72  /**
73   * Indicates want of the mission.
74   *
75   * @type { Want }
76   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
77   * @systemapi
78   * @since 8
79   */
80  want: Want;
81
82  /**
83   * Indicates label of the mission.
84   *
85   * @type { string }
86   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
87   * @systemapi
88   * @since 8
89   */
90  label: string;
91
92  /**
93   * Indicates icon path of the mission.
94   *
95   * @type { string }
96   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
97   * @systemapi
98   * @since 8
99   */
100  iconPath: string;
101
102  /**
103   * Indicates whether the mission is continuable.
104   *
105   * @type { boolean }
106   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
107   * @systemapi
108   * @since 8
109   */
110  continuable: boolean;
111
112  /**
113   * Indicates the ability state of this mission.
114   *
115   * @type { number }
116   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
117   * @systemapi
118   * @since 10
119   */
120  abilityState: number;
121
122  /**
123   * Indicates whether the mission is unclearable.
124   *
125   * @type { boolean }
126   * @syscap SystemCapability.Ability.AbilityRuntime.Mission
127   * @systemapi
128   * @since 10
129   */
130  unclearable: boolean;
131}
132