@actuallab/rpc 12.3.60 → 12.3.64
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.
- package/dist/index.cjs +7 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +5 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.d.cts
CHANGED
|
@@ -820,6 +820,11 @@ declare abstract class RpcPeer {
|
|
|
820
820
|
set serializationFormat(value: RpcSerializationFormat);
|
|
821
821
|
call(method: string, args?: unknown[], options?: RpcCallOptions): RpcOutboundCall;
|
|
822
822
|
callNoWait(method: string, args?: unknown[]): void;
|
|
823
|
+
/** Close the current WS connection without disposing the peer. The
|
|
824
|
+
* `conn.closed` handler flips state to `Disconnected`; for
|
|
825
|
+
* `RpcClientPeer` the run loop then iterates and reopens. The peer
|
|
826
|
+
* stays in the hub and all client proxies bound to it remain valid. */
|
|
827
|
+
disconnect(): void;
|
|
823
828
|
close(): void;
|
|
824
829
|
/** Send any messages buffered while disconnected. Call after connection + handshake are ready. */
|
|
825
830
|
protected _flushPendingSends(): void;
|
package/dist/index.d.ts
CHANGED
|
@@ -820,6 +820,11 @@ declare abstract class RpcPeer {
|
|
|
820
820
|
set serializationFormat(value: RpcSerializationFormat);
|
|
821
821
|
call(method: string, args?: unknown[], options?: RpcCallOptions): RpcOutboundCall;
|
|
822
822
|
callNoWait(method: string, args?: unknown[]): void;
|
|
823
|
+
/** Close the current WS connection without disposing the peer. The
|
|
824
|
+
* `conn.closed` handler flips state to `Disconnected`; for
|
|
825
|
+
* `RpcClientPeer` the run loop then iterates and reopens. The peer
|
|
826
|
+
* stays in the hub and all client proxies bound to it remain valid. */
|
|
827
|
+
disconnect(): void;
|
|
823
828
|
close(): void;
|
|
824
829
|
/** Send any messages buffered while disconnected. Call after connection + handshake are ready. */
|
|
825
830
|
protected _flushPendingSends(): void;
|
package/dist/index.js
CHANGED
|
@@ -2351,6 +2351,13 @@ var RpcPeer = class {
|
|
|
2351
2351
|
);
|
|
2352
2352
|
this._sendWireData(wireData);
|
|
2353
2353
|
}
|
|
2354
|
+
/** Close the current WS connection without disposing the peer. The
|
|
2355
|
+
* `conn.closed` handler flips state to `Disconnected`; for
|
|
2356
|
+
* `RpcClientPeer` the run loop then iterates and reopens. The peer
|
|
2357
|
+
* stays in the hub and all client proxies bound to it remain valid. */
|
|
2358
|
+
disconnect() {
|
|
2359
|
+
this._connection?.close();
|
|
2360
|
+
}
|
|
2354
2361
|
close() {
|
|
2355
2362
|
infoLog?.log(`'${this.ref}': Stopping`);
|
|
2356
2363
|
this.remoteObjects.disconnectAll();
|