Update auto-generated bindings
[ldk-java] / ts / structs / ReplyChannelRange.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 ReplyChannelRange 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.ReplyChannelRange_free(this.ptr);
19                     }
20                 }
21         public Uint8Array get_chain_hash() {
22                 Uint8Array ret = bindings.ReplyChannelRange_get_chain_hash(this.ptr);
23                 return ret;
24         }
25
26         public void set_chain_hash(Uint8Array val) {
27                 bindings.ReplyChannelRange_set_chain_hash(this.ptr, InternalUtils.check_arr_len(val, 32));
28         }
29
30         public number get_first_blocknum() {
31                 number ret = bindings.ReplyChannelRange_get_first_blocknum(this.ptr);
32                 return ret;
33         }
34
35         public void set_first_blocknum(number val) {
36                 bindings.ReplyChannelRange_set_first_blocknum(this.ptr, val);
37         }
38
39         public number get_number_of_blocks() {
40                 number ret = bindings.ReplyChannelRange_get_number_of_blocks(this.ptr);
41                 return ret;
42         }
43
44         public void set_number_of_blocks(number val) {
45                 bindings.ReplyChannelRange_set_number_of_blocks(this.ptr, val);
46         }
47
48         public boolean get_sync_complete() {
49                 boolean ret = bindings.ReplyChannelRange_get_sync_complete(this.ptr);
50                 return ret;
51         }
52
53         public void set_sync_complete(boolean val) {
54                 bindings.ReplyChannelRange_set_sync_complete(this.ptr, val);
55         }
56
57         public void set_short_channel_ids(number[] val) {
58                 bindings.ReplyChannelRange_set_short_channel_ids(this.ptr, val);
59         }
60
61         public static ReplyChannelRange constructor_new(Uint8Array chain_hash_arg, number first_blocknum_arg, number number_of_blocks_arg, boolean sync_complete_arg, number[] short_channel_ids_arg) {
62                 number ret = bindings.ReplyChannelRange_new(InternalUtils.check_arr_len(chain_hash_arg, 32), first_blocknum_arg, number_of_blocks_arg, sync_complete_arg, short_channel_ids_arg);
63                 const ret_hu_conv: ReplyChannelRange = new ReplyChannelRange(null, ret);
64                 ret_hu_conv.ptrs_to.add(ret_hu_conv);
65                 return ret_hu_conv;
66         }
67
68         public number clone_ptr() {
69                 number ret = bindings.ReplyChannelRange_clone_ptr(this.ptr);
70                 return ret;
71         }
72
73         public ReplyChannelRange clone() {
74                 number ret = bindings.ReplyChannelRange_clone(this.ptr);
75                 const ret_hu_conv: ReplyChannelRange = new ReplyChannelRange(null, ret);
76                 ret_hu_conv.ptrs_to.add(this);
77                 return ret_hu_conv;
78         }
79
80         public static Result_ReplyChannelRangeDecodeErrorZ constructor_read(Uint8Array ser) {
81                 number ret = bindings.ReplyChannelRange_read(ser);
82                 Result_ReplyChannelRangeDecodeErrorZ ret_hu_conv = Result_ReplyChannelRangeDecodeErrorZ.constr_from_ptr(ret);
83                 return ret_hu_conv;
84         }
85
86         public Uint8Array write() {
87                 Uint8Array ret = bindings.ReplyChannelRange_write(this.ptr);
88                 return ret;
89         }
90
91 }