/**
* Creates a new CResult_PaymentPreimageAPIErrorZ in the error state.
*/
- public static Result_PaymentPreimageAPIErrorZ err(APIError e) {
+ public static Result_PaymentPreimageAPIErrorZ err(org.ldk.structs.APIError e) {
long ret = bindings.CResult_PaymentPreimageAPIErrorZ_err(e.ptr);
Reference.reachabilityFence(e);
if (ret >= 0 && ret <= 4096) { return null; }
Result_PaymentPreimageAPIErrorZ ret_hu_conv = Result_PaymentPreimageAPIErrorZ.constr_from_ptr(ret);
+ if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(e); };
return ret_hu_conv;
}