@mega-yfue/eufy-sdk 0.5.0-beta.71 → 0.5.0-beta.72
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -113,9 +113,9 @@ export declare class RtcCommandRouter {
|
|
|
113
113
|
private stationSession;
|
|
114
114
|
/**
|
|
115
115
|
* One bounded bring-up: the session is up when its command channel opens, and it fails, with the
|
|
116
|
-
* session closed and every listener gone, when `connect()` throws, the session closes first
|
|
117
|
-
*
|
|
118
|
-
* rejecting unheard.
|
|
116
|
+
* session closed and every listener gone, when `connect()` throws, the session closes first (rejecting
|
|
117
|
+
* with the failure that closed it, when it carries one), or {@link CONNECT_TIMEOUT_MS} passes. A single
|
|
118
|
+
* promise, so an early failure cannot leave a second one rejecting unheard.
|
|
119
119
|
*/
|
|
120
120
|
private bringUp;
|
|
121
121
|
/**
|
|
@@ -15,7 +15,8 @@
|
|
|
15
15
|
*
|
|
16
16
|
* The command data channel is the session: `close` fires once, when the channel closes, the peer fails,
|
|
17
17
|
* the signalling socket drops or {@link RtcSession.close} is called, even while the peer connection is
|
|
18
|
-
* nominally up.
|
|
18
|
+
* nominally up. A peer that cannot be built when the hub grants the relay ends the session there: the
|
|
19
|
+
* failure is emitted as `error` and `close` fires carrying it.
|
|
19
20
|
*
|
|
20
21
|
* A session whose peer is a {@link RtcPeerOptions.mediaTrack} peer has no command channel: `close` fires
|
|
21
22
|
* when the peer fails or closes, and the video track's packets are emitted as `rtp`.
|
|
@@ -32,7 +33,8 @@ export interface RtcSessionOptions extends RtcSignalingOptions {
|
|
|
32
33
|
}
|
|
33
34
|
export interface RtcSessionEvents {
|
|
34
35
|
connected: [];
|
|
35
|
-
|
|
36
|
+
/** The session ended; `err` is the failure that ended it, when one did. */
|
|
37
|
+
close: [err?: Error];
|
|
36
38
|
error: [err: Error];
|
|
37
39
|
/** A reassembled command or notify frame: portal packet bytes + the link type it arrived on. */
|
|
38
40
|
commandData: [frame: Buffer, linkType: number];
|
|
@@ -73,6 +75,8 @@ export declare class RtcSession extends EventEmitter<RtcSessionEvents> {
|
|
|
73
75
|
* `connect()` still waiting for the signalling auth is rejected and its timer stopped.
|
|
74
76
|
*/
|
|
75
77
|
close(): void;
|
|
78
|
+
/** {@link RtcSession.close}, with the failure that ended the session handed to `close` when one did. */
|
|
79
|
+
private shutdown;
|
|
76
80
|
/**
|
|
77
81
|
* Trickle one local candidate, or the empty end-of-candidates. The native peer can report one after the
|
|
78
82
|
* signalling socket has closed, and sending then throws inside a native callback, where the throw can't
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mega-yfue/eufy-sdk",
|
|
3
|
-
"version": "0.5.0-beta.
|
|
3
|
+
"version": "0.5.0-beta.72",
|
|
4
4
|
"description": "One typed TypeScript client for the Anker eufy v6 cloud — capability-driven devices, realtime events over P2P/MQTT/push, and live media",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "mega-yfue",
|