projects
/
ldk-java
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge pull request #107 from TheBlueMatt/main
[ldk-java]
/
src
/
main
/
java
/
org
/
ldk
/
structs
/
ChannelMonitorUpdate.java
diff --git
a/src/main/java/org/ldk/structs/ChannelMonitorUpdate.java
b/src/main/java/org/ldk/structs/ChannelMonitorUpdate.java
index 4373180aedc6190f2a6e20195122ad80d7d2d15f..d898f862e3f831b2e055abe4d18615a179bd25d3 100644
(file)
--- a/
src/main/java/org/ldk/structs/ChannelMonitorUpdate.java
+++ b/
src/main/java/org/ldk/structs/ChannelMonitorUpdate.java
@@
-4,6
+4,8
@@
import org.ldk.impl.bindings;
import org.ldk.enums.*;
import org.ldk.util.*;
import java.util.Arrays;
import org.ldk.enums.*;
import org.ldk.util.*;
import java.util.Arrays;
+import java.lang.ref.Reference;
+import javax.annotation.Nullable;
/**
/**
@@
-31,11
+33,10
@@
public class ChannelMonitorUpdate extends CommonBase {
* The only instance where update_id values are not strictly increasing is the case where we
* allow post-force-close updates with a special update ID of [`CLOSED_CHANNEL_UPDATE_ID`]. See
* its docs for more details.
* The only instance where update_id values are not strictly increasing is the case where we
* allow post-force-close updates with a special update ID of [`CLOSED_CHANNEL_UPDATE_ID`]. See
* its docs for more details.
- *
- * [`CLOSED_CHANNEL_UPDATE_ID`]: constant.CLOSED_CHANNEL_UPDATE_ID.html
*/
public long get_update_id() {
long ret = bindings.ChannelMonitorUpdate_get_update_id(this.ptr);
*/
public long get_update_id() {
long ret = bindings.ChannelMonitorUpdate_get_update_id(this.ptr);
+ Reference.reachabilityFence(this);
return ret;
}
return ret;
}
@@
-51,11
+52,17
@@
public class ChannelMonitorUpdate extends CommonBase {
* The only instance where update_id values are not strictly increasing is the case where we
* allow post-force-close updates with a special update ID of [`CLOSED_CHANNEL_UPDATE_ID`]. See
* its docs for more details.
* The only instance where update_id values are not strictly increasing is the case where we
* allow post-force-close updates with a special update ID of [`CLOSED_CHANNEL_UPDATE_ID`]. See
* its docs for more details.
- *
- * [`CLOSED_CHANNEL_UPDATE_ID`]: constant.CLOSED_CHANNEL_UPDATE_ID.html
*/
public void set_update_id(long val) {
bindings.ChannelMonitorUpdate_set_update_id(this.ptr, val);
*/
public void set_update_id(long val) {
bindings.ChannelMonitorUpdate_set_update_id(this.ptr, val);
+ Reference.reachabilityFence(this);
+ Reference.reachabilityFence(val);
+ }
+
+ long clone_ptr() {
+ long ret = bindings.ChannelMonitorUpdate_clone_ptr(this.ptr);
+ Reference.reachabilityFence(this);
+ return ret;
}
/**
}
/**
@@
-63,7
+70,9
@@
public class ChannelMonitorUpdate extends CommonBase {
*/
public ChannelMonitorUpdate clone() {
long ret = bindings.ChannelMonitorUpdate_clone(this.ptr);
*/
public ChannelMonitorUpdate clone() {
long ret = bindings.ChannelMonitorUpdate_clone(this.ptr);
- ChannelMonitorUpdate ret_hu_conv = new ChannelMonitorUpdate(null, ret);
+ Reference.reachabilityFence(this);
+ if (ret >= 0 && ret <= 4096) { return null; }
+ org.ldk.structs.ChannelMonitorUpdate ret_hu_conv = null; if (ret < 0 || ret > 4096) { ret_hu_conv = new org.ldk.structs.ChannelMonitorUpdate(null, ret); }
ret_hu_conv.ptrs_to.add(this);
return ret_hu_conv;
}
ret_hu_conv.ptrs_to.add(this);
return ret_hu_conv;
}
@@
-73,14
+82,17
@@
public class ChannelMonitorUpdate extends CommonBase {
*/
public byte[] write() {
byte[] ret = bindings.ChannelMonitorUpdate_write(this.ptr);
*/
public byte[] write() {
byte[] ret = bindings.ChannelMonitorUpdate_write(this.ptr);
+ Reference.reachabilityFence(this);
return ret;
}
/**
* Read a ChannelMonitorUpdate from a byte array, created by ChannelMonitorUpdate_write
*/
return ret;
}
/**
* Read a ChannelMonitorUpdate from a byte array, created by ChannelMonitorUpdate_write
*/
- public static Result_ChannelMonitorUpdateDecodeErrorZ
constructor_
read(byte[] ser) {
+ public static Result_ChannelMonitorUpdateDecodeErrorZ read(byte[] ser) {
long ret = bindings.ChannelMonitorUpdate_read(ser);
long ret = bindings.ChannelMonitorUpdate_read(ser);
+ Reference.reachabilityFence(ser);
+ if (ret >= 0 && ret <= 4096) { return null; }
Result_ChannelMonitorUpdateDecodeErrorZ ret_hu_conv = Result_ChannelMonitorUpdateDecodeErrorZ.constr_from_ptr(ret);
return ret_hu_conv;
}
Result_ChannelMonitorUpdateDecodeErrorZ ret_hu_conv = Result_ChannelMonitorUpdateDecodeErrorZ.constr_from_ptr(ret);
return ret_hu_conv;
}