/ohos5.0/docs/zh-cn/application-dev/reference/apis-ability-kit/ |
H A D | js-apis-wantAgent-sys.md | 1 # @ohos.wantAgent (WantAgent模块)(系统接口) 3 WantAgent模块提供了创建WantAgent实例、获取实例的用户ID、获取want信息、比较WantAgent实例和获取bundle名称等能力。 17 ## WantAgent.getWant 21 获取WantAgent中的Want(callback形式)。 37 import WantAgent, { WantAgent as _WantAgent} from '@ohos.wantAgent'; 61 WantAgent.getWantAgent({ 89 ## WantAgent.getWant 93 获取WantAgent中的Want(Promise形式)。 103 | agent | [WantAgent](js-apis-wantAgent-sys.md) | 是 | WantAgent信息。 | 114 import WantAgent, { WantAgent as _WantAgent} from '@ohos.wantAgent'; [all …]
|
H A D | js-apis-wantAgent.md | 1 # @ohos.wantAgent (WantAgent模块) 3 WantAgent模块提供了创建WantAgent实例、获取实例的用户ID、获取want信息、比较WantAgent实例和获取bundle名称等能力。 19 创建WantAgent(callback形式)。 创建失败返回的WantAgent为空值。 30 | callback | AsyncCallback\<WantAgent\> | 是 | 创建WantAgent的回调方法。 | 79 创建WantAgent(Promise形式)。 创建失败返回的WantAgent为空值。 95 | Promise\<WantAgent\> | 以Promise形式返回WantAgent。 | 219 | agent | WantAgent | 是 | WantAgent对象。 | 360 | agent | WantAgent | 是 | WantAgent对象。 | 500 | agent | WantAgent | 是 | WantAgent对象。 | 720 | agent | WantAgent | 是 | WantAgent对象。 | [all …]
|
H A D | js-apis-app-ability-wantAgent.md | 20 创建WantAgent(callback形式)。 创建失败返回的WantAgent为空值。 33 | callback | AsyncCallback\<WantAgent\> | 是 | 创建WantAgent的回调方法。 | 102 创建WantAgent(Promise形式)。 创建失败返回的WantAgent为空值。 120 | Promise\<WantAgent\> | 以Promise形式返回WantAgent。 | 288 | agent | WantAgent | 是 | WantAgent对象。 | 474 | agent | WantAgent | 是 | WantAgent对象。 | 661 | agent | WantAgent | 是 | WantAgent对象。 | 945 | agent | WantAgent | 是 | WantAgent对象。 | 946 | otherAgent | WantAgent | 是 | WantAgent对象。 | 952 | Promise\<boolean\> | 以Promise形式返回获取判断两个WantAgent实例是否相等的结果。返回true表示两个WantAgent实例相等,false表示两个WantAg… [all …]
|
H A D | js-apis-app-ability-wantAgent-sys.md | 1 # @ohos.app.ability.wantAgent (WantAgent模块)(系统接口) 3 app.ability.WantAgent模块提供了创建WantAgent实例、获取实例的用户ID、获取want信息、比较WantAgent实例和获取bundle名称等能力。该模块将会取代[@oho… 14 import { WantAgent } from '@kit.AbilityKit'; 17 ## WantAgent.getWant 21 获取WantAgent对象的want(callback形式)。 31 | agent | WantAgent | 是 | WantAgent对象。 | 112 ## WantAgent.getWant 114 getWant(agent: WantAgent): Promise\<Want\> 116 获取WantAgent对象的want(Promise形式)。 126 | agent | WantAgent | 是 | WantAgent对象。 | [all …]
|
/ohos5.0/docs/en/application-dev/reference/apis-ability-kit/ |
H A D | js-apis-wantAgent-sys.md | 1 # @ohos.wantAgent (WantAgent) (System API) 3 The **WantAgent** module provides APIs for creating and comparing **WantAgent** objects, and obtain… 17 ## WantAgent.getWant 37 import WantAgent, { WantAgent as _WantAgent} from '@ohos.wantAgent'; 41 // WantAgent object 61 WantAgent.getWantAgent({ 89 ## WantAgent.getWant 103 | agent | [WantAgent](js-apis-wantAgent-sys.md) | Yes | **WantAgent** object.| 114 import WantAgent, { WantAgent as _WantAgent} from '@ohos.wantAgent'; 117 // WantAgent object [all …]
|
H A D | js-apis-wantAgent.md | 1 # @ohos.wantAgent (WantAgent) 3 The **WantAgent** module provides APIs for creating and comparing **WantAgent** objects, and obtain… 155 // WantAgent object 219 | agent | WantAgent | Yes | **WantAgent** object.| 232 // WantAgent object 296 // WantAgent object 360 | agent | WantAgent | Yes | **WantAgent** object.| 500 | agent | WantAgent | Yes | **WantAgent** object.| 708 equal(agent: WantAgent, otherAgent: WantAgent): Promise\<boolean\> 720 | agent | WantAgent | Yes | The first **WantAgent** object.| [all …]
|
H A D | js-apis-app-ability-wantAgent.md | 53 // WantAgent object 121 | Promise\<WantAgent\> | Promise used to return the WantAgent object.| 216 // WantAgent object 289 | agent | WantAgent | Yes | Target WantAgent object.| 314 // WantAgent object 402 // WantAgent object 475 | agent | WantAgent | Yes | Target WantAgent object.| 662 | agent | WantAgent | Yes | Target WantAgent object.| 946 | agent | WantAgent | Yes | The first WantAgent object.| 947 | otherAgent | WantAgent | Yes | The second WantAgent object.| [all …]
|
H A D | js-apis-app-ability-wantAgent-sys.md | 1 # @ohos.app.ability.wantAgent (WantAgent) (System API) 14 import { WantAgent } from '@kit.AbilityKit'; 17 ## WantAgent.getWant 19 getWant(agent: WantAgent, callback: AsyncCallback\<Want\>): void 31 | agent | WantAgent | Yes | Target **WantAgent** object. | 51 // WantAgent object 112 ## WantAgent.getWant 114 getWant(agent: WantAgent): Promise\<Want\> 126 | agent | WantAgent | Yes | Target **WantAgent** object.| 153 // WantAgent object [all …]
|
/ohos5.0/foundation/ability/ability_runtime/interfaces/inner_api/wantagent/include/ |
H A D | want_agent_helper.h | 32 namespace OHOS::AbilityRuntime::WantAgent { 63 const WantAgentInfo ¶msInfo, std::shared_ptr<WantAgent> &wantAgent); 76 static std::shared_ptr<WantAgent> GetWantAgent(const WantAgentInfo ¶msInfo, 85 static WantAgentConstant::OperationType GetType(std::shared_ptr<WantAgent> agent); 86 static ErrCode GetType(const std::shared_ptr<WantAgent> &agent, int32_t &operType); 103 static ErrCode TriggerWantAgent(std::shared_ptr<WantAgent> agent, 115 static ErrCode Cancel(const std::shared_ptr<WantAgent> agent, uint32_t flags = FLAG_INVLID); 124 …static ErrCode IsEquals(const std::shared_ptr<WantAgent> &agent, const std::shared_ptr<WantAgent> … 142 static ErrCode GetUid(const std::shared_ptr<WantAgent> &agent, int32_t &uid); 150 static std::shared_ptr<AAFwk::Want> GetWant(const std::shared_ptr<WantAgent> &agent); [all …]
|
H A D | want_agent.h | 26 namespace OHOS::AbilityRuntime::WantAgent { 27 class WantAgent final : public std::enable_shared_from_this<WantAgent>, public Parcelable { 29 WantAgent() {}; in WantAgent() function 30 virtual ~WantAgent() = default; 36 explicit WantAgent(const std::shared_ptr<PendingWant> &pendingWant); 66 static WantAgent *Unmarshalling(Parcel &parcel);
|
/ohos5.0/foundation/ability/ability_runtime/interfaces/inner_api/wantagent/src/ |
H A D | want_agent.cpp | 20 namespace OHOS::AbilityRuntime::WantAgent { namespace 21 WantAgent::WantAgent(const std::shared_ptr<PendingWant> &pendingWant) in WantAgent() function in OHOS::AbilityRuntime::WantAgent::WantAgent 26 std::shared_ptr<PendingWant> WantAgent::GetPendingWant() in GetPendingWant() 31 void WantAgent::SetPendingWant(const std::shared_ptr<PendingWant> &pendingWant) in SetPendingWant() 36 bool WantAgent::Marshalling(Parcel &parcel) const in Marshalling() 46 WantAgent *WantAgent::Unmarshalling(Parcel &parcel) in Unmarshalling() 48 WantAgent *agent = new (std::nothrow) WantAgent(); in Unmarshalling()
|
H A D | want_agent_helper.cpp | 31 namespace OHOS::AbilityRuntime::WantAgent { namespace 93 const WantAgentInfo ¶msInfo, std::shared_ptr<WantAgent> &wantAgent) in GetWantAgent() 145 wantAgent = std::make_shared<WantAgent>(pendingWant); in GetWantAgent() 181 …std::shared_ptr<WantAgent> agent = std::make_shared<WantAgent>(std::make_shared<PendingWant>(targe… in GetWantAgent() 186 WantAgentConstant::OperationType WantAgentHelper::GetType(std::shared_ptr<WantAgent> agent) in GetType() 195 ErrCode WantAgentHelper::TriggerWantAgent(std::shared_ptr<WantAgent> agent, in TriggerWantAgent() 230 ErrCode WantAgentHelper::Cancel(const std::shared_ptr<WantAgent> agent, uint32_t flags) in Cancel() 247 const std::shared_ptr<WantAgent> &agent, const std::shared_ptr<WantAgent> &otherAgent) in IsEquals() 276 ErrCode WantAgentHelper::GetUid(const std::shared_ptr<WantAgent> &agent, int32_t &uid) in GetUid() 292 std::shared_ptr<Want> WantAgentHelper::GetWant(const std::shared_ptr<WantAgent> &agent) in GetWant() [all …]
|
/ohos5.0/base/notification/distributed_notification_service/frameworks/ans/test/unittest/ |
H A D | notification_action_button_test.cpp | 49 AbilityRuntime::WantAgent::WantAgentInfo paramsInfo; in HWTEST_F() 50 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> wantAgent = in HWTEST_F() 68 AbilityRuntime::WantAgent::WantAgentInfo paramsInfo; in HWTEST_F() 69 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> wantAgent = in HWTEST_F() 89 AbilityRuntime::WantAgent::WantAgentInfo paramsInfo; in HWTEST_F() 90 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> wantAgent = in HWTEST_F() 113 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> wantAgent = nullptr; in HWTEST_F() 142 AbilityRuntime::WantAgent::WantAgentInfo paramsInfo; 143 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> wantAgent = nullptr; 168 AbilityRuntime::WantAgent::WantAgentInfo paramsInfo; [all …]
|
/ohos5.0/docs/zh-cn/application-dev/notification/ |
H A D | notification-with-wantagent.md | 3 当发布通知时,如果期望用户可以通过点击通知栏拉起目标应用组件或发布公共事件,可以通过Ability Kit申请[WantAgent](../reference/apis-ability-kit/js… 10 具体接口描述,详见[WantAgent接口文档](../reference/apis-ability-kit/js-apis-app-ability-wantAgent.md)。 14 …nbsp;WantAgentInfo, callback: AsyncCallback<WantAgent>): void | 创建WantAgent。 | 22 import { wantAgent, WantAgent } from '@kit.AbilityKit'; 32 …场景一:创建拉起UIAbility的WantAgent的[WantAgentInfo](../reference/apis-ability-kit/js-apis-inner-wantAgent-… 35 let wantAgentObj:WantAgent; // 用于保存创建成功的wantAgent对象,后续使用其完成触发的动作。 59 let wantAgentObj:WantAgent; // 用于保存创建成功的WantAgent对象,后续使用其完成触发的动作。 78 // 创建WantAgent 79 wantAgent.getWantAgent(wantAgentInfo, (err: BusinessError, data:WantAgent) => { 89 4. 构造NotificationRequest对象,并发布WantAgent通知。 [all …]
|
/ohos5.0/docs/en/release-notes/changelogs/OpenHarmony_3.2.9.1/ |
H A D | changelogs-wantAgent.md | 1 # ChangeLog of JS API Changes in the WantAgent 3 This document describes the WantAgent API changes in OpenHarmony 3.2.9.1 SP8 when compared with Ope… 6 trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: Callback<CompleteData>): void ; 10 trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: AsyncCallback<CompleteData>): void 20 | trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: Callback<CompleteData>): void ; | … 29 import WantAgent from '@ohos.app.ability.wantAgent'; 30 // WantAgent object 59 operationType: WantAgent.OperationType.START_ABILITIES, 61 wantAgentFlags:[WantAgent.WantAgentFlags.UPDATE_PRESENT_FLAG] 80 WantAgent.trigger(wantAgent, triggerInfo, triggerCallback); [all …]
|
/ohos5.0/docs/en/application-dev/notification/ |
H A D | notification-with-wantagent.md | 1 # Adding a WantAgent Object to a Notification 5 **Figure 1** Publishing a notification with a WantAgent object 10 For details about the APIs, see [@ohos.wantAgent (WantAgent)](../reference/apis-ability-kit/js-apis… 14 …WantAgentInfo, callback: AsyncCallback<WantAgent>): void | Creates a **WantAg… 22 import { wantAgent, WantAgent } from '@kit.AbilityKit'; 35 …let wantAgentObj:WantAgent; // Save the created WantAgent object for completing the trigger operat… 59 …let wantAgentObj:WantAgent; // Save the created WantAgent object for completing the trigger operat… 75 …ility-kit/js-apis-app-ability-wantAgent.md#wantagentgetwantagent) to create a **WantAgent** object. 78 // Create a WantAgent object. 79 wantAgent.getWantAgent(wantAgentInfo, (err: BusinessError, data:WantAgent) => { [all …]
|
/ohos5.0/foundation/ability/ability_runtime/test/unittest/want_agent_test/ |
H A D | want_agent_test.cpp | 44 using namespace OHOS::AbilityRuntime::WantAgent; 47 namespace OHOS::AbilityRuntime::WantAgent { namespace 79 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(nullptr); 92 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 105 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 117 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(nullptr); 130 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(nullptr);
|
/ohos5.0/docs/zh-cn/release-notes/changelogs/OpenHarmony_3.2.9.1/ |
H A D | changelogs-wantAgent.md | 6 trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: Callback<CompleteData>): void ; 10 trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: AsyncCallback<CompleteData>): void 20 | trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: Callback<CompleteData>): void ; | … 29 import WantAgent from '@ohos.app.ability.wantAgent'; 59 operationType: WantAgent.OperationType.START_ABILITIES, 61 wantAgentFlags:[WantAgent.WantAgentFlags.UPDATE_PRESENT_FLAG] 80 WantAgent.trigger(wantAgent, triggerInfo, triggerCallback); 86 WantAgent.getWantAgent(wantAgentInfo, getWantAgentCallback);
|
/ohos5.0/foundation/ability/ability_runtime/test/unittest/want_agent_helper_test/ |
H A D | want_agent_helper_test.cpp | 570 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 619 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 646 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 674 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 703 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 733 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 760 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 838 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 854 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); 883 std::shared_ptr<WantAgent> wantAgent = std::make_shared<WantAgent>(pendingWant); [all …]
|
/ohos5.0/base/notification/distributed_notification_service/interfaces/inner_api/ |
H A D | notification_action_button.h | 48 … const std::string &title, const std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> &wantAgent, 88 const std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> GetWantAgent() const; 241 const std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> &wantAgent, 258 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> wantAgent_ {};
|
H A D | notification_request.h | 280 void SetWantAgent(const std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> &wantAgent); 287 const std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> GetWantAgent() const; 294 … void SetRemovalWantAgent(const std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> &wantAgent); 301 const std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> GetRemovalWantAgent() const; 313 …void SetMaxScreenWantAgent(const std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> &wantAgent); 320 const std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> GetMaxScreenWantAgent() const; 1526 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> wantAgent_ {}; 1527 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> removalWantAgent_ {}; 1528 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> maxScreenWantAgent_ {};
|
/ohos5.0/foundation/ability/ability_runtime/test/fuzztest/wantagenthelperstring_fuzzer/ |
H A D | wantagenthelperstring_fuzzer.cpp | 26 using namespace OHOS::AbilityRuntime::WantAgent; 32 WantAgent* wantAgent = nullptr; in DoSomethingInterestingWithMyAPI() 34 wantAgent = WantAgent::Unmarshalling(wantAgentParcel); in DoSomethingInterestingWithMyAPI() 37 std::shared_ptr<WantAgent> sptrAgent = std::make_shared<WantAgent>(pendingWant); in DoSomethingInterestingWithMyAPI()
|
/ohos5.0/base/notification/distributed_notification_service/test/bechmarktest/notification_publish_test/ |
H A D | notification_publish_test.cpp | 83 AbilityRuntime::WantAgent::WantAgentInfo paramsInfo; in InitWantAgentRequest() 84 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> wantAgent = in InitWantAgentRequest() 85 AbilityRuntime::WantAgent::WantAgentHelper::GetWantAgent(paramsInfo); in InitWantAgentRequest() 97 AbilityRuntime::WantAgent::WantAgentInfo paramsInfo; in InitButtonRequest() 98 std::shared_ptr<AbilityRuntime::WantAgent::WantAgent> wantAgent = in InitButtonRequest() 99 AbilityRuntime::WantAgent::WantAgentHelper::GetWantAgent(paramsInfo); in InitButtonRequest()
|
/ohos5.0/base/location/interfaces/inner_api/include/ |
H A D | geofence_request.h | 53 void SetWantAgent(const AbilityRuntime::WantAgent::WantAgent wantAgent); 55 AbilityRuntime::WantAgent::WantAgent GetWantAgent(); 108 AbilityRuntime::WantAgent::WantAgent wantAgent_;
|
/ohos5.0/docs/zh-cn/application-dev/device/location/ |
H A D | geofence-guidelines.md | 19 | [on(type: 'gnssFenceStatusChange', request: GeofenceRequest, want: WantAgent): void;](../../refer… 20 | [off(type: 'gnssFenceStatusChange', request: GeofenceRequest, want: WantAgent): void;](../../refe… 75 4. 调用getWantAgent()方法进行创建WantAgent。 77 并且在获取到WantAgent对象之后调用地理围栏接口添加围栏,当设备进入或者退出该围栏时,系统会自动触发WantAgent的动作。 81 // 创建WantAgent
|