X-Git-Url: http://git.bitcoin.ninja/index.cgi?p=ldk-java;a=blobdiff_plain;f=c_sharp%2Fsrc%2Forg%2Fldk%2Fstructs%2FOnionMessageContents.cs;h=61f863d956850b124652e198ec78d59db51bcec4;hp=8bd84802e170a76e61486fa7636744215f884989;hb=3d1f246d05172683acd3b81836de4e4e9f0c1afd;hpb=a32b8843c44637ebd82c83390d17db573b972153 diff --git a/c_sharp/src/org/ldk/structs/OnionMessageContents.cs b/c_sharp/src/org/ldk/structs/OnionMessageContents.cs index 8bd84802..61f863d9 100644 --- a/c_sharp/src/org/ldk/structs/OnionMessageContents.cs +++ b/c_sharp/src/org/ldk/structs/OnionMessageContents.cs @@ -16,6 +16,9 @@ public interface OnionMessageContentsInterface { /**Serialize the object into a byte array */ byte[] write(); + /**Return a human-readable "debug" string describing this object + */ + string debug_str(); } /** @@ -46,6 +49,12 @@ public class OnionMessageContents : CommonBase { long result = InternalUtils.encodeUint8Array(ret); return result; } + public long debug_str() { + string ret = arg.debug_str(); + GC.KeepAlive(arg); + long result = InternalUtils.encodeString(ret); + return result; + } } /** Creates a new instance of OnionMessageContents from a given implementation */ @@ -80,6 +89,17 @@ public class OnionMessageContents : CommonBase { return ret_conv; } + /** + * Return a human-readable "debug" string describing this object + */ + public string debug_str() { + long ret = bindings.OnionMessageContents_debug_str(this.ptr); + GC.KeepAlive(this); + if (ret >= 0 && ret <= 4096) { return null; } + string ret_conv = InternalUtils.decodeString(ret); + return ret_conv; + } + internal long clone_ptr() { long ret = bindings.OnionMessageContents_clone_ptr(this.ptr); GC.KeepAlive(this);