isP2PActive(params: Object)
Requires:
P2PKit≥2.0.3@ray-js/ray≥1.3.15
Platforms:
iOSAndroid
Description
check P2P status
Parameters
| Property | Type | Required | Default | Description |
|---|---|---|---|---|
deviceId | string | Yes | - | Device ID |
mode | number | No | 0 | Connection mode, 0: INTERNET 1: LAN |
timeout | number | No | 0 | Timeout (ms). Defaults: INTERNET 15000 ms, LAN 3000 ms |
complete | () => void | No | - | Completion callback (executed on both success and failure) |
success | () => void | No | - | Callback on successful API call |
fail | (params: Object) => void | No | - | Failure callback |
fail callback parameters
| Property | Type | Description |
|---|---|---|
errorMsg | string | Error message |
errorCode | string | number | Error code |
| Error extension |
Return Value
None