From 6cafac7538e355ddf4f176da52e64bb10fc680ca Mon Sep 17 00:00:00 2001 From: wangchensu Date: Fri, 16 Dec 2022 16:06:13 +0800 Subject: [PATCH] =?UTF-8?q?fixed=2050566e2=20from=20https://gitee.com/wang?= =?UTF-8?q?chensu1/interface=5Fsdk-js/pulls/3665=20PluginManagerAPI?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E5=8F=82=E6=95=B0=E5=85=BC=E5=AE=B9Stage?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: wangchensu Change-Id: I42f9a12fae3152e754b1be6ba9c969c482537143 --- api/@ohos.pluginComponent.d.ts | 49 +++++++++++++++++++++++++++++++++- 1 file changed, 48 insertions(+), 1 deletion(-) diff --git a/api/@ohos.pluginComponent.d.ts b/api/@ohos.pluginComponent.d.ts index 834ca7614c..7d3b194b34 100644 --- a/api/@ohos.pluginComponent.d.ts +++ b/api/@ohos.pluginComponent.d.ts @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -46,6 +46,20 @@ declare namespace pluginComponentManager { jsonPath?: string; } + /** + * Plugin component push parameters. + * @since 9 + * @systemapi + */ + interface PushParameterForStage { + owner: Want; + want: Want; + name: string; + data: KVObject; + extraData: KVObject; + jsonPath?: string; + } + /** * Plugin component request parameters. * @since 8 @@ -57,6 +71,19 @@ declare namespace pluginComponentManager { jsonPath?: string; } + /** + * Plugin component request parameters. + * @since 9 + * @systemapi + */ + interface RequestParameterForStage { + owner: Want; + want: Want; + name: string; + data: KVObject; + jsonPath?: string; + } + /** * Plugin component request callback parameters. * @since 8 @@ -103,6 +130,26 @@ declare namespace pluginComponentManager { */ function request(param: RequestParameters, callback: AsyncCallback): void; + /** + * Plugin component push method. + * @param param: Plugin component push parameters for stage. + * @param callback: Plugin component push event callback. + * @StageModelOnly + * @since 9 + * @systemapi + */ + function push(param: PushParameterForStage, callback: AsyncCallback): void; + + /** + * Plugin component request method. + * @param param: Plugin component request parameters for stage. + * @param callback: Plugin component request event callback. + * @StageModelOnly + * @since 9 + * @systemapi + */ + function request(param: RequestParameterForStage, callback: AsyncCallback): void; + /** * Plugin component event listener. * @since 8 -- Gitee