X-Git-Url: http://git.bitcoin.ninja/index.cgi?p=ldk-java;a=blobdiff_plain;f=c_sharp%2Fsrc%2Forg%2Fldk%2Fstructs%2FTxAbort.cs;h=47f24a72a13534cd4915122707b86343e36df270;hp=24502ba3162fbcf89ab628a645cd6381853a337f;hb=3d1f246d05172683acd3b81836de4e4e9f0c1afd;hpb=a32b8843c44637ebd82c83390d17db573b972153 diff --git a/c_sharp/src/org/ldk/structs/TxAbort.cs b/c_sharp/src/org/ldk/structs/TxAbort.cs index 24502ba3..47f24a72 100644 --- a/c_sharp/src/org/ldk/structs/TxAbort.cs +++ b/c_sharp/src/org/ldk/structs/TxAbort.cs @@ -88,6 +88,18 @@ public class TxAbort : CommonBase { return ret_hu_conv; } + /** + * Generates a non-cryptographic 64-bit hash of the TxAbort. + */ + public long hash() { + long ret = bindings.TxAbort_hash(this.ptr); + GC.KeepAlive(this); + return ret; + } + + public override int GetHashCode() { + return (int)this.hash(); + } /** * Checks if two TxAborts contain equal inner contents. * This ignores pointers and is_owned flags and looks at the values in fields.