]> git.bitcoin.ninja Git - ldk-java/blob - ts/structs/Result_TxOutAccessErrorZ.ts
Remove commented-out code
[ldk-java] / ts / structs / Result_TxOutAccessErrorZ.ts
1
2 import CommonBase from './CommonBase';
3 import * as bindings from '../bindings' // TODO: figure out location
4
5 public class Result_TxOutAccessErrorZ extends CommonBase {
6         private Result_TxOutAccessErrorZ(Object _dummy, long ptr) { super(ptr); }
7         protected void finalize() throws Throwable {
8                 if (ptr != 0) { bindings.CResult_TxOutAccessErrorZ_free(ptr); } super.finalize();
9         }
10
11         static Result_TxOutAccessErrorZ constr_from_ptr(long ptr) {
12                 if (bindings.LDKCResult_TxOutAccessErrorZ_result_ok(ptr)) {
13                         return new Result_TxOutAccessErrorZ_OK(null, ptr);
14                 } else {
15                         return new Result_TxOutAccessErrorZ_Err(null, ptr);
16                 }
17         }
18         public static final class Result_TxOutAccessErrorZ_OK extends Result_TxOutAccessErrorZ {
19                 public final TxOut res;
20                 private Result_TxOutAccessErrorZ_OK(Object _dummy, long ptr) {
21                         super(_dummy, ptr);
22                         uint32_t res = bindings.LDKCResult_TxOutAccessErrorZ_get_ok(ptr);
23                         TxOut res_conv = new TxOut(null, res);
24                         this.res = res_conv;
25                 }
26                 public Result_TxOutAccessErrorZ_OK(TxOut res) {
27                         this(null, bindings.CResult_TxOutAccessErrorZ_ok(res.ptr));
28                 }
29         }
30
31         public static final class Result_TxOutAccessErrorZ_Err extends Result_TxOutAccessErrorZ {
32                 public final LDKAccessError err;
33                 private Result_TxOutAccessErrorZ_Err(Object _dummy, long ptr) {
34                         super(_dummy, ptr);
35                         this.err = bindings.LDKCResult_TxOutAccessErrorZ_get_err(ptr);
36                 }
37                 public Result_TxOutAccessErrorZ_Err(LDKAccessError err) {
38                         this(null, bindings.CResult_TxOutAccessErrorZ_err(err));
39                 }
40         }
41 }