6 namespace org { namespace ldk { namespace structs {
9 * An event generated by ChannelManager which indicates a message should be sent to a peer (or
10 * broadcast to most peers).
11 * These events are handled by PeerManager::process_events if you are using a PeerManager.
13 public class MessageSendEvent : CommonBase {
14 protected MessageSendEvent(object _dummy, long ptr) : base(ptr) { }
16 if (ptr != 0) { bindings.MessageSendEvent_free(ptr); }
19 internal static MessageSendEvent constr_from_ptr(long ptr) {
20 long raw_ty = bindings.LDKMessageSendEvent_ty_from_ptr(ptr);
22 case 0: return new MessageSendEvent_SendAcceptChannel(ptr);
23 case 1: return new MessageSendEvent_SendAcceptChannelV2(ptr);
24 case 2: return new MessageSendEvent_SendOpenChannel(ptr);
25 case 3: return new MessageSendEvent_SendOpenChannelV2(ptr);
26 case 4: return new MessageSendEvent_SendFundingCreated(ptr);
27 case 5: return new MessageSendEvent_SendFundingSigned(ptr);
28 case 6: return new MessageSendEvent_SendTxAddInput(ptr);
29 case 7: return new MessageSendEvent_SendTxAddOutput(ptr);
30 case 8: return new MessageSendEvent_SendTxRemoveInput(ptr);
31 case 9: return new MessageSendEvent_SendTxRemoveOutput(ptr);
32 case 10: return new MessageSendEvent_SendTxComplete(ptr);
33 case 11: return new MessageSendEvent_SendTxSignatures(ptr);
34 case 12: return new MessageSendEvent_SendTxInitRbf(ptr);
35 case 13: return new MessageSendEvent_SendTxAckRbf(ptr);
36 case 14: return new MessageSendEvent_SendTxAbort(ptr);
37 case 15: return new MessageSendEvent_SendChannelReady(ptr);
38 case 16: return new MessageSendEvent_SendAnnouncementSignatures(ptr);
39 case 17: return new MessageSendEvent_UpdateHTLCs(ptr);
40 case 18: return new MessageSendEvent_SendRevokeAndACK(ptr);
41 case 19: return new MessageSendEvent_SendClosingSigned(ptr);
42 case 20: return new MessageSendEvent_SendShutdown(ptr);
43 case 21: return new MessageSendEvent_SendChannelReestablish(ptr);
44 case 22: return new MessageSendEvent_SendChannelAnnouncement(ptr);
45 case 23: return new MessageSendEvent_BroadcastChannelAnnouncement(ptr);
46 case 24: return new MessageSendEvent_BroadcastChannelUpdate(ptr);
47 case 25: return new MessageSendEvent_BroadcastNodeAnnouncement(ptr);
48 case 26: return new MessageSendEvent_SendChannelUpdate(ptr);
49 case 27: return new MessageSendEvent_HandleError(ptr);
50 case 28: return new MessageSendEvent_SendChannelRangeQuery(ptr);
51 case 29: return new MessageSendEvent_SendShortIdsQuery(ptr);
52 case 30: return new MessageSendEvent_SendReplyChannelRange(ptr);
53 case 31: return new MessageSendEvent_SendGossipTimestampFilter(ptr);
55 throw new ArgumentException("Impossible enum variant");
59 /** A MessageSendEvent of type SendAcceptChannel */
60 public class MessageSendEvent_SendAcceptChannel : MessageSendEvent {
62 * The node_id of the node which should receive this message
64 public byte[] node_id;
66 * The message which should be sent.
68 public AcceptChannel msg;
69 internal MessageSendEvent_SendAcceptChannel(long ptr) : base(null, ptr) {
70 this.node_id = bindings.LDKMessageSendEvent_SendAcceptChannel_get_node_id(ptr);
71 long msg = bindings.LDKMessageSendEvent_SendAcceptChannel_get_msg(ptr);
72 org.ldk.structs.AcceptChannel msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.AcceptChannel(null, msg); }
73 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
74 this.msg = msg_hu_conv;
77 /** A MessageSendEvent of type SendAcceptChannelV2 */
78 public class MessageSendEvent_SendAcceptChannelV2 : MessageSendEvent {
80 * The node_id of the node which should receive this message
82 public byte[] node_id;
84 * The message which should be sent.
86 public AcceptChannelV2 msg;
87 internal MessageSendEvent_SendAcceptChannelV2(long ptr) : base(null, ptr) {
88 this.node_id = bindings.LDKMessageSendEvent_SendAcceptChannelV2_get_node_id(ptr);
89 long msg = bindings.LDKMessageSendEvent_SendAcceptChannelV2_get_msg(ptr);
90 org.ldk.structs.AcceptChannelV2 msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.AcceptChannelV2(null, msg); }
91 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
92 this.msg = msg_hu_conv;
95 /** A MessageSendEvent of type SendOpenChannel */
96 public class MessageSendEvent_SendOpenChannel : MessageSendEvent {
98 * The node_id of the node which should receive this message
100 public byte[] node_id;
102 * The message which should be sent.
104 public OpenChannel msg;
105 internal MessageSendEvent_SendOpenChannel(long ptr) : base(null, ptr) {
106 this.node_id = bindings.LDKMessageSendEvent_SendOpenChannel_get_node_id(ptr);
107 long msg = bindings.LDKMessageSendEvent_SendOpenChannel_get_msg(ptr);
108 org.ldk.structs.OpenChannel msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.OpenChannel(null, msg); }
109 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
110 this.msg = msg_hu_conv;
113 /** A MessageSendEvent of type SendOpenChannelV2 */
114 public class MessageSendEvent_SendOpenChannelV2 : MessageSendEvent {
116 * The node_id of the node which should receive this message
118 public byte[] node_id;
120 * The message which should be sent.
122 public OpenChannelV2 msg;
123 internal MessageSendEvent_SendOpenChannelV2(long ptr) : base(null, ptr) {
124 this.node_id = bindings.LDKMessageSendEvent_SendOpenChannelV2_get_node_id(ptr);
125 long msg = bindings.LDKMessageSendEvent_SendOpenChannelV2_get_msg(ptr);
126 org.ldk.structs.OpenChannelV2 msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.OpenChannelV2(null, msg); }
127 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
128 this.msg = msg_hu_conv;
131 /** A MessageSendEvent of type SendFundingCreated */
132 public class MessageSendEvent_SendFundingCreated : MessageSendEvent {
134 * The node_id of the node which should receive this message
136 public byte[] node_id;
138 * The message which should be sent.
140 public FundingCreated msg;
141 internal MessageSendEvent_SendFundingCreated(long ptr) : base(null, ptr) {
142 this.node_id = bindings.LDKMessageSendEvent_SendFundingCreated_get_node_id(ptr);
143 long msg = bindings.LDKMessageSendEvent_SendFundingCreated_get_msg(ptr);
144 org.ldk.structs.FundingCreated msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.FundingCreated(null, msg); }
145 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
146 this.msg = msg_hu_conv;
149 /** A MessageSendEvent of type SendFundingSigned */
150 public class MessageSendEvent_SendFundingSigned : MessageSendEvent {
152 * The node_id of the node which should receive this message
154 public byte[] node_id;
156 * The message which should be sent.
158 public FundingSigned msg;
159 internal MessageSendEvent_SendFundingSigned(long ptr) : base(null, ptr) {
160 this.node_id = bindings.LDKMessageSendEvent_SendFundingSigned_get_node_id(ptr);
161 long msg = bindings.LDKMessageSendEvent_SendFundingSigned_get_msg(ptr);
162 org.ldk.structs.FundingSigned msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.FundingSigned(null, msg); }
163 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
164 this.msg = msg_hu_conv;
167 /** A MessageSendEvent of type SendTxAddInput */
168 public class MessageSendEvent_SendTxAddInput : MessageSendEvent {
170 * The node_id of the node which should receive this message
172 public byte[] node_id;
174 * The message which should be sent.
176 public TxAddInput msg;
177 internal MessageSendEvent_SendTxAddInput(long ptr) : base(null, ptr) {
178 this.node_id = bindings.LDKMessageSendEvent_SendTxAddInput_get_node_id(ptr);
179 long msg = bindings.LDKMessageSendEvent_SendTxAddInput_get_msg(ptr);
180 org.ldk.structs.TxAddInput msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.TxAddInput(null, msg); }
181 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
182 this.msg = msg_hu_conv;
185 /** A MessageSendEvent of type SendTxAddOutput */
186 public class MessageSendEvent_SendTxAddOutput : MessageSendEvent {
188 * The node_id of the node which should receive this message
190 public byte[] node_id;
192 * The message which should be sent.
194 public TxAddOutput msg;
195 internal MessageSendEvent_SendTxAddOutput(long ptr) : base(null, ptr) {
196 this.node_id = bindings.LDKMessageSendEvent_SendTxAddOutput_get_node_id(ptr);
197 long msg = bindings.LDKMessageSendEvent_SendTxAddOutput_get_msg(ptr);
198 org.ldk.structs.TxAddOutput msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.TxAddOutput(null, msg); }
199 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
200 this.msg = msg_hu_conv;
203 /** A MessageSendEvent of type SendTxRemoveInput */
204 public class MessageSendEvent_SendTxRemoveInput : MessageSendEvent {
206 * The node_id of the node which should receive this message
208 public byte[] node_id;
210 * The message which should be sent.
212 public TxRemoveInput msg;
213 internal MessageSendEvent_SendTxRemoveInput(long ptr) : base(null, ptr) {
214 this.node_id = bindings.LDKMessageSendEvent_SendTxRemoveInput_get_node_id(ptr);
215 long msg = bindings.LDKMessageSendEvent_SendTxRemoveInput_get_msg(ptr);
216 org.ldk.structs.TxRemoveInput msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.TxRemoveInput(null, msg); }
217 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
218 this.msg = msg_hu_conv;
221 /** A MessageSendEvent of type SendTxRemoveOutput */
222 public class MessageSendEvent_SendTxRemoveOutput : MessageSendEvent {
224 * The node_id of the node which should receive this message
226 public byte[] node_id;
228 * The message which should be sent.
230 public TxRemoveOutput msg;
231 internal MessageSendEvent_SendTxRemoveOutput(long ptr) : base(null, ptr) {
232 this.node_id = bindings.LDKMessageSendEvent_SendTxRemoveOutput_get_node_id(ptr);
233 long msg = bindings.LDKMessageSendEvent_SendTxRemoveOutput_get_msg(ptr);
234 org.ldk.structs.TxRemoveOutput msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.TxRemoveOutput(null, msg); }
235 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
236 this.msg = msg_hu_conv;
239 /** A MessageSendEvent of type SendTxComplete */
240 public class MessageSendEvent_SendTxComplete : MessageSendEvent {
242 * The node_id of the node which should receive this message
244 public byte[] node_id;
246 * The message which should be sent.
248 public TxComplete msg;
249 internal MessageSendEvent_SendTxComplete(long ptr) : base(null, ptr) {
250 this.node_id = bindings.LDKMessageSendEvent_SendTxComplete_get_node_id(ptr);
251 long msg = bindings.LDKMessageSendEvent_SendTxComplete_get_msg(ptr);
252 org.ldk.structs.TxComplete msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.TxComplete(null, msg); }
253 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
254 this.msg = msg_hu_conv;
257 /** A MessageSendEvent of type SendTxSignatures */
258 public class MessageSendEvent_SendTxSignatures : MessageSendEvent {
260 * The node_id of the node which should receive this message
262 public byte[] node_id;
264 * The message which should be sent.
266 public TxSignatures msg;
267 internal MessageSendEvent_SendTxSignatures(long ptr) : base(null, ptr) {
268 this.node_id = bindings.LDKMessageSendEvent_SendTxSignatures_get_node_id(ptr);
269 long msg = bindings.LDKMessageSendEvent_SendTxSignatures_get_msg(ptr);
270 org.ldk.structs.TxSignatures msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.TxSignatures(null, msg); }
271 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
272 this.msg = msg_hu_conv;
275 /** A MessageSendEvent of type SendTxInitRbf */
276 public class MessageSendEvent_SendTxInitRbf : MessageSendEvent {
278 * The node_id of the node which should receive this message
280 public byte[] node_id;
282 * The message which should be sent.
284 public TxInitRbf msg;
285 internal MessageSendEvent_SendTxInitRbf(long ptr) : base(null, ptr) {
286 this.node_id = bindings.LDKMessageSendEvent_SendTxInitRbf_get_node_id(ptr);
287 long msg = bindings.LDKMessageSendEvent_SendTxInitRbf_get_msg(ptr);
288 org.ldk.structs.TxInitRbf msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.TxInitRbf(null, msg); }
289 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
290 this.msg = msg_hu_conv;
293 /** A MessageSendEvent of type SendTxAckRbf */
294 public class MessageSendEvent_SendTxAckRbf : MessageSendEvent {
296 * The node_id of the node which should receive this message
298 public byte[] node_id;
300 * The message which should be sent.
303 internal MessageSendEvent_SendTxAckRbf(long ptr) : base(null, ptr) {
304 this.node_id = bindings.LDKMessageSendEvent_SendTxAckRbf_get_node_id(ptr);
305 long msg = bindings.LDKMessageSendEvent_SendTxAckRbf_get_msg(ptr);
306 org.ldk.structs.TxAckRbf msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.TxAckRbf(null, msg); }
307 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
308 this.msg = msg_hu_conv;
311 /** A MessageSendEvent of type SendTxAbort */
312 public class MessageSendEvent_SendTxAbort : MessageSendEvent {
314 * The node_id of the node which should receive this message
316 public byte[] node_id;
318 * The message which should be sent.
320 public TxAddInput msg;
321 internal MessageSendEvent_SendTxAbort(long ptr) : base(null, ptr) {
322 this.node_id = bindings.LDKMessageSendEvent_SendTxAbort_get_node_id(ptr);
323 long msg = bindings.LDKMessageSendEvent_SendTxAbort_get_msg(ptr);
324 org.ldk.structs.TxAddInput msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.TxAddInput(null, msg); }
325 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
326 this.msg = msg_hu_conv;
329 /** A MessageSendEvent of type SendChannelReady */
330 public class MessageSendEvent_SendChannelReady : MessageSendEvent {
332 * The node_id of the node which should receive these message(s)
334 public byte[] node_id;
336 * The channel_ready message which should be sent.
338 public ChannelReady msg;
339 internal MessageSendEvent_SendChannelReady(long ptr) : base(null, ptr) {
340 this.node_id = bindings.LDKMessageSendEvent_SendChannelReady_get_node_id(ptr);
341 long msg = bindings.LDKMessageSendEvent_SendChannelReady_get_msg(ptr);
342 org.ldk.structs.ChannelReady msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.ChannelReady(null, msg); }
343 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
344 this.msg = msg_hu_conv;
347 /** A MessageSendEvent of type SendAnnouncementSignatures */
348 public class MessageSendEvent_SendAnnouncementSignatures : MessageSendEvent {
350 * The node_id of the node which should receive these message(s)
352 public byte[] node_id;
354 * The announcement_signatures message which should be sent.
356 public AnnouncementSignatures msg;
357 internal MessageSendEvent_SendAnnouncementSignatures(long ptr) : base(null, ptr) {
358 this.node_id = bindings.LDKMessageSendEvent_SendAnnouncementSignatures_get_node_id(ptr);
359 long msg = bindings.LDKMessageSendEvent_SendAnnouncementSignatures_get_msg(ptr);
360 org.ldk.structs.AnnouncementSignatures msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.AnnouncementSignatures(null, msg); }
361 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
362 this.msg = msg_hu_conv;
365 /** A MessageSendEvent of type UpdateHTLCs */
366 public class MessageSendEvent_UpdateHTLCs : MessageSendEvent {
368 * The node_id of the node which should receive these message(s)
370 public byte[] node_id;
372 * The update messages which should be sent. ALL messages in the struct should be sent!
374 public CommitmentUpdate updates;
375 internal MessageSendEvent_UpdateHTLCs(long ptr) : base(null, ptr) {
376 this.node_id = bindings.LDKMessageSendEvent_UpdateHTLCs_get_node_id(ptr);
377 long updates = bindings.LDKMessageSendEvent_UpdateHTLCs_get_updates(ptr);
378 org.ldk.structs.CommitmentUpdate updates_hu_conv = null; if (updates < 0 || updates > 4096) { updates_hu_conv = new org.ldk.structs.CommitmentUpdate(null, updates); }
379 if (updates_hu_conv != null) { updates_hu_conv.ptrs_to.AddLast(this); };
380 this.updates = updates_hu_conv;
383 /** A MessageSendEvent of type SendRevokeAndACK */
384 public class MessageSendEvent_SendRevokeAndACK : MessageSendEvent {
386 * The node_id of the node which should receive this message
388 public byte[] node_id;
390 * The message which should be sent.
392 public RevokeAndACK msg;
393 internal MessageSendEvent_SendRevokeAndACK(long ptr) : base(null, ptr) {
394 this.node_id = bindings.LDKMessageSendEvent_SendRevokeAndACK_get_node_id(ptr);
395 long msg = bindings.LDKMessageSendEvent_SendRevokeAndACK_get_msg(ptr);
396 org.ldk.structs.RevokeAndACK msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.RevokeAndACK(null, msg); }
397 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
398 this.msg = msg_hu_conv;
401 /** A MessageSendEvent of type SendClosingSigned */
402 public class MessageSendEvent_SendClosingSigned : MessageSendEvent {
404 * The node_id of the node which should receive this message
406 public byte[] node_id;
408 * The message which should be sent.
410 public ClosingSigned msg;
411 internal MessageSendEvent_SendClosingSigned(long ptr) : base(null, ptr) {
412 this.node_id = bindings.LDKMessageSendEvent_SendClosingSigned_get_node_id(ptr);
413 long msg = bindings.LDKMessageSendEvent_SendClosingSigned_get_msg(ptr);
414 org.ldk.structs.ClosingSigned msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.ClosingSigned(null, msg); }
415 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
416 this.msg = msg_hu_conv;
419 /** A MessageSendEvent of type SendShutdown */
420 public class MessageSendEvent_SendShutdown : MessageSendEvent {
422 * The node_id of the node which should receive this message
424 public byte[] node_id;
426 * The message which should be sent.
429 internal MessageSendEvent_SendShutdown(long ptr) : base(null, ptr) {
430 this.node_id = bindings.LDKMessageSendEvent_SendShutdown_get_node_id(ptr);
431 long msg = bindings.LDKMessageSendEvent_SendShutdown_get_msg(ptr);
432 org.ldk.structs.Shutdown msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.Shutdown(null, msg); }
433 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
434 this.msg = msg_hu_conv;
437 /** A MessageSendEvent of type SendChannelReestablish */
438 public class MessageSendEvent_SendChannelReestablish : MessageSendEvent {
440 * The node_id of the node which should receive this message
442 public byte[] node_id;
444 * The message which should be sent.
446 public ChannelReestablish msg;
447 internal MessageSendEvent_SendChannelReestablish(long ptr) : base(null, ptr) {
448 this.node_id = bindings.LDKMessageSendEvent_SendChannelReestablish_get_node_id(ptr);
449 long msg = bindings.LDKMessageSendEvent_SendChannelReestablish_get_msg(ptr);
450 org.ldk.structs.ChannelReestablish msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.ChannelReestablish(null, msg); }
451 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
452 this.msg = msg_hu_conv;
455 /** A MessageSendEvent of type SendChannelAnnouncement */
456 public class MessageSendEvent_SendChannelAnnouncement : MessageSendEvent {
458 * The node_id of the node which should receive this message
460 public byte[] node_id;
462 * The channel_announcement which should be sent.
464 public ChannelAnnouncement msg;
466 * The followup channel_update which should be sent.
468 public ChannelUpdate update_msg;
469 internal MessageSendEvent_SendChannelAnnouncement(long ptr) : base(null, ptr) {
470 this.node_id = bindings.LDKMessageSendEvent_SendChannelAnnouncement_get_node_id(ptr);
471 long msg = bindings.LDKMessageSendEvent_SendChannelAnnouncement_get_msg(ptr);
472 org.ldk.structs.ChannelAnnouncement msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.ChannelAnnouncement(null, msg); }
473 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
474 this.msg = msg_hu_conv;
475 long update_msg = bindings.LDKMessageSendEvent_SendChannelAnnouncement_get_update_msg(ptr);
476 org.ldk.structs.ChannelUpdate update_msg_hu_conv = null; if (update_msg < 0 || update_msg > 4096) { update_msg_hu_conv = new org.ldk.structs.ChannelUpdate(null, update_msg); }
477 if (update_msg_hu_conv != null) { update_msg_hu_conv.ptrs_to.AddLast(this); };
478 this.update_msg = update_msg_hu_conv;
481 /** A MessageSendEvent of type BroadcastChannelAnnouncement */
482 public class MessageSendEvent_BroadcastChannelAnnouncement : MessageSendEvent {
484 * The channel_announcement which should be sent.
486 public ChannelAnnouncement msg;
488 * The followup channel_update which should be sent.
490 * Note that this (or a relevant inner pointer) may be NULL or all-0s to represent None
492 public ChannelUpdate update_msg;
493 internal MessageSendEvent_BroadcastChannelAnnouncement(long ptr) : base(null, ptr) {
494 long msg = bindings.LDKMessageSendEvent_BroadcastChannelAnnouncement_get_msg(ptr);
495 org.ldk.structs.ChannelAnnouncement msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.ChannelAnnouncement(null, msg); }
496 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
497 this.msg = msg_hu_conv;
498 long update_msg = bindings.LDKMessageSendEvent_BroadcastChannelAnnouncement_get_update_msg(ptr);
499 org.ldk.structs.ChannelUpdate update_msg_hu_conv = null; if (update_msg < 0 || update_msg > 4096) { update_msg_hu_conv = new org.ldk.structs.ChannelUpdate(null, update_msg); }
500 if (update_msg_hu_conv != null) { update_msg_hu_conv.ptrs_to.AddLast(this); };
501 this.update_msg = update_msg_hu_conv;
504 /** A MessageSendEvent of type BroadcastChannelUpdate */
505 public class MessageSendEvent_BroadcastChannelUpdate : MessageSendEvent {
507 * The channel_update which should be sent.
509 public ChannelUpdate msg;
510 internal MessageSendEvent_BroadcastChannelUpdate(long ptr) : base(null, ptr) {
511 long msg = bindings.LDKMessageSendEvent_BroadcastChannelUpdate_get_msg(ptr);
512 org.ldk.structs.ChannelUpdate msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.ChannelUpdate(null, msg); }
513 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
514 this.msg = msg_hu_conv;
517 /** A MessageSendEvent of type BroadcastNodeAnnouncement */
518 public class MessageSendEvent_BroadcastNodeAnnouncement : MessageSendEvent {
520 * The node_announcement which should be sent.
522 public NodeAnnouncement msg;
523 internal MessageSendEvent_BroadcastNodeAnnouncement(long ptr) : base(null, ptr) {
524 long msg = bindings.LDKMessageSendEvent_BroadcastNodeAnnouncement_get_msg(ptr);
525 org.ldk.structs.NodeAnnouncement msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.NodeAnnouncement(null, msg); }
526 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
527 this.msg = msg_hu_conv;
530 /** A MessageSendEvent of type SendChannelUpdate */
531 public class MessageSendEvent_SendChannelUpdate : MessageSendEvent {
533 * The node_id of the node which should receive this message
535 public byte[] node_id;
537 * The channel_update which should be sent.
539 public ChannelUpdate msg;
540 internal MessageSendEvent_SendChannelUpdate(long ptr) : base(null, ptr) {
541 this.node_id = bindings.LDKMessageSendEvent_SendChannelUpdate_get_node_id(ptr);
542 long msg = bindings.LDKMessageSendEvent_SendChannelUpdate_get_msg(ptr);
543 org.ldk.structs.ChannelUpdate msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.ChannelUpdate(null, msg); }
544 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
545 this.msg = msg_hu_conv;
548 /** A MessageSendEvent of type HandleError */
549 public class MessageSendEvent_HandleError : MessageSendEvent {
551 * The node_id of the node which should receive this message
553 public byte[] node_id;
555 * The action which should be taken.
557 public ErrorAction action;
558 internal MessageSendEvent_HandleError(long ptr) : base(null, ptr) {
559 this.node_id = bindings.LDKMessageSendEvent_HandleError_get_node_id(ptr);
560 long action = bindings.LDKMessageSendEvent_HandleError_get_action(ptr);
561 org.ldk.structs.ErrorAction action_hu_conv = org.ldk.structs.ErrorAction.constr_from_ptr(action);
562 if (action_hu_conv != null) { action_hu_conv.ptrs_to.AddLast(this); };
563 this.action = action_hu_conv;
566 /** A MessageSendEvent of type SendChannelRangeQuery */
567 public class MessageSendEvent_SendChannelRangeQuery : MessageSendEvent {
569 * The node_id of this message recipient
571 public byte[] node_id;
573 * The query_channel_range which should be sent.
575 public QueryChannelRange msg;
576 internal MessageSendEvent_SendChannelRangeQuery(long ptr) : base(null, ptr) {
577 this.node_id = bindings.LDKMessageSendEvent_SendChannelRangeQuery_get_node_id(ptr);
578 long msg = bindings.LDKMessageSendEvent_SendChannelRangeQuery_get_msg(ptr);
579 org.ldk.structs.QueryChannelRange msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.QueryChannelRange(null, msg); }
580 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
581 this.msg = msg_hu_conv;
584 /** A MessageSendEvent of type SendShortIdsQuery */
585 public class MessageSendEvent_SendShortIdsQuery : MessageSendEvent {
587 * The node_id of this message recipient
589 public byte[] node_id;
591 * The query_short_channel_ids which should be sent.
593 public QueryShortChannelIds msg;
594 internal MessageSendEvent_SendShortIdsQuery(long ptr) : base(null, ptr) {
595 this.node_id = bindings.LDKMessageSendEvent_SendShortIdsQuery_get_node_id(ptr);
596 long msg = bindings.LDKMessageSendEvent_SendShortIdsQuery_get_msg(ptr);
597 org.ldk.structs.QueryShortChannelIds msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.QueryShortChannelIds(null, msg); }
598 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
599 this.msg = msg_hu_conv;
602 /** A MessageSendEvent of type SendReplyChannelRange */
603 public class MessageSendEvent_SendReplyChannelRange : MessageSendEvent {
605 * The node_id of this message recipient
607 public byte[] node_id;
609 * The reply_channel_range which should be sent.
611 public ReplyChannelRange msg;
612 internal MessageSendEvent_SendReplyChannelRange(long ptr) : base(null, ptr) {
613 this.node_id = bindings.LDKMessageSendEvent_SendReplyChannelRange_get_node_id(ptr);
614 long msg = bindings.LDKMessageSendEvent_SendReplyChannelRange_get_msg(ptr);
615 org.ldk.structs.ReplyChannelRange msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.ReplyChannelRange(null, msg); }
616 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
617 this.msg = msg_hu_conv;
620 /** A MessageSendEvent of type SendGossipTimestampFilter */
621 public class MessageSendEvent_SendGossipTimestampFilter : MessageSendEvent {
623 * The node_id of this message recipient
625 public byte[] node_id;
627 * The gossip_timestamp_filter which should be sent.
629 public GossipTimestampFilter msg;
630 internal MessageSendEvent_SendGossipTimestampFilter(long ptr) : base(null, ptr) {
631 this.node_id = bindings.LDKMessageSendEvent_SendGossipTimestampFilter_get_node_id(ptr);
632 long msg = bindings.LDKMessageSendEvent_SendGossipTimestampFilter_get_msg(ptr);
633 org.ldk.structs.GossipTimestampFilter msg_hu_conv = null; if (msg < 0 || msg > 4096) { msg_hu_conv = new org.ldk.structs.GossipTimestampFilter(null, msg); }
634 if (msg_hu_conv != null) { msg_hu_conv.ptrs_to.AddLast(this); };
635 this.msg = msg_hu_conv;
638 internal long clone_ptr() {
639 long ret = bindings.MessageSendEvent_clone_ptr(this.ptr);
645 * Creates a copy of the MessageSendEvent
647 public MessageSendEvent clone() {
648 long ret = bindings.MessageSendEvent_clone(this.ptr);
650 if (ret >= 0 && ret <= 4096) { return null; }
651 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
652 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(this); };
657 * Utility method to constructs a new SendAcceptChannel-variant MessageSendEvent
659 public static MessageSendEvent send_accept_channel(byte[] node_id, org.ldk.structs.AcceptChannel msg) {
660 long ret = bindings.MessageSendEvent_send_accept_channel(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
661 GC.KeepAlive(node_id);
663 if (ret >= 0 && ret <= 4096) { return null; }
664 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
665 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
666 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
671 * Utility method to constructs a new SendAcceptChannelV2-variant MessageSendEvent
673 public static MessageSendEvent send_accept_channel_v2(byte[] node_id, org.ldk.structs.AcceptChannelV2 msg) {
674 long ret = bindings.MessageSendEvent_send_accept_channel_v2(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
675 GC.KeepAlive(node_id);
677 if (ret >= 0 && ret <= 4096) { return null; }
678 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
679 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
680 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
685 * Utility method to constructs a new SendOpenChannel-variant MessageSendEvent
687 public static MessageSendEvent send_open_channel(byte[] node_id, org.ldk.structs.OpenChannel msg) {
688 long ret = bindings.MessageSendEvent_send_open_channel(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
689 GC.KeepAlive(node_id);
691 if (ret >= 0 && ret <= 4096) { return null; }
692 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
693 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
694 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
699 * Utility method to constructs a new SendOpenChannelV2-variant MessageSendEvent
701 public static MessageSendEvent send_open_channel_v2(byte[] node_id, org.ldk.structs.OpenChannelV2 msg) {
702 long ret = bindings.MessageSendEvent_send_open_channel_v2(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
703 GC.KeepAlive(node_id);
705 if (ret >= 0 && ret <= 4096) { return null; }
706 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
707 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
708 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
713 * Utility method to constructs a new SendFundingCreated-variant MessageSendEvent
715 public static MessageSendEvent send_funding_created(byte[] node_id, org.ldk.structs.FundingCreated msg) {
716 long ret = bindings.MessageSendEvent_send_funding_created(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
717 GC.KeepAlive(node_id);
719 if (ret >= 0 && ret <= 4096) { return null; }
720 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
721 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
722 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
727 * Utility method to constructs a new SendFundingSigned-variant MessageSendEvent
729 public static MessageSendEvent send_funding_signed(byte[] node_id, org.ldk.structs.FundingSigned msg) {
730 long ret = bindings.MessageSendEvent_send_funding_signed(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
731 GC.KeepAlive(node_id);
733 if (ret >= 0 && ret <= 4096) { return null; }
734 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
735 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
736 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
741 * Utility method to constructs a new SendTxAddInput-variant MessageSendEvent
743 public static MessageSendEvent send_tx_add_input(byte[] node_id, org.ldk.structs.TxAddInput msg) {
744 long ret = bindings.MessageSendEvent_send_tx_add_input(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
745 GC.KeepAlive(node_id);
747 if (ret >= 0 && ret <= 4096) { return null; }
748 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
749 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
750 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
755 * Utility method to constructs a new SendTxAddOutput-variant MessageSendEvent
757 public static MessageSendEvent send_tx_add_output(byte[] node_id, org.ldk.structs.TxAddOutput msg) {
758 long ret = bindings.MessageSendEvent_send_tx_add_output(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
759 GC.KeepAlive(node_id);
761 if (ret >= 0 && ret <= 4096) { return null; }
762 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
763 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
764 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
769 * Utility method to constructs a new SendTxRemoveInput-variant MessageSendEvent
771 public static MessageSendEvent send_tx_remove_input(byte[] node_id, org.ldk.structs.TxRemoveInput msg) {
772 long ret = bindings.MessageSendEvent_send_tx_remove_input(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
773 GC.KeepAlive(node_id);
775 if (ret >= 0 && ret <= 4096) { return null; }
776 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
777 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
778 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
783 * Utility method to constructs a new SendTxRemoveOutput-variant MessageSendEvent
785 public static MessageSendEvent send_tx_remove_output(byte[] node_id, org.ldk.structs.TxRemoveOutput msg) {
786 long ret = bindings.MessageSendEvent_send_tx_remove_output(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
787 GC.KeepAlive(node_id);
789 if (ret >= 0 && ret <= 4096) { return null; }
790 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
791 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
792 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
797 * Utility method to constructs a new SendTxComplete-variant MessageSendEvent
799 public static MessageSendEvent send_tx_complete(byte[] node_id, org.ldk.structs.TxComplete msg) {
800 long ret = bindings.MessageSendEvent_send_tx_complete(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
801 GC.KeepAlive(node_id);
803 if (ret >= 0 && ret <= 4096) { return null; }
804 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
805 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
806 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
811 * Utility method to constructs a new SendTxSignatures-variant MessageSendEvent
813 public static MessageSendEvent send_tx_signatures(byte[] node_id, org.ldk.structs.TxSignatures msg) {
814 long ret = bindings.MessageSendEvent_send_tx_signatures(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
815 GC.KeepAlive(node_id);
817 if (ret >= 0 && ret <= 4096) { return null; }
818 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
819 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
820 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
825 * Utility method to constructs a new SendTxInitRbf-variant MessageSendEvent
827 public static MessageSendEvent send_tx_init_rbf(byte[] node_id, org.ldk.structs.TxInitRbf msg) {
828 long ret = bindings.MessageSendEvent_send_tx_init_rbf(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
829 GC.KeepAlive(node_id);
831 if (ret >= 0 && ret <= 4096) { return null; }
832 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
833 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
834 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
839 * Utility method to constructs a new SendTxAckRbf-variant MessageSendEvent
841 public static MessageSendEvent send_tx_ack_rbf(byte[] node_id, org.ldk.structs.TxAckRbf msg) {
842 long ret = bindings.MessageSendEvent_send_tx_ack_rbf(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
843 GC.KeepAlive(node_id);
845 if (ret >= 0 && ret <= 4096) { return null; }
846 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
847 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
848 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
853 * Utility method to constructs a new SendTxAbort-variant MessageSendEvent
855 public static MessageSendEvent send_tx_abort(byte[] node_id, org.ldk.structs.TxAddInput msg) {
856 long ret = bindings.MessageSendEvent_send_tx_abort(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
857 GC.KeepAlive(node_id);
859 if (ret >= 0 && ret <= 4096) { return null; }
860 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
861 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
862 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
867 * Utility method to constructs a new SendChannelReady-variant MessageSendEvent
869 public static MessageSendEvent send_channel_ready(byte[] node_id, org.ldk.structs.ChannelReady msg) {
870 long ret = bindings.MessageSendEvent_send_channel_ready(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
871 GC.KeepAlive(node_id);
873 if (ret >= 0 && ret <= 4096) { return null; }
874 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
875 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
876 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
881 * Utility method to constructs a new SendAnnouncementSignatures-variant MessageSendEvent
883 public static MessageSendEvent send_announcement_signatures(byte[] node_id, org.ldk.structs.AnnouncementSignatures msg) {
884 long ret = bindings.MessageSendEvent_send_announcement_signatures(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
885 GC.KeepAlive(node_id);
887 if (ret >= 0 && ret <= 4096) { return null; }
888 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
889 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
890 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
895 * Utility method to constructs a new UpdateHTLCs-variant MessageSendEvent
897 public static MessageSendEvent update_htlcs(byte[] node_id, org.ldk.structs.CommitmentUpdate updates) {
898 long ret = bindings.MessageSendEvent_update_htlcs(InternalUtils.check_arr_len(node_id, 33), updates == null ? 0 : updates.ptr);
899 GC.KeepAlive(node_id);
900 GC.KeepAlive(updates);
901 if (ret >= 0 && ret <= 4096) { return null; }
902 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
903 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
904 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(updates); };
909 * Utility method to constructs a new SendRevokeAndACK-variant MessageSendEvent
911 public static MessageSendEvent send_revoke_and_ack(byte[] node_id, org.ldk.structs.RevokeAndACK msg) {
912 long ret = bindings.MessageSendEvent_send_revoke_and_ack(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
913 GC.KeepAlive(node_id);
915 if (ret >= 0 && ret <= 4096) { return null; }
916 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
917 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
918 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
923 * Utility method to constructs a new SendClosingSigned-variant MessageSendEvent
925 public static MessageSendEvent send_closing_signed(byte[] node_id, org.ldk.structs.ClosingSigned msg) {
926 long ret = bindings.MessageSendEvent_send_closing_signed(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
927 GC.KeepAlive(node_id);
929 if (ret >= 0 && ret <= 4096) { return null; }
930 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
931 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
932 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
937 * Utility method to constructs a new SendShutdown-variant MessageSendEvent
939 public static MessageSendEvent send_shutdown(byte[] node_id, org.ldk.structs.Shutdown msg) {
940 long ret = bindings.MessageSendEvent_send_shutdown(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
941 GC.KeepAlive(node_id);
943 if (ret >= 0 && ret <= 4096) { return null; }
944 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
945 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
946 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
951 * Utility method to constructs a new SendChannelReestablish-variant MessageSendEvent
953 public static MessageSendEvent send_channel_reestablish(byte[] node_id, org.ldk.structs.ChannelReestablish msg) {
954 long ret = bindings.MessageSendEvent_send_channel_reestablish(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
955 GC.KeepAlive(node_id);
957 if (ret >= 0 && ret <= 4096) { return null; }
958 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
959 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
960 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
965 * Utility method to constructs a new SendChannelAnnouncement-variant MessageSendEvent
967 public static MessageSendEvent send_channel_announcement(byte[] node_id, org.ldk.structs.ChannelAnnouncement msg, org.ldk.structs.ChannelUpdate update_msg) {
968 long ret = bindings.MessageSendEvent_send_channel_announcement(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr, update_msg == null ? 0 : update_msg.ptr);
969 GC.KeepAlive(node_id);
971 GC.KeepAlive(update_msg);
972 if (ret >= 0 && ret <= 4096) { return null; }
973 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
974 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
975 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
976 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(update_msg); };
981 * Utility method to constructs a new BroadcastChannelAnnouncement-variant MessageSendEvent
983 public static MessageSendEvent broadcast_channel_announcement(org.ldk.structs.ChannelAnnouncement msg, org.ldk.structs.ChannelUpdate update_msg) {
984 long ret = bindings.MessageSendEvent_broadcast_channel_announcement(msg == null ? 0 : msg.ptr, update_msg == null ? 0 : update_msg.ptr);
986 GC.KeepAlive(update_msg);
987 if (ret >= 0 && ret <= 4096) { return null; }
988 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
989 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
990 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
991 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(update_msg); };
996 * Utility method to constructs a new BroadcastChannelUpdate-variant MessageSendEvent
998 public static MessageSendEvent broadcast_channel_update(org.ldk.structs.ChannelUpdate msg) {
999 long ret = bindings.MessageSendEvent_broadcast_channel_update(msg == null ? 0 : msg.ptr);
1001 if (ret >= 0 && ret <= 4096) { return null; }
1002 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
1003 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
1004 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
1009 * Utility method to constructs a new BroadcastNodeAnnouncement-variant MessageSendEvent
1011 public static MessageSendEvent broadcast_node_announcement(org.ldk.structs.NodeAnnouncement msg) {
1012 long ret = bindings.MessageSendEvent_broadcast_node_announcement(msg == null ? 0 : msg.ptr);
1014 if (ret >= 0 && ret <= 4096) { return null; }
1015 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
1016 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
1017 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
1022 * Utility method to constructs a new SendChannelUpdate-variant MessageSendEvent
1024 public static MessageSendEvent send_channel_update(byte[] node_id, org.ldk.structs.ChannelUpdate msg) {
1025 long ret = bindings.MessageSendEvent_send_channel_update(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
1026 GC.KeepAlive(node_id);
1028 if (ret >= 0 && ret <= 4096) { return null; }
1029 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
1030 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
1031 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
1036 * Utility method to constructs a new HandleError-variant MessageSendEvent
1038 public static MessageSendEvent handle_error(byte[] node_id, org.ldk.structs.ErrorAction action) {
1039 long ret = bindings.MessageSendEvent_handle_error(InternalUtils.check_arr_len(node_id, 33), action.ptr);
1040 GC.KeepAlive(node_id);
1041 GC.KeepAlive(action);
1042 if (ret >= 0 && ret <= 4096) { return null; }
1043 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
1044 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
1045 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(action); };
1050 * Utility method to constructs a new SendChannelRangeQuery-variant MessageSendEvent
1052 public static MessageSendEvent send_channel_range_query(byte[] node_id, org.ldk.structs.QueryChannelRange msg) {
1053 long ret = bindings.MessageSendEvent_send_channel_range_query(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
1054 GC.KeepAlive(node_id);
1056 if (ret >= 0 && ret <= 4096) { return null; }
1057 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
1058 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
1059 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
1064 * Utility method to constructs a new SendShortIdsQuery-variant MessageSendEvent
1066 public static MessageSendEvent send_short_ids_query(byte[] node_id, org.ldk.structs.QueryShortChannelIds msg) {
1067 long ret = bindings.MessageSendEvent_send_short_ids_query(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
1068 GC.KeepAlive(node_id);
1070 if (ret >= 0 && ret <= 4096) { return null; }
1071 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
1072 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
1073 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
1078 * Utility method to constructs a new SendReplyChannelRange-variant MessageSendEvent
1080 public static MessageSendEvent send_reply_channel_range(byte[] node_id, org.ldk.structs.ReplyChannelRange msg) {
1081 long ret = bindings.MessageSendEvent_send_reply_channel_range(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
1082 GC.KeepAlive(node_id);
1084 if (ret >= 0 && ret <= 4096) { return null; }
1085 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
1086 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
1087 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };
1092 * Utility method to constructs a new SendGossipTimestampFilter-variant MessageSendEvent
1094 public static MessageSendEvent send_gossip_timestamp_filter(byte[] node_id, org.ldk.structs.GossipTimestampFilter msg) {
1095 long ret = bindings.MessageSendEvent_send_gossip_timestamp_filter(InternalUtils.check_arr_len(node_id, 33), msg == null ? 0 : msg.ptr);
1096 GC.KeepAlive(node_id);
1098 if (ret >= 0 && ret <= 4096) { return null; }
1099 org.ldk.structs.MessageSendEvent ret_hu_conv = org.ldk.structs.MessageSendEvent.constr_from_ptr(ret);
1100 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
1101 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(msg); };