Properly set CVec_u8Z to a byte[] which adds a ton more fn's
[ldk-java] / src / main / java / org / ldk / structs / NetworkGraph.java
index f18a9645e548508a98ca0fde0d5960891a9066b6..79647091a5a07f151bd1a60e47f014d1ef9e6464 100644 (file)
@@ -11,7 +11,12 @@ public class NetworkGraph extends CommonBase {
                bindings.NetworkGraph_free(ptr);
        }
 
-       // Skipped NetworkGraph_write
+       public byte[] write(NetworkGraph obj) {
+               byte[] ret = bindings.NetworkGraph_write(obj == null ? 0 : obj.ptr & ~1);
+               this.ptrs_to.add(obj);
+               return ret;
+       }
+
        public NetworkGraph(byte[] ser) {
                super(bindings.NetworkGraph_read(ser));
        }