]> git.bitcoin.ninja Git - ldk-java/blob - ts/structs/CommitmentSigned.ts
Update auto-generated bindings
[ldk-java] / ts / structs / CommitmentSigned.ts
1
2             
3 import CommonBase from './CommonBase';
4 import * as bindings from '../bindings' // TODO: figure out location
5
6
7
8             export default class CommitmentSigned extends CommonBase {
9                 constructor(_dummy: object, ptr: number) {
10                     super(ptr);
11                 }
12
13                 
14                 protected finalize() {
15                     super.finalize();
16
17                     if (this.ptr != 0) {
18                         bindings.CommitmentSigned_free(this.ptr);
19                     }
20                 }
21         public Uint8Array get_channel_id() {
22                 Uint8Array ret = bindings.CommitmentSigned_get_channel_id(this.ptr);
23                 return ret;
24         }
25
26         public void set_channel_id(Uint8Array val) {
27                 bindings.CommitmentSigned_set_channel_id(this.ptr, val);
28         }
29
30         public Uint8Array get_signature() {
31                 Uint8Array ret = bindings.CommitmentSigned_get_signature(this.ptr);
32                 return ret;
33         }
34
35         public void set_signature(Uint8Array val) {
36                 bindings.CommitmentSigned_set_signature(this.ptr, val);
37         }
38
39         public void set_htlc_signatures(Uint8Array[] val) {
40                 bindings.CommitmentSigned_set_htlc_signatures(this.ptr, val);
41         }
42
43         public static CommitmentSigned constructor_new(Uint8Array channel_id_arg, Uint8Array signature_arg, Uint8Array[] htlc_signatures_arg) {
44                 number ret = bindings.CommitmentSigned_new(channel_id_arg, signature_arg, htlc_signatures_arg);
45                 const ret_hu_conv: CommitmentSigned = new CommitmentSigned(null, ret);
46                 ret_hu_conv.ptrs_to.add(ret_hu_conv);
47                 return ret_hu_conv;
48         }
49
50         public CommitmentSigned clone() {
51                 number ret = bindings.CommitmentSigned_clone(this.ptr);
52                 const ret_hu_conv: CommitmentSigned = new CommitmentSigned(null, ret);
53                 ret_hu_conv.ptrs_to.add(this);
54                 return ret_hu_conv;
55         }
56
57         public Uint8Array write() {
58                 Uint8Array ret = bindings.CommitmentSigned_write(this.ptr);
59                 return ret;
60         }
61
62         public static Result_CommitmentSignedDecodeErrorZ constructor_read(Uint8Array ser) {
63                 number ret = bindings.CommitmentSigned_read(ser);
64                 Result_CommitmentSignedDecodeErrorZ ret_hu_conv = Result_CommitmentSignedDecodeErrorZ.constr_from_ptr(ret);
65                 return ret_hu_conv;
66         }
67
68 }