X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=ts%2Fstructs%2FNodeFeatures.ts;h=d65e11e3f445eac9e5a34117eb60a940f1421d60;hb=7d6be8a5ef72a4ebfe07660cce55f43f6cc30b80;hp=d091079f895c994131b7457427ed1c2e2ee713c0;hpb=acecce750cf1159a51f9d1a4dbfd717520739e92;p=ldk-java diff --git a/ts/structs/NodeFeatures.ts b/ts/structs/NodeFeatures.ts index d091079f..d65e11e3 100644 --- a/ts/structs/NodeFeatures.ts +++ b/ts/structs/NodeFeatures.ts @@ -18,4 +18,52 @@ import * as bindings from '../bindings' // TODO: figure out location bindings.NodeFeatures_free(this.ptr); } } + public boolean eq(NodeFeatures b) { + boolean ret = bindings.NodeFeatures_eq(this.ptr, b == null ? 0 : b.ptr & ~1); + this.ptrs_to.add(b); + return ret; + } + + public NodeFeatures clone() { + number ret = bindings.NodeFeatures_clone(this.ptr); + const ret_hu_conv: NodeFeatures = new NodeFeatures(null, ret); + ret_hu_conv.ptrs_to.add(this); + return ret_hu_conv; + } + + public static NodeFeatures constructor_empty() { + number ret = bindings.NodeFeatures_empty(); + const ret_hu_conv: NodeFeatures = new NodeFeatures(null, ret); + ret_hu_conv.ptrs_to.add(ret_hu_conv); + return ret_hu_conv; + } + + public static NodeFeatures constructor_known() { + number ret = bindings.NodeFeatures_known(); + const ret_hu_conv: NodeFeatures = new NodeFeatures(null, ret); + ret_hu_conv.ptrs_to.add(ret_hu_conv); + return ret_hu_conv; + } + + public boolean requires_unknown_bits() { + boolean ret = bindings.NodeFeatures_requires_unknown_bits(this.ptr); + return ret; + } + + public boolean supports_payment_secret() { + boolean ret = bindings.NodeFeatures_supports_payment_secret(this.ptr); + return ret; + } + + public Uint8Array write() { + Uint8Array ret = bindings.NodeFeatures_write(this.ptr); + return ret; + } + + public static Result_NodeFeaturesDecodeErrorZ constructor_read(Uint8Array ser) { + number ret = bindings.NodeFeatures_read(ser); + Result_NodeFeaturesDecodeErrorZ ret_hu_conv = Result_NodeFeaturesDecodeErrorZ.constr_from_ptr(ret); + return ret_hu_conv; + } + }