1 package org.ldk.structs;
3 import org.ldk.impl.bindings;
4 import org.ldk.enums.*;
6 import java.util.Arrays;
8 @SuppressWarnings("unchecked") // We correctly assign various generic arrays
9 public class AcceptChannel extends CommonBase {
10 AcceptChannel(Object _dummy, long ptr) { super(ptr); }
11 @Override @SuppressWarnings("deprecation")
12 protected void finalize() throws Throwable {
14 if (ptr != 0) { bindings.AcceptChannel_free(ptr); }
17 public static AcceptChannel constructor_clone(AcceptChannel orig) {
18 long ret = bindings.AcceptChannel_clone(orig == null ? 0 : orig.ptr & ~1);
19 AcceptChannel ret_hu_conv = new AcceptChannel(null, ret);
20 ret_hu_conv.ptrs_to.add(orig);
24 public byte[] get_temporary_channel_id() {
25 byte[] ret = bindings.AcceptChannel_get_temporary_channel_id(this.ptr);
29 public void set_temporary_channel_id(byte[] val) {
30 bindings.AcceptChannel_set_temporary_channel_id(this.ptr, val);
33 public long get_dust_limit_satoshis() {
34 long ret = bindings.AcceptChannel_get_dust_limit_satoshis(this.ptr);
38 public void set_dust_limit_satoshis(long val) {
39 bindings.AcceptChannel_set_dust_limit_satoshis(this.ptr, val);
42 public long get_max_htlc_value_in_flight_msat() {
43 long ret = bindings.AcceptChannel_get_max_htlc_value_in_flight_msat(this.ptr);
47 public void set_max_htlc_value_in_flight_msat(long val) {
48 bindings.AcceptChannel_set_max_htlc_value_in_flight_msat(this.ptr, val);
51 public long get_channel_reserve_satoshis() {
52 long ret = bindings.AcceptChannel_get_channel_reserve_satoshis(this.ptr);
56 public void set_channel_reserve_satoshis(long val) {
57 bindings.AcceptChannel_set_channel_reserve_satoshis(this.ptr, val);
60 public long get_htlc_minimum_msat() {
61 long ret = bindings.AcceptChannel_get_htlc_minimum_msat(this.ptr);
65 public void set_htlc_minimum_msat(long val) {
66 bindings.AcceptChannel_set_htlc_minimum_msat(this.ptr, val);
69 public int get_minimum_depth() {
70 int ret = bindings.AcceptChannel_get_minimum_depth(this.ptr);
74 public void set_minimum_depth(int val) {
75 bindings.AcceptChannel_set_minimum_depth(this.ptr, val);
78 public short get_to_self_delay() {
79 short ret = bindings.AcceptChannel_get_to_self_delay(this.ptr);
83 public void set_to_self_delay(short val) {
84 bindings.AcceptChannel_set_to_self_delay(this.ptr, val);
87 public short get_max_accepted_htlcs() {
88 short ret = bindings.AcceptChannel_get_max_accepted_htlcs(this.ptr);
92 public void set_max_accepted_htlcs(short val) {
93 bindings.AcceptChannel_set_max_accepted_htlcs(this.ptr, val);
96 public byte[] get_funding_pubkey() {
97 byte[] ret = bindings.AcceptChannel_get_funding_pubkey(this.ptr);
101 public void set_funding_pubkey(byte[] val) {
102 bindings.AcceptChannel_set_funding_pubkey(this.ptr, val);
105 public byte[] get_revocation_basepoint() {
106 byte[] ret = bindings.AcceptChannel_get_revocation_basepoint(this.ptr);
110 public void set_revocation_basepoint(byte[] val) {
111 bindings.AcceptChannel_set_revocation_basepoint(this.ptr, val);
114 public byte[] get_payment_point() {
115 byte[] ret = bindings.AcceptChannel_get_payment_point(this.ptr);
119 public void set_payment_point(byte[] val) {
120 bindings.AcceptChannel_set_payment_point(this.ptr, val);
123 public byte[] get_delayed_payment_basepoint() {
124 byte[] ret = bindings.AcceptChannel_get_delayed_payment_basepoint(this.ptr);
128 public void set_delayed_payment_basepoint(byte[] val) {
129 bindings.AcceptChannel_set_delayed_payment_basepoint(this.ptr, val);
132 public byte[] get_htlc_basepoint() {
133 byte[] ret = bindings.AcceptChannel_get_htlc_basepoint(this.ptr);
137 public void set_htlc_basepoint(byte[] val) {
138 bindings.AcceptChannel_set_htlc_basepoint(this.ptr, val);
141 public byte[] get_first_per_commitment_point() {
142 byte[] ret = bindings.AcceptChannel_get_first_per_commitment_point(this.ptr);
146 public void set_first_per_commitment_point(byte[] val) {
147 bindings.AcceptChannel_set_first_per_commitment_point(this.ptr, val);
150 public byte[] write(AcceptChannel obj) {
151 byte[] ret = bindings.AcceptChannel_write(obj == null ? 0 : obj.ptr & ~1);
152 this.ptrs_to.add(obj);
156 public static AcceptChannel constructor_read(byte[] ser) {
157 long ret = bindings.AcceptChannel_read(ser);
158 AcceptChannel ret_hu_conv = new AcceptChannel(null, ret);