modify intelliJ plugin docs
Signed-off-by: gou-jingjing <goujingjing@kaihong.com>
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023 Shenzhen Kaihong Digital Industry Development Co., Ltd.
|
* Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd.
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
* You may obtain a copy of the License at
|
* You may obtain a copy of the License at
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023 Shenzhen Kaihong Digital Industry Development Co., Ltd.
|
* Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd.
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
* You may obtain a copy of the License at
|
* You may obtain a copy of the License at
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023 Shenzhen Kaihong Digital Industry Development Co., Ltd.
|
* Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd.
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
* You may obtain a copy of the License at
|
* You may obtain a copy of the License at
|
||||||
|
Before Width: | Height: | Size: 34 KiB After Width: | Height: | Size: 25 KiB |
Before Width: | Height: | Size: 21 KiB After Width: | Height: | Size: 18 KiB |
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 29 KiB |
Before Width: | Height: | Size: 34 KiB After Width: | Height: | Size: 32 KiB |
Before Width: | Height: | Size: 40 KiB After Width: | Height: | Size: 42 KiB |
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 29 KiB |
Before Width: | Height: | Size: 21 KiB After Width: | Height: | Size: 46 KiB |
@ -52,9 +52,9 @@ Content root选择~/napi_generator/napi_IntelliJ_plugin文件夹,module name
|
|||||||
8.Modules配置完成后,若在SDKs中无相应JDK和Plugin SDK,请点击+号分别添加 Add Java JDK和Add Intellij PlantForm Plugin SDK,Java JDK为java11的安装目录,Plugin SDK为 IDEA Community 2021.3.3的安装目录。
|
8.Modules配置完成后,若在SDKs中无相应JDK和Plugin SDK,请点击+号分别添加 Add Java JDK和Add Intellij PlantForm Plugin SDK,Java JDK为java11的安装目录,Plugin SDK为 IDEA Community 2021.3.3的安装目录。
|
||||||
![](../../../figures/IntelliJ_env_config_SDKs.png)
|
![](../../../figures/IntelliJ_env_config_SDKs.png)
|
||||||
|
|
||||||
9.配置Libraries(napi 1.0.3版本以及之后版本才需要配置依赖,之前的版本可跳过此步骤)
|
9.配置Libraries(napi 1.0.3版本以及之后版本才需要配置依赖,之前的版本跳过此步骤)
|
||||||
|
|
||||||
配置依赖原因:由于IntellIj插件市场兼容性问题,原使用的json库与新版本的IDE不兼容,因此使用新的json库解决兼容性问题,新的json库需要从Maven仓库下载并将依赖配置到工程中。
|
由于IntellIj插件市场兼容性问题,原使用的json库与新版本的IDE不兼容,因此使用新的json库解决兼容性问题,新的json库需要从Maven仓库下载并将依赖配置到工程中。
|
||||||
|
|
||||||
步骤:点击"+",选择"From Maven...";在搜索框搜索依赖的jar包:com.alibaba.fastjson2:fastjson2:2.0.42,勾选"Download to"并点击OK,将依赖下载至工程目录下的lib文件夹;点击"Choose Modules"中的OK。
|
步骤:点击"+",选择"From Maven...";在搜索框搜索依赖的jar包:com.alibaba.fastjson2:fastjson2:2.0.42,勾选"Download to"并点击OK,将依赖下载至工程目录下的lib文件夹;点击"Choose Modules"中的OK。
|
||||||
|
|
||||||
@ -82,7 +82,7 @@ Content root选择~/napi_generator/napi_IntelliJ_plugin文件夹,module name
|
|||||||
|
|
||||||
![](../../../figures/IntelliJ_env_select_moudles.png)
|
![](../../../figures/IntelliJ_env_select_moudles.png)
|
||||||
|
|
||||||
1.0.3版本之前生成的包为.jar格式,1.0.3以及之后版本生成的版本为.zip格式(由于新增了lib依赖:com.alibaba.fastjson2:fastjson2:2.0.42,因此插件包为.zip格式)。
|
1.0.3之前版本,版本格式.jar,由于1.0.3及之后新增了lib依赖(com.alibaba.fastjson2:fastjson2:2.0.42),版本格式为.zip。
|
||||||
|
|
||||||
![](../../../figures/IntelliJ_env_built_jar_success.png)
|
![](../../../figures/IntelliJ_env_built_jar_success.png)
|
||||||
|
|
||||||
|
@ -1,29 +1,11 @@
|
|||||||
# DevEco Studio编译打包说明
|
# 集成应用Native工程说明
|
||||||
|
|
||||||
## 简介
|
## 简介
|
||||||
本文主要介绍使用IntelliJ插件将ts接口文件名格式如下ohos.A.B.C.d.ts文件转换后如何在DevEco Studio进行编译打包。
|
本文主要介绍使用Intellij插件将ts接口文件名格式如下ohos.A.B.C.d.ts文件转换后如何集成到应用Native工程中并编译打包,最终对接口进行测试。
|
||||||
|
|
||||||
## 准备
|
## 准备
|
||||||
|
|
||||||
### 待转换的ts文件用例
|
### 接口测试相关的应用
|
||||||
|
|
||||||
待转换的@ohos.napitest.d.ts文件如下:
|
|
||||||
|
|
||||||
[@ohos.napitest.d.ts](https://gitee.com/openharmony/napi_generator/blob/master/examples/ts/@ohos.napitest.d.ts)
|
|
||||||
|
|
||||||
### 业务代码用例
|
|
||||||
|
|
||||||
业务代码用例如下:
|
|
||||||
|
|
||||||
serviceCode/NodeISayHello.h
|
|
||||||
|
|
||||||
[NodeISayHello.h](https://gitee.com/openharmony/napi_generator/blob/master/examples/pluginCase/serviceCode/NodeISayHello.h)
|
|
||||||
|
|
||||||
serviceCode/NodeISayHello.cpp
|
|
||||||
|
|
||||||
[NodeISayHello.cpp](https://gitee.com/openharmony/napi_generator/blob/master/examples/pluginCase/serviceCode/NodeISayHello.cpp)
|
|
||||||
|
|
||||||
### 测试应用用例
|
|
||||||
|
|
||||||
在DevEco Studio中增加调用napi方法的测试用例。其中修改index.js文件内容如下:
|
在DevEco Studio中增加调用napi方法的测试用例。其中修改index.js文件内容如下:
|
||||||
|
|
||||||
@ -177,7 +159,7 @@ console.info("napiTestDemo ----funcTest returnVal = " + this.returnVal)
|
|||||||
I A03d00/JSAPP: napiTestDemo ----funcTest returnVal = "ret is false"
|
I A03d00/JSAPP: napiTestDemo ----funcTest returnVal = "ret is false"
|
||||||
```
|
```
|
||||||
|
|
||||||
7.调用其它模块:entry模块的方法add
|
7.工具生成代码集成到应用Native工程之后,该应用Native工程中已有模块的接口不影响使用,如:entry模块的方法add
|
||||||
|
|
||||||
```
|
```
|
||||||
this.addResult = testEntry.add(2, 3).toString();
|
this.addResult = testEntry.add(2, 3).toString();
|
||||||
@ -207,7 +189,7 @@ Text('普通方法funcTest返回值: returnVal = ' + this.returnVal).margin({
|
|||||||
Text('libentry模块: 2 + 3 = ' + this.addResult).margin({ top: 10 })
|
Text('libentry模块: 2 + 3 = ' + this.addResult).margin({ top: 10 })
|
||||||
```
|
```
|
||||||
|
|
||||||
## 使用说明
|
## 打包说明
|
||||||
|
|
||||||
1. 在File->Project Structure->Project->Signing Configs自动签名,点击OK即可。
|
1. 在File->Project Structure->Project->Signing Configs自动签名,点击OK即可。
|
||||||
|
|
||||||
@ -225,8 +207,10 @@ Text('libentry模块: 2 + 3 = ' + this.addResult).margin({ top: 10 })
|
|||||||
|
|
||||||
3. 执行成功后,设备中会出现安装的APP并进入APP测试页面
|
3. 执行成功后,设备中会出现安装的APP并进入APP测试页面
|
||||||
|
|
||||||
点击"注册object回调后SayHello调用回调"按钮,APP页面中sayHelloStart回调info和sayHelloEnd回调info会显示出C++传到js层的回调数据;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
3.1 注册object回调后SayHello调用回调
|
||||||
|
|
||||||
|
点击"注册object回调后SayHello调用回调"按钮,APP页面中sayHelloStart回调info和sayHelloEnd回调info会显示出C++传到js层的回调数据;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
||||||
|
|
||||||
```
|
```
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello from=js1
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello from=js1
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello to=native1
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello to=native1
|
||||||
@ -234,28 +218,34 @@ Text('libentry模块: 2 + 3 = ' + this.addResult).margin({ top: 10 })
|
|||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloStartCallback begin
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloStartCallback begin
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloStartCallback end
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloStartCallback end
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloEndCallback begin
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloEndCallback begin
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloEndCallback end
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloEndCallback end
|
||||||
```
|
```
|
||||||
|
|
||||||
|
3.2 注销object回调后SayHello调用回调
|
||||||
|
|
||||||
点击“注销object回调后SayHello调用回调”按钮,sayHelloStart回调info和sayHelloEnd回调info会显示出数据为空,即该回调已注销,C++无法调用回调,显示的为应用赋的空值;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
点击“注销object回调后SayHello调用回调”按钮,sayHelloStart回调info和sayHelloEnd回调info会显示出数据为空,即该回调已注销,C++无法调用回调,显示的为应用赋的空值;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
||||||
|
|
||||||
```
|
```
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello from=js2
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello from=js2
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello to=native2
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello to=native2
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello sayType=0
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHello sayType=0
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloStartCallback begin
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloStartCallback begin
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloStartCallback end
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloStartCallback end
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloEndCallback begin
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloEndCallback begin
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloEndCallback end
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI NodeISayHelloListener_onSayHelloEndCallback end
|
||||||
```
|
```
|
||||||
|
|
||||||
|
3.3 Promise 回调
|
||||||
|
|
||||||
点击“Promise 回调”按钮,Promise回调的errMsg, result, response会出现C++传到js层的回调数据;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
点击“Promise 回调”按钮,Promise回调的errMsg, result, response会出现C++传到js层的回调数据;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
||||||
|
|
||||||
```
|
```
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHelloWithResponse from=response from
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHelloWithResponse from=response from
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHelloWithResponse to=response to
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHelloWithResponse to=response to
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHelloWithResponse sayType=1
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHelloWithResponse sayType=1
|
||||||
```
|
```
|
||||||
|
|
||||||
|
3.4 register回调后SayHi调用回调
|
||||||
|
|
||||||
点击“register回调后SayHi调用回调”按钮,register注册的回调会显示出wid = 50, wid值为C++传到js的回调数据;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
点击“register回调后SayHi调用回调”按钮,register注册的回调会显示出wid = 50, wid值为C++传到js的回调数据;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
||||||
|
|
||||||
@ -265,6 +255,8 @@ Text('libentry模块: 2 + 3 = ' + this.addResult).margin({ top: 10 })
|
|||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHi sayType=1
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHi sayType=1
|
||||||
```
|
```
|
||||||
|
|
||||||
|
3.5 unRegister回调后SayHi调用回调
|
||||||
|
|
||||||
点击“unRegister回调后SayHi调用回调”按钮,register注册的回调会显示出wid 为空,即该回调已注销,C++无法调用回调,显示的为应用赋的空值;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
点击“unRegister回调后SayHi调用回调”按钮,register注册的回调会显示出wid 为空,即该回调已注销,C++无法调用回调,显示的为应用赋的空值;DevEco Studio控制台中Log->HiLog中会出现以下结果:
|
||||||
|
|
||||||
```
|
```
|
||||||
@ -272,11 +264,15 @@ Text('libentry模块: 2 + 3 = ' + this.addResult).margin({ top: 10 })
|
|||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHi to=native4
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHi to=native4
|
||||||
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHi sayType=1
|
A03200/MY_TAG com.example.napitestdemo I NAPITEST_LOGI sayHi sayType=1
|
||||||
```
|
```
|
||||||
|
|
||||||
|
3.6 调用funcTest方法
|
||||||
|
|
||||||
点击”调用funcTest方法“按钮,普通方法funcTest返回值显示出 returnVal = ret is false。
|
点击”调用funcTest方法“按钮,普通方法funcTest返回值显示出 returnVal = ret is false。
|
||||||
|
|
||||||
|
3.7 调用entry模块的方法
|
||||||
|
|
||||||
点击“调用entry模块的方法”按钮,libentry模块:2 + 3 = 5。
|
点击“调用entry模块的方法”按钮,libentry模块:2 + 3 = 5。
|
||||||
|
|
||||||
![](../../../figures/DevEco_run_result.png)
|
![](../../../figures/DevEco_run_result.png)
|
||||||
|
|
||||||
## 相关仓
|
## 相关仓
|
||||||
|
@ -32,23 +32,29 @@ Ability Template选择Native C++,单击Next。
|
|||||||
|
|
||||||
![](../../../figures/DevEco_step_finish.png)
|
![](../../../figures/DevEco_step_finish.png)
|
||||||
|
|
||||||
2.安装插件,File->Settings->Plugins->Installed->Install Plugin from Disk...,选择下载的napi_generator包(1.0.3版本及之后的是.zip包,之前的是.jar包),安装成功之后重启IDE。
|
2.安装插件,File->Settings->Plugins->Installed->Install Plugin from Disk...,选择下载的napi_generator包,安装成功之后重启IDE。
|
||||||
|
|
||||||
![](../../../figures/DevEco_step_pluginsOk.png)
|
![](../../../figures/DevEco_step_pluginsOk.png)
|
||||||
|
|
||||||
安装jar包,v1.0.3之前
|
v1.0.3之前版本,安装jar包
|
||||||
|
|
||||||
![](../../../figures/DevEco_step_applyPlugins.png)
|
![](../../../figures/DevEco_step_applyPlugins.png)
|
||||||
|
|
||||||
安装zip包,v1.0.3及之后
|
v1.0.3及之后版本,安装zip包
|
||||||
|
|
||||||
![](../../../figures/DevEco_step_applyPlugins_zip.png)
|
![](../../../figures/DevEco_step_applyPlugins_zip.png)
|
||||||
|
|
||||||
3.把待转换的.d.ts文件放在DevEco stdio新建项目的src目录下。若.d.ts文件中声明了basic.d.ts文件,将basic.d.ts文件放置在待转换.d.ts文件同一级目录;若除此之外还声明其它.d.ts文件,将此类文件放置在待转换.d.ts文件同级目录。
|
|
||||||
|
|
||||||
|
3.使用工具之前,需要做以下准备工作,链接如下:
|
||||||
|
|
||||||
|
[PRAPERATION_ZH](https://gitee.com/openharmony/napi_generator/blob/master/napi_IntelliJ_plugin/docs/napi/PRAPERATION_ZH.md)
|
||||||
|
|
||||||
|
新建项目的src目录,把待转换的.d.ts文件放在DevEco Studio新建项目的src目录下;新建生成框架路径generatorCode;将业务代码放在./src/main/cpp目录下。若.d.ts文件中声明了basic.d.ts文件,将basic.d.ts文件放置在待转换.d.ts文件同一级目录;若除此之外还声明其他.d.ts文件,将此类文件放置在待转换.d.ts文件同级目录。
|
||||||
|
|
||||||
![](../../../figures/DevEco_step_napi.png)
|
![](../../../figures/DevEco_step_napi.png)
|
||||||
|
|
||||||
4.选择.d.ts文件,点击右键选择 Generate Napi Frame,工具弹出Generate Napi Frame弹窗。接口文件文本框填写.d.ts文件路径;生成框架路径文本框填写生成框架存放路径;编译脚本路径填写生成CMakeList.txt文件输出路径;number目的类型此处选择char;启用import功能不选择(待转换.d.ts文件未引用其它文件);配置业务代码按钮可用于配置接口的业务代码,框架根据配置自动粘合工具代码与业务代码;若用户想手动配置业务代码,则不点击配置按钮配置。点击ok。
|
4.配置工具参数:选择.d.ts文件,点击右键选择 "Generate Napi Frame",工具弹出"Generate Napi Frame"弹窗。接口文件文本框填写.d.ts文件路径;"生成框架路径"填写生成框架存放路径;"编译脚本路径"填写生成CMakeList.txt文件输出路径;"number目的类型"此处选择uint32_t;因待转换.d.ts文件未引用其它文件,"启用import功能"不选择;"配置业务代码"按钮用于配置接口的业务代码,框架根据配置自动粘合工具代码与业务代码;若用户想手动配置业务代码,则不点击配置按钮配置。点击ok。
|
||||||
|
|
||||||
![](../../../figures/DevEco_step_napiGenerate.png)
|
![](../../../figures/DevEco_step_napiGenerate.png)
|
||||||
|
|
||||||
@ -62,7 +68,7 @@ Ability Template选择Native C++,单击Next。
|
|||||||
|
|
||||||
[cfg.json](https://gitee.com/openharmony/napi_generator/blob/master/examples/pluginCase/cfg.json)
|
[cfg.json](https://gitee.com/openharmony/napi_generator/blob/master/examples/pluginCase/cfg.json)
|
||||||
|
|
||||||
## DevEco Studio编译打包说明
|
## 集成应用Native工程说明
|
||||||
NAPI框架代码生成后,系统框架开发者进行二次开发后,可在DevEco Studio进行编译打包生成对应的库文件,供应用开发者调用接口。DevEco Studio编译打包说明的具体操作步骤可以左键单击以下链接了解:
|
NAPI框架代码生成后,系统框架开发者进行二次开发后,可在DevEco Studio将生成代码集成到应用Native工程中,并进行编译打包生成对应的库文件,供应用开发者调用接口。集成应用Native工程说明的具体操作步骤可以左键单击以下链接了解:
|
||||||
|
|
||||||
[DevEco Studio编译打包说明](https://gitee.com/openharmony/napi_generator/blob/master/napi_IntelliJ_plugin/docs/napi/INSTRUCTION_BUILD_ZH.md)
|
[集成应用Native工程说明](https://gitee.com/openharmony/napi_generator/blob/master/napi_IntelliJ_plugin/docs/napi/INSTRUCTION_BUILD_ZH.md)
|
25
napi_IntelliJ_plugin/docs/napi/PRAPERATION_ZH.md
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
# 使用工具之前的准备
|
||||||
|
|
||||||
|
## 简介
|
||||||
|
|
||||||
|
本文主要介绍用户使用Napi生成工具之前需要做的准备工作。
|
||||||
|
|
||||||
|
## 准备
|
||||||
|
|
||||||
|
### 待转换的ts文件
|
||||||
|
|
||||||
|
待转换的@ohos.napitest.d.ts文件如下:
|
||||||
|
|
||||||
|
[@ohos.napitest.d.ts](https://gitee.com/openharmony/napi_generator/blob/master/examples/ts/@ohos.napitest.d.ts)
|
||||||
|
|
||||||
|
### 业务代码
|
||||||
|
|
||||||
|
业务代码用例如下:
|
||||||
|
|
||||||
|
serviceCode/NodeISayHello.h
|
||||||
|
|
||||||
|
[NodeISayHello.h](https://gitee.com/openharmony/napi_generator/blob/master/examples/pluginCase/serviceCode/NodeISayHello.h)
|
||||||
|
|
||||||
|
serviceCode/NodeISayHello.cpp
|
||||||
|
|
||||||
|
[NodeISayHello.cpp](https://gitee.com/openharmony/napi_generator/blob/master/examples/pluginCase/serviceCode/NodeISayHello.cpp)
|