diff --git a/en/react-native-udp.md b/en/react-native-udp.md index 45916a5fceef1aeb6f280637b44103aaeebfcf9f..a0428e1d65b77baa5c04e75bbcc1133c200000ee 100644 --- a/en/react-native-udp.md +++ b/en/react-native-udp.md @@ -191,7 +191,7 @@ Open `entry/oh-package.json5` file and add the following dependencies: ```json "dependencies": { "@rnoh/react-native-openharmony": "file:../react_native_openharmony", - "@react-native-oh-tpl/react-native-udp": "file:../../node_modules/@react-native-oh-tpl/react-native-udp/harmony/react-native-udp.har" + "@react-native-oh-tpl/react-native-udp": "file:../../node_modules/@react-native-oh-tpl/react-native-udp/harmony/react_native_udp.har" } ``` @@ -255,6 +255,7 @@ Check the release version information in the release address of the third-party | Name | Description | Type | Required | Platform | HarmonyOS Support | | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------ | -------- | -------- | ----------- | ----------------- | | createSocket | Creates a Socket object. | Function | false | Android/iOS | yes | +| close | Close the underlying socket and stop listening for data on it. If a callback is provided. | Function | false | Android/iOS | yes | | bind | For UDP sockets, causes the `UdpSocket` to listen for datagram messages on a named `port`. | Function | false | Android/iOS | yes | | send | Broadcasts a datagram on the socket. | Function | false | Android/iOS | yes | | address | Returns an object containing the address information for a socket. | Function | false | Android/iOS | yes | @@ -268,4 +269,4 @@ Check the release version information in the release address of the third-party ## License -This project is licensed under [The MIT License (MIT)](https://github.com/tradle/react-native-udp/blob/master/LICENSE). +This project is licensed under [The MIT License (MIT)](https://github.com/tradle/react-native-udp/blob/master/LICENSE). \ No newline at end of file diff --git a/zh-cn/react-native-udp.md b/zh-cn/react-native-udp.md index f1ad55591c84d414d277a83c51e93e0e044865f6..78e185ee9ea56ad0d904f86fdc6accbe214c8ee0 100644 --- a/zh-cn/react-native-udp.md +++ b/zh-cn/react-native-udp.md @@ -193,7 +193,7 @@ export default App; ```json "dependencies": { "@rnoh/react-native-openharmony": "file:../react_native_openharmony", - "@react-native-oh-tpl/react-native-udp": "file:../../node_modules/@react-native-oh-tpl/react-native-udp/harmony/react-native-udp.har" + "@react-native-oh-tpl/react-native-udp": "file:../../node_modules/@react-native-oh-tpl/react-native-udp/harmony/react_native_udp.har" } ``` @@ -261,6 +261,7 @@ ohpm install | Name | Description | Type | Required | Platform | HarmonyOS Support | | -------------- | ------------------------------------------------------------ | -------- | -------- | ----------- | ----------------- | | createSocket | Creates a Socket object. | Function | false | Android/iOS | yes | +| close | Close the underlying socket and stop listening for data on it. If a callback is provided. | Function | false | Android/iOS | yes | | bind | For UDP sockets, causes the `UdpSocket` to listen for datagram messages on a named `port`. | Function | false | Android/iOS | yes | | send | Broadcasts a datagram on the socket. | Function | false | Android/iOS | yes | | address | Returns an object containing the address information for a socket. | Function | false | Android/iOS | yes | @@ -278,4 +279,4 @@ ohpm install ## 开源协议 -本项目基于 [The MIT License (MIT)](https://github.com/tradle/react-native-udp/blob/master/LICENSE) ,请自由地享受和参与开源。 +本项目基于 [The MIT License (MIT)](https://github.com/tradle/react-native-udp/blob/master/LICENSE) ,请自由地享受和参与开源。 \ No newline at end of file