]> git.bitcoin.ninja Git - ldk-java/blob - ts/structs/ReplyChannelRange.ts
Merge pull request #47 from TheBlueMatt/main
[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, val);
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(chain_hash_arg, 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 ReplyChannelRange clone() {
69                 number ret = bindings.ReplyChannelRange_clone(this.ptr);
70                 const ret_hu_conv: ReplyChannelRange = new ReplyChannelRange(null, ret);
71                 ret_hu_conv.ptrs_to.add(this);
72                 return ret_hu_conv;
73         }
74
75         public static Result_ReplyChannelRangeDecodeErrorZ constructor_read(Uint8Array ser) {
76                 number ret = bindings.ReplyChannelRange_read(ser);
77                 Result_ReplyChannelRangeDecodeErrorZ ret_hu_conv = Result_ReplyChannelRangeDecodeErrorZ.constr_from_ptr(ret);
78                 return ret_hu_conv;
79         }
80
81         public Uint8Array write() {
82                 Uint8Array ret = bindings.ReplyChannelRange_write(this.ptr);
83                 return ret;
84         }
85
86 }