@agntcy/slim-bindings 3.3.8 → 3.4.0

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.
@@ -80,6 +80,7 @@ interface NativeModuleInterface {
80
80
  uniffi_slim_rpc_fn_init_callback_vtable_streamunaryhandler(vtable: UniffiVTableCallbackInterfaceSlimRpcStreamUnaryHandler): void;
81
81
  uniffi_slim_rpc_fn_init_callback_vtable_unarystreamhandler(vtable: UniffiVTableCallbackInterfaceSlimRpcUnaryStreamHandler): void;
82
82
  uniffi_slim_rpc_fn_init_callback_vtable_unaryunaryhandler(vtable: UniffiVTableCallbackInterfaceSlimRpcUnaryUnaryHandler): void;
83
+ uniffi_slim_rpc_fn_method_bidistreamhandler_cancel(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): void;
83
84
  uniffi_slim_rpc_fn_method_bidistreamhandler_close_send(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): void;
84
85
  uniffi_slim_rpc_fn_method_bidistreamhandler_close_send_async(uniffiSelf: bigint): bigint;
85
86
  uniffi_slim_rpc_fn_method_bidistreamhandler_recv(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
@@ -111,16 +112,19 @@ interface NativeModuleInterface {
111
112
  uniffi_slim_rpc_fn_method_context_peer_subject(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
112
113
  uniffi_slim_rpc_fn_method_context_remaining_time(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
113
114
  uniffi_slim_rpc_fn_method_context_session_id(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
115
+ uniffi_slim_rpc_fn_method_multicastbidistreamhandler_cancel(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): void;
114
116
  uniffi_slim_rpc_fn_method_multicastbidistreamhandler_close_send(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): void;
115
117
  uniffi_slim_rpc_fn_method_multicastbidistreamhandler_close_send_async(uniffiSelf: bigint): bigint;
116
118
  uniffi_slim_rpc_fn_method_multicastbidistreamhandler_recv(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
117
119
  uniffi_slim_rpc_fn_method_multicastbidistreamhandler_recv_async(uniffiSelf: bigint): bigint;
118
120
  uniffi_slim_rpc_fn_method_multicastbidistreamhandler_send(uniffiSelf: bigint, data: Uint8Array, uniffi_out_err: UniffiRustCallStatus): void;
119
121
  uniffi_slim_rpc_fn_method_multicastbidistreamhandler_send_async(uniffiSelf: bigint, data: Uint8Array): bigint;
122
+ uniffi_slim_rpc_fn_method_multicastresponsereader_cancel(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): void;
120
123
  uniffi_slim_rpc_fn_method_multicastresponsereader_next(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
121
124
  uniffi_slim_rpc_fn_method_multicastresponsereader_next_async(uniffiSelf: bigint): bigint;
122
125
  uniffi_slim_rpc_fn_method_requeststream_next(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
123
126
  uniffi_slim_rpc_fn_method_requeststream_next_async(uniffiSelf: bigint): bigint;
127
+ uniffi_slim_rpc_fn_method_requeststreamwriter_cancel(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): void;
124
128
  uniffi_slim_rpc_fn_method_requeststreamwriter_finalize_async(uniffiSelf: bigint): bigint;
125
129
  uniffi_slim_rpc_fn_method_requeststreamwriter_finalize_stream(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
126
130
  uniffi_slim_rpc_fn_method_requeststreamwriter_finalize_stream_async(uniffiSelf: bigint): bigint;
@@ -134,6 +138,7 @@ interface NativeModuleInterface {
134
138
  uniffi_slim_rpc_fn_method_responsesink_send_async(uniffiSelf: bigint, data: Uint8Array): bigint;
135
139
  uniffi_slim_rpc_fn_method_responsesink_send_error(uniffiSelf: bigint, error: Uint8Array, uniffi_out_err: UniffiRustCallStatus): void;
136
140
  uniffi_slim_rpc_fn_method_responsesink_send_error_async(uniffiSelf: bigint, error: Uint8Array): bigint;
141
+ uniffi_slim_rpc_fn_method_responsestreamreader_cancel(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): void;
137
142
  uniffi_slim_rpc_fn_method_responsestreamreader_next(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
138
143
  uniffi_slim_rpc_fn_method_responsestreamreader_next_async(uniffiSelf: bigint): bigint;
139
144
  uniffi_slim_rpc_fn_constructor_server_new(app: bigint, baseName: bigint, uniffi_out_err: UniffiRustCallStatus): bigint;
@@ -151,6 +156,7 @@ interface NativeModuleInterface {
151
156
  uniffi_slim_rpc_fn_method_unarystreamhandler_handle(uniffiSelf: bigint, request: Uint8Array, context: bigint, sink: bigint): bigint;
152
157
  uniffi_slim_rpc_fn_method_unaryunaryhandler_handle(uniffiSelf: bigint, request: Uint8Array, context: bigint): bigint;
153
158
  ffi_slim_rpc_uniffi_contract_version(): number;
159
+ uniffi_slim_rpc_checksum_method_bidistreamhandler_cancel(): number;
154
160
  uniffi_slim_rpc_checksum_method_bidistreamhandler_close_send(): number;
155
161
  uniffi_slim_rpc_checksum_method_bidistreamhandler_close_send_async(): number;
156
162
  uniffi_slim_rpc_checksum_method_bidistreamhandler_recv(): number;
@@ -182,16 +188,19 @@ interface NativeModuleInterface {
182
188
  uniffi_slim_rpc_checksum_method_context_peer_subject(): number;
183
189
  uniffi_slim_rpc_checksum_method_context_remaining_time(): number;
184
190
  uniffi_slim_rpc_checksum_method_context_session_id(): number;
191
+ uniffi_slim_rpc_checksum_method_multicastbidistreamhandler_cancel(): number;
185
192
  uniffi_slim_rpc_checksum_method_multicastbidistreamhandler_close_send(): number;
186
193
  uniffi_slim_rpc_checksum_method_multicastbidistreamhandler_close_send_async(): number;
187
194
  uniffi_slim_rpc_checksum_method_multicastbidistreamhandler_recv(): number;
188
195
  uniffi_slim_rpc_checksum_method_multicastbidistreamhandler_recv_async(): number;
189
196
  uniffi_slim_rpc_checksum_method_multicastbidistreamhandler_send(): number;
190
197
  uniffi_slim_rpc_checksum_method_multicastbidistreamhandler_send_async(): number;
198
+ uniffi_slim_rpc_checksum_method_multicastresponsereader_cancel(): number;
191
199
  uniffi_slim_rpc_checksum_method_multicastresponsereader_next(): number;
192
200
  uniffi_slim_rpc_checksum_method_multicastresponsereader_next_async(): number;
193
201
  uniffi_slim_rpc_checksum_method_requeststream_next(): number;
194
202
  uniffi_slim_rpc_checksum_method_requeststream_next_async(): number;
203
+ uniffi_slim_rpc_checksum_method_requeststreamwriter_cancel(): number;
195
204
  uniffi_slim_rpc_checksum_method_requeststreamwriter_finalize_async(): number;
196
205
  uniffi_slim_rpc_checksum_method_requeststreamwriter_finalize_stream(): number;
197
206
  uniffi_slim_rpc_checksum_method_requeststreamwriter_finalize_stream_async(): number;
@@ -205,6 +214,7 @@ interface NativeModuleInterface {
205
214
  uniffi_slim_rpc_checksum_method_responsesink_send_async(): number;
206
215
  uniffi_slim_rpc_checksum_method_responsesink_send_error(): number;
207
216
  uniffi_slim_rpc_checksum_method_responsesink_send_error_async(): number;
217
+ uniffi_slim_rpc_checksum_method_responsestreamreader_cancel(): number;
208
218
  uniffi_slim_rpc_checksum_method_responsestreamreader_next(): number;
209
219
  uniffi_slim_rpc_checksum_method_responsestreamreader_next_async(): number;
210
220
  uniffi_slim_rpc_checksum_constructor_server_new(): number;
@@ -663,8 +663,20 @@ export type StreamMessage = InstanceType<typeof StreamMessage['Data' | 'Error' |
663
663
  * Allows sending and receiving messages concurrently.
664
664
  */
665
665
  export interface BidiStreamHandlerLike {
666
+ /**
667
+ * Cancel the call: the server stops its handler.
668
+ *
669
+ * Responses already received can still be read; after them, `recv`
670
+ * returns a `Cancelled` error, and `send` fails. Does nothing if the call
671
+ * has finished.
672
+ */
673
+ cancel(): void;
666
674
  /**
667
675
  * Close the request stream (no more messages will be sent)
676
+ *
677
+ * This only ends the request side. The server keeps running the call and
678
+ * its responses can still be received; use [`cancel`](Self::cancel) to
679
+ * stop it.
668
680
  */
669
681
  closeSend(): void;
670
682
  /**
@@ -708,8 +720,20 @@ export declare class BidiStreamHandler extends UniffiAbstractObject implements B
708
720
  readonly [destructorGuardSymbol]: UniffiGcObject;
709
721
  readonly [pointerLiteralSymbol]: UniffiHandle;
710
722
  private constructor();
723
+ /**
724
+ * Cancel the call: the server stops its handler.
725
+ *
726
+ * Responses already received can still be read; after them, `recv`
727
+ * returns a `Cancelled` error, and `send` fails. Does nothing if the call
728
+ * has finished.
729
+ */
730
+ cancel(): void;
711
731
  /**
712
732
  * Close the request stream (no more messages will be sent)
733
+ *
734
+ * This only ends the request side. The server keeps running the call and
735
+ * its responses can still be received; use [`cancel`](Self::cancel) to
736
+ * stop it.
713
737
  */
714
738
  closeSend(): void;
715
739
  /**
@@ -751,9 +775,21 @@ export declare class BidiStreamHandler extends UniffiAbstractObject implements B
751
775
  * response item carries the source member's identity.
752
776
  */
753
777
  export interface MulticastBidiStreamHandlerLike {
778
+ /**
779
+ * Cancel the call: every member stops its handler.
780
+ *
781
+ * Responses already received can still be read; after them, `recv`
782
+ * returns a `Cancelled` error, and `send` fails. Does nothing if the call
783
+ * has finished.
784
+ */
785
+ cancel(): void;
754
786
  /**
755
787
  * Close the request stream — signals that no more messages will be sent
756
788
  * (blocking).
789
+ *
790
+ * This only ends the request side. The members keep running the call and
791
+ * their responses can still be received; use [`cancel`](Self::cancel) to
792
+ * stop it.
757
793
  */
758
794
  closeSend(): void;
759
795
  /**
@@ -801,9 +837,21 @@ export declare class MulticastBidiStreamHandler extends UniffiAbstractObject imp
801
837
  readonly [destructorGuardSymbol]: UniffiGcObject;
802
838
  readonly [pointerLiteralSymbol]: UniffiHandle;
803
839
  private constructor();
840
+ /**
841
+ * Cancel the call: every member stops its handler.
842
+ *
843
+ * Responses already received can still be read; after them, `recv`
844
+ * returns a `Cancelled` error, and `send` fails. Does nothing if the call
845
+ * has finished.
846
+ */
847
+ cancel(): void;
804
848
  /**
805
849
  * Close the request stream — signals that no more messages will be sent
806
850
  * (blocking).
851
+ *
852
+ * This only ends the request side. The members keep running the call and
853
+ * their responses can still be received; use [`cancel`](Self::cancel) to
854
+ * stop it.
807
855
  */
808
856
  closeSend(): void;
809
857
  /**
@@ -842,6 +890,13 @@ export declare class MulticastBidiStreamHandler extends UniffiAbstractObject imp
842
890
  * time. Each item carries the source member's identity alongside the payload.
843
891
  */
844
892
  export interface MulticastResponseReaderLike {
893
+ /**
894
+ * Cancel the call: every member stops its handler.
895
+ *
896
+ * Responses already received can still be read; after them, `next`
897
+ * returns a `Cancelled` error. Does nothing if the call has finished.
898
+ */
899
+ cancel(): void;
845
900
  /**
846
901
  * Pull the next item from the multicast response stream (blocking).
847
902
  */
@@ -868,6 +923,13 @@ export declare class MulticastResponseReader extends UniffiAbstractObject implem
868
923
  readonly [destructorGuardSymbol]: UniffiGcObject;
869
924
  readonly [pointerLiteralSymbol]: UniffiHandle;
870
925
  private constructor();
926
+ /**
927
+ * Cancel the call: every member stops its handler.
928
+ *
929
+ * Responses already received can still be read; after them, `next`
930
+ * returns a `Cancelled` error. Does nothing if the call has finished.
931
+ */
932
+ cancel(): void;
871
933
  /**
872
934
  * Pull the next item from the multicast response stream (blocking).
873
935
  */
@@ -887,6 +949,13 @@ export declare class MulticastResponseReader extends UniffiAbstractObject implem
887
949
  * Allows sending multiple request messages and getting a final response.
888
950
  */
889
951
  export interface RequestStreamWriterLike {
952
+ /**
953
+ * Cancel the call: the server stops its handler.
954
+ *
955
+ * `send` and `finalize_stream` then return a `Cancelled` error. Does
956
+ * nothing if the call has finished.
957
+ */
958
+ cancel(): void;
890
959
  /**
891
960
  * Finalize the stream and get the response (async version)
892
961
  *
@@ -930,6 +999,13 @@ export declare class RequestStreamWriter extends UniffiAbstractObject implements
930
999
  readonly [destructorGuardSymbol]: UniffiGcObject;
931
1000
  readonly [pointerLiteralSymbol]: UniffiHandle;
932
1001
  private constructor();
1002
+ /**
1003
+ * Cancel the call: the server stops its handler.
1004
+ *
1005
+ * `send` and `finalize_stream` then return a `Cancelled` error. Does
1006
+ * nothing if the call has finished.
1007
+ */
1008
+ cancel(): void;
933
1009
  /**
934
1010
  * Finalize the stream and get the response (async version)
935
1011
  *
@@ -967,6 +1043,13 @@ export declare class RequestStreamWriter extends UniffiAbstractObject implements
967
1043
  * Allows pulling messages from a server response stream one at a time.
968
1044
  */
969
1045
  export interface ResponseStreamReaderLike {
1046
+ /**
1047
+ * Cancel the call: the server stops its handler.
1048
+ *
1049
+ * Messages already received can still be read; after them, `next`
1050
+ * returns a `Cancelled` error. Does nothing if the call has finished.
1051
+ */
1052
+ cancel(): void;
970
1053
  /**
971
1054
  * Pull the next message from the response stream (blocking version)
972
1055
  *
@@ -996,6 +1079,13 @@ export declare class ResponseStreamReader extends UniffiAbstractObject implement
996
1079
  readonly [destructorGuardSymbol]: UniffiGcObject;
997
1080
  readonly [pointerLiteralSymbol]: UniffiHandle;
998
1081
  private constructor();
1082
+ /**
1083
+ * Cancel the call: the server stops its handler.
1084
+ *
1085
+ * Messages already received can still be read; after them, `next`
1086
+ * returns a `Cancelled` error. Does nothing if the call has finished.
1087
+ */
1088
+ cancel(): void;
999
1089
  /**
1000
1090
  * Pull the next message from the response stream (blocking version)
1001
1091
  *