- static { LDKFallback.init(); }
- public static native LDKFallback LDKFallback_ref_from_ptr(long ptr);
- // struct LDKStr _ldk_get_compiled_version(void);
- public static native String _ldk_get_compiled_version();
- // struct LDKStr _ldk_c_bindings_get_compiled_version(void);
- public static native String _ldk_c_bindings_get_compiled_version();
- // struct LDKSixteenBytes U128_le_bytes(struct LDKU128 val);
- public static native byte[] U128_le_bytes(byte[] val);
- // struct LDKU128 U128_new(struct LDKSixteenBytes le_bytes);
- public static native byte[] U128_new(byte[] le_bytes);
- // struct LDKBigEndianScalar BigEndianScalar_new(struct LDKThirtyTwoBytes big_endian_bytes);
- public static native long BigEndianScalar_new(byte[] big_endian_bytes);
- // uint64_t Bech32Error_clone_ptr(LDKBech32Error *NONNULL_PTR arg);
- public static native long Bech32Error_clone_ptr(long arg);
- // struct LDKBech32Error Bech32Error_clone(const struct LDKBech32Error *NONNULL_PTR orig);
- public static native long Bech32Error_clone(long orig);
- // void Bech32Error_free(struct LDKBech32Error o);
- public static native void Bech32Error_free(long o);
- // void Transaction_free(struct LDKTransaction _res);
- public static native void Transaction_free(byte[] _res);
- // void Witness_free(struct LDKWitness _res);
- public static native void Witness_free(byte[] _res);
- // struct LDKTxOut TxOut_new(struct LDKCVec_u8Z script_pubkey, uint64_t value);
- public static native long TxOut_new(byte[] script_pubkey, long value);
- // void TxOut_free(struct LDKTxOut _res);
- public static native void TxOut_free(long _res);
- // uint64_t TxOut_clone_ptr(LDKTxOut *NONNULL_PTR arg);
- public static native long TxOut_clone_ptr(long arg);
- // struct LDKTxOut TxOut_clone(const struct LDKTxOut *NONNULL_PTR orig);
- public static native long TxOut_clone(long orig);
- // void Str_free(struct LDKStr _res);
- public static native void Str_free(String _res);
- // struct LDKCOption_DurationZ COption_DurationZ_some(uint64_t o);
- public static native long COption_DurationZ_some(long o);
- // struct LDKCOption_DurationZ COption_DurationZ_none(void);
- public static native long COption_DurationZ_none();
- // void COption_DurationZ_free(struct LDKCOption_DurationZ _res);
- public static native void COption_DurationZ_free(long _res);
- // uint64_t COption_DurationZ_clone_ptr(LDKCOption_DurationZ *NONNULL_PTR arg);
- public static native long COption_DurationZ_clone_ptr(long arg);
- // struct LDKCOption_DurationZ COption_DurationZ_clone(const struct LDKCOption_DurationZ *NONNULL_PTR orig);
- public static native long COption_DurationZ_clone(long orig);
- // void CVec_BlindedPathZ_free(struct LDKCVec_BlindedPathZ _res);
- public static native void CVec_BlindedPathZ_free(long[] _res);
- // struct LDKCOption_u64Z COption_u64Z_some(uint64_t o);
- public static native long COption_u64Z_some(long o);
- // struct LDKCOption_u64Z COption_u64Z_none(void);
- public static native long COption_u64Z_none();
- // void COption_u64Z_free(struct LDKCOption_u64Z _res);
- public static native void COption_u64Z_free(long _res);
- // uint64_t COption_u64Z_clone_ptr(LDKCOption_u64Z *NONNULL_PTR arg);
- public static native long COption_u64Z_clone_ptr(long arg);
- // struct LDKCOption_u64Z COption_u64Z_clone(const struct LDKCOption_u64Z *NONNULL_PTR orig);
- public static native long COption_u64Z_clone(long orig);
- // struct LDKCResult_NoneAPIErrorZ CResult_NoneAPIErrorZ_ok(void);
- public static native long CResult_NoneAPIErrorZ_ok();
- // struct LDKCResult_NoneAPIErrorZ CResult_NoneAPIErrorZ_err(struct LDKAPIError e);
- public static native long CResult_NoneAPIErrorZ_err(long e);
- // bool CResult_NoneAPIErrorZ_is_ok(const struct LDKCResult_NoneAPIErrorZ *NONNULL_PTR o);
- public static native boolean CResult_NoneAPIErrorZ_is_ok(long o);
- // void CResult_NoneAPIErrorZ_free(struct LDKCResult_NoneAPIErrorZ _res);
- public static native void CResult_NoneAPIErrorZ_free(long _res);
- // uint64_t CResult_NoneAPIErrorZ_clone_ptr(LDKCResult_NoneAPIErrorZ *NONNULL_PTR arg);
- public static native long CResult_NoneAPIErrorZ_clone_ptr(long arg);
- // struct LDKCResult_NoneAPIErrorZ CResult_NoneAPIErrorZ_clone(const struct LDKCResult_NoneAPIErrorZ *NONNULL_PTR orig);
- public static native long CResult_NoneAPIErrorZ_clone(long orig);
- // void CVec_CResult_NoneAPIErrorZZ_free(struct LDKCVec_CResult_NoneAPIErrorZZ _res);
- public static native void CVec_CResult_NoneAPIErrorZZ_free(long[] _res);
- // void CVec_APIErrorZ_free(struct LDKCVec_APIErrorZ _res);
- public static native void CVec_APIErrorZ_free(long[] _res);
- // void CVec_u8Z_free(struct LDKCVec_u8Z _res);
- public static native void CVec_u8Z_free(byte[] _res);
- // struct LDKCOption_CVec_u8ZZ COption_CVec_u8ZZ_some(struct LDKCVec_u8Z o);
- public static native long COption_CVec_u8ZZ_some(byte[] o);
- // struct LDKCOption_CVec_u8ZZ COption_CVec_u8ZZ_none(void);
- public static native long COption_CVec_u8ZZ_none();
- // void COption_CVec_u8ZZ_free(struct LDKCOption_CVec_u8ZZ _res);
- public static native void COption_CVec_u8ZZ_free(long _res);
- // uint64_t COption_CVec_u8ZZ_clone_ptr(LDKCOption_CVec_u8ZZ *NONNULL_PTR arg);
- public static native long COption_CVec_u8ZZ_clone_ptr(long arg);
- // struct LDKCOption_CVec_u8ZZ COption_CVec_u8ZZ_clone(const struct LDKCOption_CVec_u8ZZ *NONNULL_PTR orig);
- public static native long COption_CVec_u8ZZ_clone(long orig);
- // struct LDKCResult_RecipientOnionFieldsDecodeErrorZ CResult_RecipientOnionFieldsDecodeErrorZ_ok(struct LDKRecipientOnionFields o);
- public static native long CResult_RecipientOnionFieldsDecodeErrorZ_ok(long o);
- // struct LDKCResult_RecipientOnionFieldsDecodeErrorZ CResult_RecipientOnionFieldsDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_RecipientOnionFieldsDecodeErrorZ_err(long e);
- // bool CResult_RecipientOnionFieldsDecodeErrorZ_is_ok(const struct LDKCResult_RecipientOnionFieldsDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_RecipientOnionFieldsDecodeErrorZ_is_ok(long o);
- // void CResult_RecipientOnionFieldsDecodeErrorZ_free(struct LDKCResult_RecipientOnionFieldsDecodeErrorZ _res);
- public static native void CResult_RecipientOnionFieldsDecodeErrorZ_free(long _res);
- // uint64_t CResult_RecipientOnionFieldsDecodeErrorZ_clone_ptr(LDKCResult_RecipientOnionFieldsDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_RecipientOnionFieldsDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_RecipientOnionFieldsDecodeErrorZ CResult_RecipientOnionFieldsDecodeErrorZ_clone(const struct LDKCResult_RecipientOnionFieldsDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_RecipientOnionFieldsDecodeErrorZ_clone(long orig);
- // struct LDKCOption_HTLCClaimZ COption_HTLCClaimZ_some(enum LDKHTLCClaim o);
- public static native long COption_HTLCClaimZ_some(HTLCClaim o);
- // struct LDKCOption_HTLCClaimZ COption_HTLCClaimZ_none(void);
- public static native long COption_HTLCClaimZ_none();
- // void COption_HTLCClaimZ_free(struct LDKCOption_HTLCClaimZ _res);
- public static native void COption_HTLCClaimZ_free(long _res);
- // struct LDKCResult_NoneNoneZ CResult_NoneNoneZ_ok(void);
- public static native long CResult_NoneNoneZ_ok();
- // struct LDKCResult_NoneNoneZ CResult_NoneNoneZ_err(void);
- public static native long CResult_NoneNoneZ_err();
- // bool CResult_NoneNoneZ_is_ok(const struct LDKCResult_NoneNoneZ *NONNULL_PTR o);
- public static native boolean CResult_NoneNoneZ_is_ok(long o);
- // void CResult_NoneNoneZ_free(struct LDKCResult_NoneNoneZ _res);
- public static native void CResult_NoneNoneZ_free(long _res);
- // uint64_t CResult_NoneNoneZ_clone_ptr(LDKCResult_NoneNoneZ *NONNULL_PTR arg);
- public static native long CResult_NoneNoneZ_clone_ptr(long arg);
- // struct LDKCResult_NoneNoneZ CResult_NoneNoneZ_clone(const struct LDKCResult_NoneNoneZ *NONNULL_PTR orig);
- public static native long CResult_NoneNoneZ_clone(long orig);
- // struct LDKCResult_CounterpartyCommitmentSecretsDecodeErrorZ CResult_CounterpartyCommitmentSecretsDecodeErrorZ_ok(struct LDKCounterpartyCommitmentSecrets o);
- public static native long CResult_CounterpartyCommitmentSecretsDecodeErrorZ_ok(long o);
- // struct LDKCResult_CounterpartyCommitmentSecretsDecodeErrorZ CResult_CounterpartyCommitmentSecretsDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_CounterpartyCommitmentSecretsDecodeErrorZ_err(long e);
- // bool CResult_CounterpartyCommitmentSecretsDecodeErrorZ_is_ok(const struct LDKCResult_CounterpartyCommitmentSecretsDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_CounterpartyCommitmentSecretsDecodeErrorZ_is_ok(long o);
- // void CResult_CounterpartyCommitmentSecretsDecodeErrorZ_free(struct LDKCResult_CounterpartyCommitmentSecretsDecodeErrorZ _res);
- public static native void CResult_CounterpartyCommitmentSecretsDecodeErrorZ_free(long _res);
- // uint64_t CResult_CounterpartyCommitmentSecretsDecodeErrorZ_clone_ptr(LDKCResult_CounterpartyCommitmentSecretsDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_CounterpartyCommitmentSecretsDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_CounterpartyCommitmentSecretsDecodeErrorZ CResult_CounterpartyCommitmentSecretsDecodeErrorZ_clone(const struct LDKCResult_CounterpartyCommitmentSecretsDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_CounterpartyCommitmentSecretsDecodeErrorZ_clone(long orig);
- // struct LDKCResult_TxCreationKeysDecodeErrorZ CResult_TxCreationKeysDecodeErrorZ_ok(struct LDKTxCreationKeys o);
- public static native long CResult_TxCreationKeysDecodeErrorZ_ok(long o);
- // struct LDKCResult_TxCreationKeysDecodeErrorZ CResult_TxCreationKeysDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_TxCreationKeysDecodeErrorZ_err(long e);
- // bool CResult_TxCreationKeysDecodeErrorZ_is_ok(const struct LDKCResult_TxCreationKeysDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_TxCreationKeysDecodeErrorZ_is_ok(long o);
- // void CResult_TxCreationKeysDecodeErrorZ_free(struct LDKCResult_TxCreationKeysDecodeErrorZ _res);
- public static native void CResult_TxCreationKeysDecodeErrorZ_free(long _res);
- // uint64_t CResult_TxCreationKeysDecodeErrorZ_clone_ptr(LDKCResult_TxCreationKeysDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_TxCreationKeysDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_TxCreationKeysDecodeErrorZ CResult_TxCreationKeysDecodeErrorZ_clone(const struct LDKCResult_TxCreationKeysDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_TxCreationKeysDecodeErrorZ_clone(long orig);
- // struct LDKCResult_ChannelPublicKeysDecodeErrorZ CResult_ChannelPublicKeysDecodeErrorZ_ok(struct LDKChannelPublicKeys o);
- public static native long CResult_ChannelPublicKeysDecodeErrorZ_ok(long o);
- // struct LDKCResult_ChannelPublicKeysDecodeErrorZ CResult_ChannelPublicKeysDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_ChannelPublicKeysDecodeErrorZ_err(long e);
- // bool CResult_ChannelPublicKeysDecodeErrorZ_is_ok(const struct LDKCResult_ChannelPublicKeysDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_ChannelPublicKeysDecodeErrorZ_is_ok(long o);
- // void CResult_ChannelPublicKeysDecodeErrorZ_free(struct LDKCResult_ChannelPublicKeysDecodeErrorZ _res);
- public static native void CResult_ChannelPublicKeysDecodeErrorZ_free(long _res);
- // uint64_t CResult_ChannelPublicKeysDecodeErrorZ_clone_ptr(LDKCResult_ChannelPublicKeysDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_ChannelPublicKeysDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_ChannelPublicKeysDecodeErrorZ CResult_ChannelPublicKeysDecodeErrorZ_clone(const struct LDKCResult_ChannelPublicKeysDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_ChannelPublicKeysDecodeErrorZ_clone(long orig);
- // struct LDKCOption_u32Z COption_u32Z_some(uint32_t o);
- public static native long COption_u32Z_some(int o);
- // struct LDKCOption_u32Z COption_u32Z_none(void);
- public static native long COption_u32Z_none();
- // void COption_u32Z_free(struct LDKCOption_u32Z _res);
- public static native void COption_u32Z_free(long _res);
- // uint64_t COption_u32Z_clone_ptr(LDKCOption_u32Z *NONNULL_PTR arg);
- public static native long COption_u32Z_clone_ptr(long arg);
- // struct LDKCOption_u32Z COption_u32Z_clone(const struct LDKCOption_u32Z *NONNULL_PTR orig);
- public static native long COption_u32Z_clone(long orig);
- // struct LDKCResult_HTLCOutputInCommitmentDecodeErrorZ CResult_HTLCOutputInCommitmentDecodeErrorZ_ok(struct LDKHTLCOutputInCommitment o);
- public static native long CResult_HTLCOutputInCommitmentDecodeErrorZ_ok(long o);
- // struct LDKCResult_HTLCOutputInCommitmentDecodeErrorZ CResult_HTLCOutputInCommitmentDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_HTLCOutputInCommitmentDecodeErrorZ_err(long e);
- // bool CResult_HTLCOutputInCommitmentDecodeErrorZ_is_ok(const struct LDKCResult_HTLCOutputInCommitmentDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_HTLCOutputInCommitmentDecodeErrorZ_is_ok(long o);
- // void CResult_HTLCOutputInCommitmentDecodeErrorZ_free(struct LDKCResult_HTLCOutputInCommitmentDecodeErrorZ _res);
- public static native void CResult_HTLCOutputInCommitmentDecodeErrorZ_free(long _res);
- // uint64_t CResult_HTLCOutputInCommitmentDecodeErrorZ_clone_ptr(LDKCResult_HTLCOutputInCommitmentDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_HTLCOutputInCommitmentDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_HTLCOutputInCommitmentDecodeErrorZ CResult_HTLCOutputInCommitmentDecodeErrorZ_clone(const struct LDKCResult_HTLCOutputInCommitmentDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_HTLCOutputInCommitmentDecodeErrorZ_clone(long orig);
- // enum LDKCOption_NoneZ COption_NoneZ_some(void);
- public static native COption_NoneZ COption_NoneZ_some();
- // enum LDKCOption_NoneZ COption_NoneZ_none(void);
- public static native COption_NoneZ COption_NoneZ_none();
- // void COption_NoneZ_free(enum LDKCOption_NoneZ _res);
- public static native void COption_NoneZ_free(COption_NoneZ _res);
- // struct LDKCResult_CounterpartyChannelTransactionParametersDecodeErrorZ CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_ok(struct LDKCounterpartyChannelTransactionParameters o);
- public static native long CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_ok(long o);
- // struct LDKCResult_CounterpartyChannelTransactionParametersDecodeErrorZ CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_err(long e);
- // bool CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_is_ok(const struct LDKCResult_CounterpartyChannelTransactionParametersDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_is_ok(long o);
- // void CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_free(struct LDKCResult_CounterpartyChannelTransactionParametersDecodeErrorZ _res);
- public static native void CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_free(long _res);
- // uint64_t CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_clone_ptr(LDKCResult_CounterpartyChannelTransactionParametersDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_CounterpartyChannelTransactionParametersDecodeErrorZ CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_clone(const struct LDKCResult_CounterpartyChannelTransactionParametersDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_CounterpartyChannelTransactionParametersDecodeErrorZ_clone(long orig);
- // struct LDKCResult_ChannelTransactionParametersDecodeErrorZ CResult_ChannelTransactionParametersDecodeErrorZ_ok(struct LDKChannelTransactionParameters o);
- public static native long CResult_ChannelTransactionParametersDecodeErrorZ_ok(long o);
- // struct LDKCResult_ChannelTransactionParametersDecodeErrorZ CResult_ChannelTransactionParametersDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_ChannelTransactionParametersDecodeErrorZ_err(long e);
- // bool CResult_ChannelTransactionParametersDecodeErrorZ_is_ok(const struct LDKCResult_ChannelTransactionParametersDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_ChannelTransactionParametersDecodeErrorZ_is_ok(long o);
- // void CResult_ChannelTransactionParametersDecodeErrorZ_free(struct LDKCResult_ChannelTransactionParametersDecodeErrorZ _res);
- public static native void CResult_ChannelTransactionParametersDecodeErrorZ_free(long _res);
- // uint64_t CResult_ChannelTransactionParametersDecodeErrorZ_clone_ptr(LDKCResult_ChannelTransactionParametersDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_ChannelTransactionParametersDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_ChannelTransactionParametersDecodeErrorZ CResult_ChannelTransactionParametersDecodeErrorZ_clone(const struct LDKCResult_ChannelTransactionParametersDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_ChannelTransactionParametersDecodeErrorZ_clone(long orig);
- // void CVec_SignatureZ_free(struct LDKCVec_SignatureZ _res);
- public static native void CVec_SignatureZ_free(byte[][] _res);
- // struct LDKCResult_HolderCommitmentTransactionDecodeErrorZ CResult_HolderCommitmentTransactionDecodeErrorZ_ok(struct LDKHolderCommitmentTransaction o);
- public static native long CResult_HolderCommitmentTransactionDecodeErrorZ_ok(long o);
- // struct LDKCResult_HolderCommitmentTransactionDecodeErrorZ CResult_HolderCommitmentTransactionDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_HolderCommitmentTransactionDecodeErrorZ_err(long e);
- // bool CResult_HolderCommitmentTransactionDecodeErrorZ_is_ok(const struct LDKCResult_HolderCommitmentTransactionDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_HolderCommitmentTransactionDecodeErrorZ_is_ok(long o);
- // void CResult_HolderCommitmentTransactionDecodeErrorZ_free(struct LDKCResult_HolderCommitmentTransactionDecodeErrorZ _res);
- public static native void CResult_HolderCommitmentTransactionDecodeErrorZ_free(long _res);
- // uint64_t CResult_HolderCommitmentTransactionDecodeErrorZ_clone_ptr(LDKCResult_HolderCommitmentTransactionDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_HolderCommitmentTransactionDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_HolderCommitmentTransactionDecodeErrorZ CResult_HolderCommitmentTransactionDecodeErrorZ_clone(const struct LDKCResult_HolderCommitmentTransactionDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_HolderCommitmentTransactionDecodeErrorZ_clone(long orig);
- // struct LDKCResult_BuiltCommitmentTransactionDecodeErrorZ CResult_BuiltCommitmentTransactionDecodeErrorZ_ok(struct LDKBuiltCommitmentTransaction o);
- public static native long CResult_BuiltCommitmentTransactionDecodeErrorZ_ok(long o);
- // struct LDKCResult_BuiltCommitmentTransactionDecodeErrorZ CResult_BuiltCommitmentTransactionDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_BuiltCommitmentTransactionDecodeErrorZ_err(long e);
- // bool CResult_BuiltCommitmentTransactionDecodeErrorZ_is_ok(const struct LDKCResult_BuiltCommitmentTransactionDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_BuiltCommitmentTransactionDecodeErrorZ_is_ok(long o);
- // void CResult_BuiltCommitmentTransactionDecodeErrorZ_free(struct LDKCResult_BuiltCommitmentTransactionDecodeErrorZ _res);
- public static native void CResult_BuiltCommitmentTransactionDecodeErrorZ_free(long _res);
- // uint64_t CResult_BuiltCommitmentTransactionDecodeErrorZ_clone_ptr(LDKCResult_BuiltCommitmentTransactionDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_BuiltCommitmentTransactionDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_BuiltCommitmentTransactionDecodeErrorZ CResult_BuiltCommitmentTransactionDecodeErrorZ_clone(const struct LDKCResult_BuiltCommitmentTransactionDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_BuiltCommitmentTransactionDecodeErrorZ_clone(long orig);
- // struct LDKCResult_TrustedClosingTransactionNoneZ CResult_TrustedClosingTransactionNoneZ_ok(struct LDKTrustedClosingTransaction o);
- public static native long CResult_TrustedClosingTransactionNoneZ_ok(long o);
- // struct LDKCResult_TrustedClosingTransactionNoneZ CResult_TrustedClosingTransactionNoneZ_err(void);
- public static native long CResult_TrustedClosingTransactionNoneZ_err();
- // bool CResult_TrustedClosingTransactionNoneZ_is_ok(const struct LDKCResult_TrustedClosingTransactionNoneZ *NONNULL_PTR o);
- public static native boolean CResult_TrustedClosingTransactionNoneZ_is_ok(long o);
- // void CResult_TrustedClosingTransactionNoneZ_free(struct LDKCResult_TrustedClosingTransactionNoneZ _res);
- public static native void CResult_TrustedClosingTransactionNoneZ_free(long _res);
- // struct LDKCResult_CommitmentTransactionDecodeErrorZ CResult_CommitmentTransactionDecodeErrorZ_ok(struct LDKCommitmentTransaction o);
- public static native long CResult_CommitmentTransactionDecodeErrorZ_ok(long o);
- // struct LDKCResult_CommitmentTransactionDecodeErrorZ CResult_CommitmentTransactionDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_CommitmentTransactionDecodeErrorZ_err(long e);
- // bool CResult_CommitmentTransactionDecodeErrorZ_is_ok(const struct LDKCResult_CommitmentTransactionDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_CommitmentTransactionDecodeErrorZ_is_ok(long o);
- // void CResult_CommitmentTransactionDecodeErrorZ_free(struct LDKCResult_CommitmentTransactionDecodeErrorZ _res);
- public static native void CResult_CommitmentTransactionDecodeErrorZ_free(long _res);
- // uint64_t CResult_CommitmentTransactionDecodeErrorZ_clone_ptr(LDKCResult_CommitmentTransactionDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_CommitmentTransactionDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_CommitmentTransactionDecodeErrorZ CResult_CommitmentTransactionDecodeErrorZ_clone(const struct LDKCResult_CommitmentTransactionDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_CommitmentTransactionDecodeErrorZ_clone(long orig);
- // struct LDKCResult_TrustedCommitmentTransactionNoneZ CResult_TrustedCommitmentTransactionNoneZ_ok(struct LDKTrustedCommitmentTransaction o);
- public static native long CResult_TrustedCommitmentTransactionNoneZ_ok(long o);
- // struct LDKCResult_TrustedCommitmentTransactionNoneZ CResult_TrustedCommitmentTransactionNoneZ_err(void);
- public static native long CResult_TrustedCommitmentTransactionNoneZ_err();
- // bool CResult_TrustedCommitmentTransactionNoneZ_is_ok(const struct LDKCResult_TrustedCommitmentTransactionNoneZ *NONNULL_PTR o);
- public static native boolean CResult_TrustedCommitmentTransactionNoneZ_is_ok(long o);
- // void CResult_TrustedCommitmentTransactionNoneZ_free(struct LDKCResult_TrustedCommitmentTransactionNoneZ _res);
- public static native void CResult_TrustedCommitmentTransactionNoneZ_free(long _res);
- // struct LDKCResult_CVec_SignatureZNoneZ CResult_CVec_SignatureZNoneZ_ok(struct LDKCVec_SignatureZ o);
- public static native long CResult_CVec_SignatureZNoneZ_ok(byte[][] o);
- // struct LDKCResult_CVec_SignatureZNoneZ CResult_CVec_SignatureZNoneZ_err(void);
- public static native long CResult_CVec_SignatureZNoneZ_err();
- // bool CResult_CVec_SignatureZNoneZ_is_ok(const struct LDKCResult_CVec_SignatureZNoneZ *NONNULL_PTR o);
- public static native boolean CResult_CVec_SignatureZNoneZ_is_ok(long o);
- // void CResult_CVec_SignatureZNoneZ_free(struct LDKCResult_CVec_SignatureZNoneZ _res);
- public static native void CResult_CVec_SignatureZNoneZ_free(long _res);
- // uint64_t CResult_CVec_SignatureZNoneZ_clone_ptr(LDKCResult_CVec_SignatureZNoneZ *NONNULL_PTR arg);
- public static native long CResult_CVec_SignatureZNoneZ_clone_ptr(long arg);
- // struct LDKCResult_CVec_SignatureZNoneZ CResult_CVec_SignatureZNoneZ_clone(const struct LDKCResult_CVec_SignatureZNoneZ *NONNULL_PTR orig);
- public static native long CResult_CVec_SignatureZNoneZ_clone(long orig);
- // struct LDKCResult_ShutdownScriptDecodeErrorZ CResult_ShutdownScriptDecodeErrorZ_ok(struct LDKShutdownScript o);
- public static native long CResult_ShutdownScriptDecodeErrorZ_ok(long o);
- // struct LDKCResult_ShutdownScriptDecodeErrorZ CResult_ShutdownScriptDecodeErrorZ_err(struct LDKDecodeError e);
- public static native long CResult_ShutdownScriptDecodeErrorZ_err(long e);
- // bool CResult_ShutdownScriptDecodeErrorZ_is_ok(const struct LDKCResult_ShutdownScriptDecodeErrorZ *NONNULL_PTR o);
- public static native boolean CResult_ShutdownScriptDecodeErrorZ_is_ok(long o);
- // void CResult_ShutdownScriptDecodeErrorZ_free(struct LDKCResult_ShutdownScriptDecodeErrorZ _res);
- public static native void CResult_ShutdownScriptDecodeErrorZ_free(long _res);
- // uint64_t CResult_ShutdownScriptDecodeErrorZ_clone_ptr(LDKCResult_ShutdownScriptDecodeErrorZ *NONNULL_PTR arg);
- public static native long CResult_ShutdownScriptDecodeErrorZ_clone_ptr(long arg);
- // struct LDKCResult_ShutdownScriptDecodeErrorZ CResult_ShutdownScriptDecodeErrorZ_clone(const struct LDKCResult_ShutdownScriptDecodeErrorZ *NONNULL_PTR orig);
- public static native long CResult_ShutdownScriptDecodeErrorZ_clone(long orig);
- // struct LDKCResult_ShutdownScriptInvalidShutdownScriptZ CResult_ShutdownScriptInvalidShutdownScriptZ_ok(struct LDKShutdownScript o);
- public static native long CResult_ShutdownScriptInvalidShutdownScriptZ_ok(long o);
- // struct LDKCResult_ShutdownScriptInvalidShutdownScriptZ CResult_ShutdownScriptInvalidShutdownScriptZ_err(struct LDKInvalidShutdownScript e);
- public static native long CResult_ShutdownScriptInvalidShutdownScriptZ_err(long e);
- // bool CResult_ShutdownScriptInvalidShutdownScriptZ_is_ok(const struct LDKCResult_ShutdownScriptInvalidShutdownScriptZ *NONNULL_PTR o);
- public static native boolean CResult_ShutdownScriptInvalidShutdownScriptZ_is_ok(long o);
- // void CResult_ShutdownScriptInvalidShutdownScriptZ_free(struct LDKCResult_ShutdownScriptInvalidShutdownScriptZ _res);
- public static native void CResult_ShutdownScriptInvalidShutdownScriptZ_free(long _res);
- // uint64_t CResult_ShutdownScriptInvalidShutdownScriptZ_clone_ptr(LDKCResult_ShutdownScriptInvalidShutdownScriptZ *NONNULL_PTR arg);
- public static native long CResult_ShutdownScriptInvalidShutdownScriptZ_clone_ptr(long arg);
- // struct LDKCResult_ShutdownScriptInvalidShutdownScriptZ CResult_ShutdownScriptInvalidShutdownScriptZ_clone(const struct LDKCResult_ShutdownScriptInvalidShutdownScriptZ *NONNULL_PTR orig);
- public static native long CResult_ShutdownScriptInvalidShutdownScriptZ_clone(long orig);
+ static { LDKBolt11ParseError.init(); }
+ public static native LDKBolt11ParseError LDKBolt11ParseError_ref_from_ptr(long ptr);
+ // enum LDKSiPrefix CResult_SiPrefixBolt11ParseErrorZ_get_ok(LDKCResult_SiPrefixBolt11ParseErrorZ *NONNULL_PTR owner);
+ public static native SiPrefix CResult_SiPrefixBolt11ParseErrorZ_get_ok(long owner);
+ // struct LDKBolt11ParseError CResult_SiPrefixBolt11ParseErrorZ_get_err(LDKCResult_SiPrefixBolt11ParseErrorZ *NONNULL_PTR owner);
+ public static native long CResult_SiPrefixBolt11ParseErrorZ_get_err(long owner);
+ public static class LDKParseOrSemanticError {
+ private LDKParseOrSemanticError() {}
+ public final static class ParseError extends LDKParseOrSemanticError {
+ public long parse_error;
+ ParseError(long parse_error) { this.parse_error = parse_error; }
+ }
+ public final static class SemanticError extends LDKParseOrSemanticError {
+ public org.ldk.enums.Bolt11SemanticError semantic_error;
+ SemanticError(org.ldk.enums.Bolt11SemanticError semantic_error) { this.semantic_error = semantic_error; }
+ }
+ static native void init();
+ }
+ static { LDKParseOrSemanticError.init(); }
+ public static native LDKParseOrSemanticError LDKParseOrSemanticError_ref_from_ptr(long ptr);
+ // struct LDKBolt11Invoice CResult_Bolt11InvoiceParseOrSemanticErrorZ_get_ok(LDKCResult_Bolt11InvoiceParseOrSemanticErrorZ *NONNULL_PTR owner);
+ public static native long CResult_Bolt11InvoiceParseOrSemanticErrorZ_get_ok(long owner);
+ // struct LDKParseOrSemanticError CResult_Bolt11InvoiceParseOrSemanticErrorZ_get_err(LDKCResult_Bolt11InvoiceParseOrSemanticErrorZ *NONNULL_PTR owner);
+ public static native long CResult_Bolt11InvoiceParseOrSemanticErrorZ_get_err(long owner);
+ // struct LDKSignedRawBolt11Invoice CResult_SignedRawBolt11InvoiceBolt11ParseErrorZ_get_ok(LDKCResult_SignedRawBolt11InvoiceBolt11ParseErrorZ *NONNULL_PTR owner);
+ public static native long CResult_SignedRawBolt11InvoiceBolt11ParseErrorZ_get_ok(long owner);
+ // struct LDKBolt11ParseError CResult_SignedRawBolt11InvoiceBolt11ParseErrorZ_get_err(LDKCResult_SignedRawBolt11InvoiceBolt11ParseErrorZ *NONNULL_PTR owner);
+ public static native long CResult_SignedRawBolt11InvoiceBolt11ParseErrorZ_get_err(long owner);
+ // struct LDKRawBolt11Invoice C3Tuple_RawBolt11Invoice_u832Bolt11InvoiceSignatureZ_get_a(LDKC3Tuple_RawBolt11Invoice_u832Bolt11InvoiceSignatureZ *NONNULL_PTR owner);
+ public static native long C3Tuple_RawBolt11Invoice_u832Bolt11InvoiceSignatureZ_get_a(long owner);
+ // struct LDKThirtyTwoBytes C3Tuple_RawBolt11Invoice_u832Bolt11InvoiceSignatureZ_get_b(LDKC3Tuple_RawBolt11Invoice_u832Bolt11InvoiceSignatureZ *NONNULL_PTR owner);
+ public static native byte[] C3Tuple_RawBolt11Invoice_u832Bolt11InvoiceSignatureZ_get_b(long owner);
+ // struct LDKBolt11InvoiceSignature C3Tuple_RawBolt11Invoice_u832Bolt11InvoiceSignatureZ_get_c(LDKC3Tuple_RawBolt11Invoice_u832Bolt11InvoiceSignatureZ *NONNULL_PTR owner);
+ public static native long C3Tuple_RawBolt11Invoice_u832Bolt11InvoiceSignatureZ_get_c(long owner);
+ // struct LDKPayeePubKey CResult_PayeePubKeySecp256k1ErrorZ_get_ok(LDKCResult_PayeePubKeySecp256k1ErrorZ *NONNULL_PTR owner);
+ public static native long CResult_PayeePubKeySecp256k1ErrorZ_get_ok(long owner);
+ // enum LDKSecp256k1Error CResult_PayeePubKeySecp256k1ErrorZ_get_err(LDKCResult_PayeePubKeySecp256k1ErrorZ *NONNULL_PTR owner);
+ public static native Secp256k1Error CResult_PayeePubKeySecp256k1ErrorZ_get_err(long owner);
+ // struct LDKPositiveTimestamp CResult_PositiveTimestampCreationErrorZ_get_ok(LDKCResult_PositiveTimestampCreationErrorZ *NONNULL_PTR owner);
+ public static native long CResult_PositiveTimestampCreationErrorZ_get_ok(long owner);
+ // enum LDKCreationError CResult_PositiveTimestampCreationErrorZ_get_err(LDKCResult_PositiveTimestampCreationErrorZ *NONNULL_PTR owner);
+ public static native CreationError CResult_PositiveTimestampCreationErrorZ_get_err(long owner);
+ // void CResult_NoneBolt11SemanticErrorZ_get_ok(LDKCResult_NoneBolt11SemanticErrorZ *NONNULL_PTR owner);
+ public static native void CResult_NoneBolt11SemanticErrorZ_get_ok(long owner);
+ // enum LDKBolt11SemanticError CResult_NoneBolt11SemanticErrorZ_get_err(LDKCResult_NoneBolt11SemanticErrorZ *NONNULL_PTR owner);
+ public static native Bolt11SemanticError CResult_NoneBolt11SemanticErrorZ_get_err(long owner);
+ // struct LDKBolt11Invoice CResult_Bolt11InvoiceBolt11SemanticErrorZ_get_ok(LDKCResult_Bolt11InvoiceBolt11SemanticErrorZ *NONNULL_PTR owner);
+ public static native long CResult_Bolt11InvoiceBolt11SemanticErrorZ_get_ok(long owner);
+ // enum LDKBolt11SemanticError CResult_Bolt11InvoiceBolt11SemanticErrorZ_get_err(LDKCResult_Bolt11InvoiceBolt11SemanticErrorZ *NONNULL_PTR owner);
+ public static native Bolt11SemanticError CResult_Bolt11InvoiceBolt11SemanticErrorZ_get_err(long owner);
+ // struct LDKDescription CResult_DescriptionCreationErrorZ_get_ok(LDKCResult_DescriptionCreationErrorZ *NONNULL_PTR owner);
+ public static native long CResult_DescriptionCreationErrorZ_get_ok(long owner);
+ // enum LDKCreationError CResult_DescriptionCreationErrorZ_get_err(LDKCResult_DescriptionCreationErrorZ *NONNULL_PTR owner);
+ public static native CreationError CResult_DescriptionCreationErrorZ_get_err(long owner);
+ // struct LDKPrivateRoute CResult_PrivateRouteCreationErrorZ_get_ok(LDKCResult_PrivateRouteCreationErrorZ *NONNULL_PTR owner);
+ public static native long CResult_PrivateRouteCreationErrorZ_get_ok(long owner);
+ // enum LDKCreationError CResult_PrivateRouteCreationErrorZ_get_err(LDKCResult_PrivateRouteCreationErrorZ *NONNULL_PTR owner);
+ public static native CreationError CResult_PrivateRouteCreationErrorZ_get_err(long owner);
+ // struct LDKOutPoint CResult_OutPointDecodeErrorZ_get_ok(LDKCResult_OutPointDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_OutPointDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_OutPointDecodeErrorZ_get_err(LDKCResult_OutPointDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_OutPointDecodeErrorZ_get_err(long owner);
+ // struct LDKBigSize CResult_BigSizeDecodeErrorZ_get_ok(LDKCResult_BigSizeDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_BigSizeDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_BigSizeDecodeErrorZ_get_err(LDKCResult_BigSizeDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_BigSizeDecodeErrorZ_get_err(long owner);
+ // struct LDKHostname CResult_HostnameDecodeErrorZ_get_ok(LDKCResult_HostnameDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_HostnameDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_HostnameDecodeErrorZ_get_err(LDKCResult_HostnameDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_HostnameDecodeErrorZ_get_err(long owner);
+ // struct LDKTransactionU16LenLimited CResult_TransactionU16LenLimitedNoneZ_get_ok(LDKCResult_TransactionU16LenLimitedNoneZ *NONNULL_PTR owner);
+ public static native long CResult_TransactionU16LenLimitedNoneZ_get_ok(long owner);
+ // void CResult_TransactionU16LenLimitedNoneZ_get_err(LDKCResult_TransactionU16LenLimitedNoneZ *NONNULL_PTR owner);
+ public static native void CResult_TransactionU16LenLimitedNoneZ_get_err(long owner);
+ // struct LDKTransactionU16LenLimited CResult_TransactionU16LenLimitedDecodeErrorZ_get_ok(LDKCResult_TransactionU16LenLimitedDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_TransactionU16LenLimitedDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_TransactionU16LenLimitedDecodeErrorZ_get_err(LDKCResult_TransactionU16LenLimitedDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_TransactionU16LenLimitedDecodeErrorZ_get_err(long owner);
+ // struct LDKUntrustedString CResult_UntrustedStringDecodeErrorZ_get_ok(LDKCResult_UntrustedStringDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_UntrustedStringDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_UntrustedStringDecodeErrorZ_get_err(LDKCResult_UntrustedStringDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_UntrustedStringDecodeErrorZ_get_err(long owner);
+ // struct LDKReceiveTlvs CResult_ReceiveTlvsDecodeErrorZ_get_ok(LDKCResult_ReceiveTlvsDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_ReceiveTlvsDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_ReceiveTlvsDecodeErrorZ_get_err(LDKCResult_ReceiveTlvsDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_ReceiveTlvsDecodeErrorZ_get_err(long owner);
+ // struct LDKPaymentRelay CResult_PaymentRelayDecodeErrorZ_get_ok(LDKCResult_PaymentRelayDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_PaymentRelayDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_PaymentRelayDecodeErrorZ_get_err(LDKCResult_PaymentRelayDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_PaymentRelayDecodeErrorZ_get_err(long owner);
+ // struct LDKPaymentConstraints CResult_PaymentConstraintsDecodeErrorZ_get_ok(LDKCResult_PaymentConstraintsDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_PaymentConstraintsDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_PaymentConstraintsDecodeErrorZ_get_err(LDKCResult_PaymentConstraintsDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_PaymentConstraintsDecodeErrorZ_get_err(long owner);
+ public static class LDKPaymentError {
+ private LDKPaymentError() {}
+ public final static class Invoice extends LDKPaymentError {
+ public java.lang.String invoice;
+ Invoice(java.lang.String invoice) { this.invoice = invoice; }
+ }
+ public final static class Sending extends LDKPaymentError {
+ public org.ldk.enums.RetryableSendFailure sending;
+ Sending(org.ldk.enums.RetryableSendFailure sending) { this.sending = sending; }
+ }
+ static native void init();
+ }
+ static { LDKPaymentError.init(); }
+ public static native LDKPaymentError LDKPaymentError_ref_from_ptr(long ptr);
+ // struct LDKThirtyTwoBytes CResult_ThirtyTwoBytesPaymentErrorZ_get_ok(LDKCResult_ThirtyTwoBytesPaymentErrorZ *NONNULL_PTR owner);
+ public static native byte[] CResult_ThirtyTwoBytesPaymentErrorZ_get_ok(long owner);
+ // struct LDKPaymentError CResult_ThirtyTwoBytesPaymentErrorZ_get_err(LDKCResult_ThirtyTwoBytesPaymentErrorZ *NONNULL_PTR owner);
+ public static native long CResult_ThirtyTwoBytesPaymentErrorZ_get_err(long owner);
+ // void CResult_NonePaymentErrorZ_get_ok(LDKCResult_NonePaymentErrorZ *NONNULL_PTR owner);
+ public static native void CResult_NonePaymentErrorZ_get_ok(long owner);
+ // struct LDKPaymentError CResult_NonePaymentErrorZ_get_err(LDKCResult_NonePaymentErrorZ *NONNULL_PTR owner);
+ public static native long CResult_NonePaymentErrorZ_get_err(long owner);
+ public static class LDKProbingError {
+ private LDKProbingError() {}
+ public final static class Invoice extends LDKProbingError {
+ public java.lang.String invoice;
+ Invoice(java.lang.String invoice) { this.invoice = invoice; }
+ }
+ public final static class Sending extends LDKProbingError {
+ public long sending;
+ Sending(long sending) { this.sending = sending; }
+ }
+ static native void init();
+ }
+ static { LDKProbingError.init(); }
+ public static native LDKProbingError LDKProbingError_ref_from_ptr(long ptr);
+ // struct LDKCVec_C2Tuple_ThirtyTwoBytesThirtyTwoBytesZZ CResult_CVec_C2Tuple_ThirtyTwoBytesThirtyTwoBytesZZProbingErrorZ_get_ok(LDKCResult_CVec_C2Tuple_ThirtyTwoBytesThirtyTwoBytesZZProbingErrorZ *NONNULL_PTR owner);
+ public static native long[] CResult_CVec_C2Tuple_ThirtyTwoBytesThirtyTwoBytesZZProbingErrorZ_get_ok(long owner);
+ // struct LDKProbingError CResult_CVec_C2Tuple_ThirtyTwoBytesThirtyTwoBytesZZProbingErrorZ_get_err(LDKCResult_CVec_C2Tuple_ThirtyTwoBytesThirtyTwoBytesZZProbingErrorZ *NONNULL_PTR owner);
+ public static native long CResult_CVec_C2Tuple_ThirtyTwoBytesThirtyTwoBytesZZProbingErrorZ_get_err(long owner);
+ // struct LDKStr CResult_StrSecp256k1ErrorZ_get_ok(LDKCResult_StrSecp256k1ErrorZ *NONNULL_PTR owner);
+ public static native String CResult_StrSecp256k1ErrorZ_get_ok(long owner);
+ // enum LDKSecp256k1Error CResult_StrSecp256k1ErrorZ_get_err(LDKCResult_StrSecp256k1ErrorZ *NONNULL_PTR owner);
+ public static native Secp256k1Error CResult_StrSecp256k1ErrorZ_get_err(long owner);
+ // struct LDKOnionMessagePath CResult_OnionMessagePathNoneZ_get_ok(LDKCResult_OnionMessagePathNoneZ *NONNULL_PTR owner);
+ public static native long CResult_OnionMessagePathNoneZ_get_ok(long owner);
+ // void CResult_OnionMessagePathNoneZ_get_err(LDKCResult_OnionMessagePathNoneZ *NONNULL_PTR owner);
+ public static native void CResult_OnionMessagePathNoneZ_get_err(long owner);
+ // struct LDKPublicKey C2Tuple_PublicKeyOnionMessageZ_get_a(LDKC2Tuple_PublicKeyOnionMessageZ *NONNULL_PTR owner);
+ public static native byte[] C2Tuple_PublicKeyOnionMessageZ_get_a(long owner);
+ // struct LDKOnionMessage C2Tuple_PublicKeyOnionMessageZ_get_b(LDKC2Tuple_PublicKeyOnionMessageZ *NONNULL_PTR owner);
+ public static native long C2Tuple_PublicKeyOnionMessageZ_get_b(long owner);
+ public static class LDKSendError {
+ private LDKSendError() {}
+ public final static class Secp256k1 extends LDKSendError {
+ public org.ldk.enums.Secp256k1Error secp256k1;
+ Secp256k1(org.ldk.enums.Secp256k1Error secp256k1) { this.secp256k1 = secp256k1; }
+ }
+ public final static class TooBigPacket extends LDKSendError {
+ TooBigPacket() { }
+ }
+ public final static class TooFewBlindedHops extends LDKSendError {
+ TooFewBlindedHops() { }
+ }
+ public final static class InvalidFirstHop extends LDKSendError {
+ InvalidFirstHop() { }
+ }
+ public final static class InvalidMessage extends LDKSendError {
+ InvalidMessage() { }
+ }
+ public final static class BufferFull extends LDKSendError {
+ BufferFull() { }
+ }
+ public final static class GetNodeIdFailed extends LDKSendError {
+ GetNodeIdFailed() { }
+ }
+ public final static class BlindedPathAdvanceFailed extends LDKSendError {
+ BlindedPathAdvanceFailed() { }
+ }
+ static native void init();
+ }
+ static { LDKSendError.init(); }
+ public static native LDKSendError LDKSendError_ref_from_ptr(long ptr);
+ // struct LDKC2Tuple_PublicKeyOnionMessageZ CResult_C2Tuple_PublicKeyOnionMessageZSendErrorZ_get_ok(LDKCResult_C2Tuple_PublicKeyOnionMessageZSendErrorZ *NONNULL_PTR owner);
+ public static native long CResult_C2Tuple_PublicKeyOnionMessageZSendErrorZ_get_ok(long owner);
+ // struct LDKSendError CResult_C2Tuple_PublicKeyOnionMessageZSendErrorZ_get_err(LDKCResult_C2Tuple_PublicKeyOnionMessageZSendErrorZ *NONNULL_PTR owner);
+ public static native long CResult_C2Tuple_PublicKeyOnionMessageZSendErrorZ_get_err(long owner);
+ public static class LDKParsedOnionMessageContents {
+ private LDKParsedOnionMessageContents() {}
+ public final static class Offers extends LDKParsedOnionMessageContents {
+ public long offers;
+ Offers(long offers) { this.offers = offers; }
+ }
+ public final static class Custom extends LDKParsedOnionMessageContents {
+ public long custom;
+ Custom(long custom) { this.custom = custom; }
+ }
+ static native void init();
+ }
+ static { LDKParsedOnionMessageContents.init(); }
+ public static native LDKParsedOnionMessageContents LDKParsedOnionMessageContents_ref_from_ptr(long ptr);
+ public static class LDKPeeledOnion {
+ private LDKPeeledOnion() {}
+ public final static class Forward extends LDKPeeledOnion {
+ public byte[] _0;
+ public long _1;
+ Forward(byte[] _0, long _1) { this._0 = _0; this._1 = _1; }
+ }
+ public final static class Receive extends LDKPeeledOnion {
+ public long _0;
+ public byte[] _1;
+ public long _2;
+ Receive(long _0, byte[] _1, long _2) { this._0 = _0; this._1 = _1; this._2 = _2; }
+ }
+ static native void init();
+ }
+ static { LDKPeeledOnion.init(); }
+ public static native LDKPeeledOnion LDKPeeledOnion_ref_from_ptr(long ptr);
+ // struct LDKPeeledOnion CResult_PeeledOnionNoneZ_get_ok(LDKCResult_PeeledOnionNoneZ *NONNULL_PTR owner);
+ public static native long CResult_PeeledOnionNoneZ_get_ok(long owner);
+ // void CResult_PeeledOnionNoneZ_get_err(LDKCResult_PeeledOnionNoneZ *NONNULL_PTR owner);
+ public static native void CResult_PeeledOnionNoneZ_get_err(long owner);
+ // void CResult_NoneSendErrorZ_get_ok(LDKCResult_NoneSendErrorZ *NONNULL_PTR owner);
+ public static native void CResult_NoneSendErrorZ_get_ok(long owner);
+ // struct LDKSendError CResult_NoneSendErrorZ_get_err(LDKCResult_NoneSendErrorZ *NONNULL_PTR owner);
+ public static native long CResult_NoneSendErrorZ_get_err(long owner);
+ // struct LDKBlindedPath CResult_BlindedPathNoneZ_get_ok(LDKCResult_BlindedPathNoneZ *NONNULL_PTR owner);
+ public static native long CResult_BlindedPathNoneZ_get_ok(long owner);
+ // void CResult_BlindedPathNoneZ_get_err(LDKCResult_BlindedPathNoneZ *NONNULL_PTR owner);
+ public static native void CResult_BlindedPathNoneZ_get_err(long owner);
+ // struct LDKC2Tuple_BlindedPayInfoBlindedPathZ CResult_C2Tuple_BlindedPayInfoBlindedPathZNoneZ_get_ok(LDKCResult_C2Tuple_BlindedPayInfoBlindedPathZNoneZ *NONNULL_PTR owner);
+ public static native long CResult_C2Tuple_BlindedPayInfoBlindedPathZNoneZ_get_ok(long owner);
+ // void CResult_C2Tuple_BlindedPayInfoBlindedPathZNoneZ_get_err(LDKCResult_C2Tuple_BlindedPayInfoBlindedPathZNoneZ *NONNULL_PTR owner);
+ public static native void CResult_C2Tuple_BlindedPayInfoBlindedPathZNoneZ_get_err(long owner);
+ // struct LDKBlindedPath CResult_BlindedPathDecodeErrorZ_get_ok(LDKCResult_BlindedPathDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_BlindedPathDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_BlindedPathDecodeErrorZ_get_err(LDKCResult_BlindedPathDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_BlindedPathDecodeErrorZ_get_err(long owner);
+ // struct LDKBlindedHop CResult_BlindedHopDecodeErrorZ_get_ok(LDKCResult_BlindedHopDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_BlindedHopDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_BlindedHopDecodeErrorZ_get_err(LDKCResult_BlindedHopDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_BlindedHopDecodeErrorZ_get_err(long owner);
+ // struct LDKInvoiceError CResult_InvoiceErrorDecodeErrorZ_get_ok(LDKCResult_InvoiceErrorDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_InvoiceErrorDecodeErrorZ_get_ok(long owner);
+ // struct LDKDecodeError CResult_InvoiceErrorDecodeErrorZ_get_err(LDKCResult_InvoiceErrorDecodeErrorZ *NONNULL_PTR owner);
+ public static native long CResult_InvoiceErrorDecodeErrorZ_get_err(long owner);
+ public interface LDKFilter {
+ void register_tx(byte[] txid, byte[] script_pubkey);
+ void register_output(long output);
+ }
+ public static native long LDKFilter_new(LDKFilter impl);
+ // void Filter_register_tx LDKFilter *NONNULL_PTR this_arg, const uint8_t (*txid)[32], struct LDKu8slice script_pubkey
+ public static native void Filter_register_tx(long this_arg, byte[] txid, byte[] script_pubkey);
+ // void Filter_register_output LDKFilter *NONNULL_PTR this_arg, struct LDKWatchedOutput output
+ public static native void Filter_register_output(long this_arg, long output);
+ public static class LDKCOption_FilterZ {
+ private LDKCOption_FilterZ() {}
+ public final static class Some extends LDKCOption_FilterZ {
+ public long some;
+ Some(long some) { this.some = some; }
+ }
+ public final static class None extends LDKCOption_FilterZ {
+ None() { }
+ }
+ static native void init();
+ }
+ static { LDKCOption_FilterZ.init(); }
+ public static native LDKCOption_FilterZ LDKCOption_FilterZ_ref_from_ptr(long ptr);
+ // struct LDKLockedChannelMonitor CResult_LockedChannelMonitorNoneZ_get_ok(LDKCResult_LockedChannelMonitorNoneZ *NONNULL_PTR owner);
+ public static native long CResult_LockedChannelMonitorNoneZ_get_ok(long owner);
+ // void CResult_LockedChannelMonitorNoneZ_get_err(LDKCResult_LockedChannelMonitorNoneZ *NONNULL_PTR owner);
+ public static native void CResult_LockedChannelMonitorNoneZ_get_err(long owner);
+ // struct LDKOutPoint C2Tuple_OutPointCVec_MonitorUpdateIdZZ_get_a(LDKC2Tuple_OutPointCVec_MonitorUpdateIdZZ *NONNULL_PTR owner);
+ public static native long C2Tuple_OutPointCVec_MonitorUpdateIdZZ_get_a(long owner);
+ // struct LDKCVec_MonitorUpdateIdZ C2Tuple_OutPointCVec_MonitorUpdateIdZZ_get_b(LDKC2Tuple_OutPointCVec_MonitorUpdateIdZZ *NONNULL_PTR owner);
+ public static native long[] C2Tuple_OutPointCVec_MonitorUpdateIdZZ_get_b(long owner);
+ public interface LDKKVStore {
+ long read(String primary_namespace, String secondary_namespace, String key);
+ long write(String primary_namespace, String secondary_namespace, String key, byte[] buf);
+ long remove(String primary_namespace, String secondary_namespace, String key, boolean lazy);
+ long list(String primary_namespace, String secondary_namespace);
+ }
+ public static native long LDKKVStore_new(LDKKVStore impl);
+ // LDKCResult_CVec_u8ZIOErrorZ KVStore_read LDKKVStore *NONNULL_PTR this_arg, struct LDKStr primary_namespace, struct LDKStr secondary_namespace, struct LDKStr key
+ public static native long KVStore_read(long this_arg, String primary_namespace, String secondary_namespace, String key);
+ // LDKCResult_NoneIOErrorZ KVStore_write LDKKVStore *NONNULL_PTR this_arg, struct LDKStr primary_namespace, struct LDKStr secondary_namespace, struct LDKStr key, struct LDKu8slice buf
+ public static native long KVStore_write(long this_arg, String primary_namespace, String secondary_namespace, String key, byte[] buf);
+ // LDKCResult_NoneIOErrorZ KVStore_remove LDKKVStore *NONNULL_PTR this_arg, struct LDKStr primary_namespace, struct LDKStr secondary_namespace, struct LDKStr key, bool lazy
+ public static native long KVStore_remove(long this_arg, String primary_namespace, String secondary_namespace, String key, boolean lazy);
+ // LDKCResult_CVec_StrZIOErrorZ KVStore_list LDKKVStore *NONNULL_PTR this_arg, struct LDKStr primary_namespace, struct LDKStr secondary_namespace
+ public static native long KVStore_list(long this_arg, String primary_namespace, String secondary_namespace);
+ public interface LDKPersister {
+ long persist_manager(long channel_manager);
+ long persist_graph(long network_graph);
+ long persist_scorer(long scorer);
+ }
+ public static native long LDKPersister_new(LDKPersister impl);
+ // LDKCResult_NoneIOErrorZ Persister_persist_manager LDKPersister *NONNULL_PTR this_arg, const struct LDKChannelManager *NONNULL_PTR channel_manager
+ public static native long Persister_persist_manager(long this_arg, long channel_manager);
+ // LDKCResult_NoneIOErrorZ Persister_persist_graph LDKPersister *NONNULL_PTR this_arg, const struct LDKNetworkGraph *NONNULL_PTR network_graph
+ public static native long Persister_persist_graph(long this_arg, long network_graph);
+ // LDKCResult_NoneIOErrorZ Persister_persist_scorer LDKPersister *NONNULL_PTR this_arg, const struct LDKWriteableScore *NONNULL_PTR scorer
+ public static native long Persister_persist_scorer(long this_arg, long scorer);
+ public interface LDKPersist {
+ ChannelMonitorUpdateStatus persist_new_channel(long channel_id, long data, long update_id);
+ ChannelMonitorUpdateStatus update_persisted_channel(long channel_id, long update, long data, long update_id);
+ }
+ public static native long LDKPersist_new(LDKPersist impl);
+ // LDKChannelMonitorUpdateStatus Persist_persist_new_channel LDKPersist *NONNULL_PTR this_arg, struct LDKOutPoint channel_id, const struct LDKChannelMonitor *NONNULL_PTR data, struct LDKMonitorUpdateId update_id
+ public static native ChannelMonitorUpdateStatus Persist_persist_new_channel(long this_arg, long channel_id, long data, long update_id);
+ // LDKChannelMonitorUpdateStatus Persist_update_persisted_channel LDKPersist *NONNULL_PTR this_arg, struct LDKOutPoint channel_id, struct LDKChannelMonitorUpdate update, const struct LDKChannelMonitor *NONNULL_PTR data, struct LDKMonitorUpdateId update_id
+ public static native ChannelMonitorUpdateStatus Persist_update_persisted_channel(long this_arg, long channel_id, long update, long data, long update_id);
+ public interface LDKFutureCallback {
+ void call();
+ }
+ public static native long LDKFutureCallback_new(LDKFutureCallback impl);
+ // void FutureCallback_call LDKFutureCallback *NONNULL_PTR this_arg
+ public static native void FutureCallback_call(long this_arg);
+ public interface LDKListen {
+ void filtered_block_connected(byte[] header, long[] txdata, int height);
+ void block_connected(byte[] block, int height);
+ void block_disconnected(byte[] header, int height);
+ }
+ public static native long LDKListen_new(LDKListen impl);
+ // void Listen_filtered_block_connected LDKListen *NONNULL_PTR this_arg, const uint8_t (*header)[80], struct LDKCVec_C2Tuple_usizeTransactionZZ txdata, uint32_t height
+ public static native void Listen_filtered_block_connected(long this_arg, byte[] header, long[] txdata, int height);
+ // void Listen_block_connected LDKListen *NONNULL_PTR this_arg, struct LDKu8slice block, uint32_t height
+ public static native void Listen_block_connected(long this_arg, byte[] block, int height);
+ // void Listen_block_disconnected LDKListen *NONNULL_PTR this_arg, const uint8_t (*header)[80], uint32_t height
+ public static native void Listen_block_disconnected(long this_arg, byte[] header, int height);
+ public interface LDKConfirm {
+ void transactions_confirmed(byte[] header, long[] txdata, int height);
+ void transaction_unconfirmed(byte[] txid);
+ void best_block_updated(byte[] header, int height);
+ long[] get_relevant_txids();
+ }
+ public static native long LDKConfirm_new(LDKConfirm impl);
+ // void Confirm_transactions_confirmed LDKConfirm *NONNULL_PTR this_arg, const uint8_t (*header)[80], struct LDKCVec_C2Tuple_usizeTransactionZZ txdata, uint32_t height
+ public static native void Confirm_transactions_confirmed(long this_arg, byte[] header, long[] txdata, int height);
+ // void Confirm_transaction_unconfirmed LDKConfirm *NONNULL_PTR this_arg, const uint8_t (*txid)[32]
+ public static native void Confirm_transaction_unconfirmed(long this_arg, byte[] txid);
+ // void Confirm_best_block_updated LDKConfirm *NONNULL_PTR this_arg, const uint8_t (*header)[80], uint32_t height
+ public static native void Confirm_best_block_updated(long this_arg, byte[] header, int height);
+ // LDKCVec_C2Tuple_ThirtyTwoBytesCOption_ThirtyTwoBytesZZZ Confirm_get_relevant_txids LDKConfirm *NONNULL_PTR this_arg
+ public static native long[] Confirm_get_relevant_txids(long this_arg);
+ public interface LDKEventHandler {
+ void handle_event(long event);
+ }
+ public static native long LDKEventHandler_new(LDKEventHandler impl);
+ // void EventHandler_handle_event LDKEventHandler *NONNULL_PTR this_arg, struct LDKEvent event
+ public static native void EventHandler_handle_event(long this_arg, long event);
+ public interface LDKEventsProvider {
+ void process_pending_events(long handler);
+ }
+ public static native long LDKEventsProvider_new(LDKEventsProvider impl);
+ // void EventsProvider_process_pending_events LDKEventsProvider *NONNULL_PTR this_arg, struct LDKEventHandler handler
+ public static native void EventsProvider_process_pending_events(long this_arg, long handler);
+ public static class LDKFailureCode {
+ private LDKFailureCode() {}
+ public final static class TemporaryNodeFailure extends LDKFailureCode {
+ TemporaryNodeFailure() { }
+ }
+ public final static class RequiredNodeFeatureMissing extends LDKFailureCode {
+ RequiredNodeFeatureMissing() { }
+ }
+ public final static class IncorrectOrUnknownPaymentDetails extends LDKFailureCode {
+ IncorrectOrUnknownPaymentDetails() { }
+ }
+ public final static class InvalidOnionPayload extends LDKFailureCode {
+ public long invalid_onion_payload;
+ InvalidOnionPayload(long invalid_onion_payload) { this.invalid_onion_payload = invalid_onion_payload; }
+ }
+ static native void init();
+ }
+ static { LDKFailureCode.init(); }
+ public static native LDKFailureCode LDKFailureCode_ref_from_ptr(long ptr);
+ public interface LDKMessageSendEventsProvider {
+ long[] get_and_clear_pending_msg_events();
+ }
+ public static native long LDKMessageSendEventsProvider_new(LDKMessageSendEventsProvider impl);
+ // LDKCVec_MessageSendEventZ MessageSendEventsProvider_get_and_clear_pending_msg_events LDKMessageSendEventsProvider *NONNULL_PTR this_arg
+ public static native long[] MessageSendEventsProvider_get_and_clear_pending_msg_events(long this_arg);
+ public interface LDKChannelMessageHandler {
+ void handle_open_channel(byte[] their_node_id, long msg);
+ void handle_open_channel_v2(byte[] their_node_id, long msg);
+ void handle_accept_channel(byte[] their_node_id, long msg);
+ void handle_accept_channel_v2(byte[] their_node_id, long msg);
+ void handle_funding_created(byte[] their_node_id, long msg);
+ void handle_funding_signed(byte[] their_node_id, long msg);
+ void handle_channel_ready(byte[] their_node_id, long msg);
+ void handle_shutdown(byte[] their_node_id, long msg);
+ void handle_closing_signed(byte[] their_node_id, long msg);
+ void handle_tx_add_input(byte[] their_node_id, long msg);
+ void handle_tx_add_output(byte[] their_node_id, long msg);
+ void handle_tx_remove_input(byte[] their_node_id, long msg);
+ void handle_tx_remove_output(byte[] their_node_id, long msg);
+ void handle_tx_complete(byte[] their_node_id, long msg);
+ void handle_tx_signatures(byte[] their_node_id, long msg);
+ void handle_tx_init_rbf(byte[] their_node_id, long msg);
+ void handle_tx_ack_rbf(byte[] their_node_id, long msg);
+ void handle_tx_abort(byte[] their_node_id, long msg);
+ void handle_update_add_htlc(byte[] their_node_id, long msg);
+ void handle_update_fulfill_htlc(byte[] their_node_id, long msg);
+ void handle_update_fail_htlc(byte[] their_node_id, long msg);
+ void handle_update_fail_malformed_htlc(byte[] their_node_id, long msg);
+ void handle_commitment_signed(byte[] their_node_id, long msg);
+ void handle_revoke_and_ack(byte[] their_node_id, long msg);
+ void handle_update_fee(byte[] their_node_id, long msg);
+ void handle_announcement_signatures(byte[] their_node_id, long msg);
+ void peer_disconnected(byte[] their_node_id);
+ long peer_connected(byte[] their_node_id, long msg, boolean inbound);
+ void handle_channel_reestablish(byte[] their_node_id, long msg);
+ void handle_channel_update(byte[] their_node_id, long msg);
+ void handle_error(byte[] their_node_id, long msg);
+ long provided_node_features();
+ long provided_init_features(byte[] their_node_id);
+ long get_chain_hashes();
+ }
+ public static native long LDKChannelMessageHandler_new(LDKChannelMessageHandler impl, LDKMessageSendEventsProvider MessageSendEventsProvider);
+ public static native long LDKChannelMessageHandler_get_MessageSendEventsProvider(long arg);
+ // void ChannelMessageHandler_handle_open_channel LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKOpenChannel *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_open_channel(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_open_channel_v2 LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKOpenChannelV2 *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_open_channel_v2(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_accept_channel LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKAcceptChannel *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_accept_channel(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_accept_channel_v2 LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKAcceptChannelV2 *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_accept_channel_v2(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_funding_created LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKFundingCreated *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_funding_created(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_funding_signed LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKFundingSigned *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_funding_signed(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_channel_ready LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKChannelReady *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_channel_ready(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_shutdown LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKShutdown *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_shutdown(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_closing_signed LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKClosingSigned *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_closing_signed(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_tx_add_input LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKTxAddInput *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_tx_add_input(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_tx_add_output LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKTxAddOutput *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_tx_add_output(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_tx_remove_input LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKTxRemoveInput *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_tx_remove_input(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_tx_remove_output LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKTxRemoveOutput *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_tx_remove_output(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_tx_complete LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKTxComplete *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_tx_complete(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_tx_signatures LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKTxSignatures *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_tx_signatures(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_tx_init_rbf LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKTxInitRbf *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_tx_init_rbf(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_tx_ack_rbf LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKTxAckRbf *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_tx_ack_rbf(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_tx_abort LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKTxAbort *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_tx_abort(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_update_add_htlc LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKUpdateAddHTLC *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_update_add_htlc(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_update_fulfill_htlc LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKUpdateFulfillHTLC *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_update_fulfill_htlc(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_update_fail_htlc LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKUpdateFailHTLC *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_update_fail_htlc(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_update_fail_malformed_htlc LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKUpdateFailMalformedHTLC *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_update_fail_malformed_htlc(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_commitment_signed LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKCommitmentSigned *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_commitment_signed(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_revoke_and_ack LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKRevokeAndACK *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_revoke_and_ack(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_update_fee LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKUpdateFee *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_update_fee(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_announcement_signatures LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKAnnouncementSignatures *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_announcement_signatures(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_peer_disconnected LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id
+ public static native void ChannelMessageHandler_peer_disconnected(long this_arg, byte[] their_node_id);
+ // LDKCResult_NoneNoneZ ChannelMessageHandler_peer_connected LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKInit *NONNULL_PTR msg, bool inbound
+ public static native long ChannelMessageHandler_peer_connected(long this_arg, byte[] their_node_id, long msg, boolean inbound);
+ // void ChannelMessageHandler_handle_channel_reestablish LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKChannelReestablish *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_channel_reestablish(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_channel_update LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKChannelUpdate *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_channel_update(long this_arg, byte[] their_node_id, long msg);
+ // void ChannelMessageHandler_handle_error LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKErrorMessage *NONNULL_PTR msg
+ public static native void ChannelMessageHandler_handle_error(long this_arg, byte[] their_node_id, long msg);
+ // LDKNodeFeatures ChannelMessageHandler_provided_node_features LDKChannelMessageHandler *NONNULL_PTR this_arg
+ public static native long ChannelMessageHandler_provided_node_features(long this_arg);
+ // LDKInitFeatures ChannelMessageHandler_provided_init_features LDKChannelMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id
+ public static native long ChannelMessageHandler_provided_init_features(long this_arg, byte[] their_node_id);
+ // LDKCOption_CVec_ThirtyTwoBytesZZ ChannelMessageHandler_get_chain_hashes LDKChannelMessageHandler *NONNULL_PTR this_arg
+ public static native long ChannelMessageHandler_get_chain_hashes(long this_arg);
+ public interface LDKOffersMessageHandler {
+ long handle_message(long message);
+ long[] release_pending_messages();
+ }
+ public static native long LDKOffersMessageHandler_new(LDKOffersMessageHandler impl);
+ // LDKCOption_OffersMessageZ OffersMessageHandler_handle_message LDKOffersMessageHandler *NONNULL_PTR this_arg, struct LDKOffersMessage message
+ public static native long OffersMessageHandler_handle_message(long this_arg, long message);
+ // LDKCVec_C3Tuple_OffersMessageDestinationBlindedPathZZ OffersMessageHandler_release_pending_messages LDKOffersMessageHandler *NONNULL_PTR this_arg
+ public static native long[] OffersMessageHandler_release_pending_messages(long this_arg);
+ public interface LDKRoutingMessageHandler {
+ long handle_node_announcement(long msg);
+ long handle_channel_announcement(long msg);
+ long handle_channel_update(long msg);
+ long get_next_channel_announcement(long starting_point);
+ long get_next_node_announcement(long starting_point);
+ long peer_connected(byte[] their_node_id, long init, boolean inbound);
+ long handle_reply_channel_range(byte[] their_node_id, long msg);
+ long handle_reply_short_channel_ids_end(byte[] their_node_id, long msg);
+ long handle_query_channel_range(byte[] their_node_id, long msg);
+ long handle_query_short_channel_ids(byte[] their_node_id, long msg);
+ boolean processing_queue_high();
+ long provided_node_features();
+ long provided_init_features(byte[] their_node_id);
+ }
+ public static native long LDKRoutingMessageHandler_new(LDKRoutingMessageHandler impl, LDKMessageSendEventsProvider MessageSendEventsProvider);
+ public static native long LDKRoutingMessageHandler_get_MessageSendEventsProvider(long arg);
+ // LDKCResult_boolLightningErrorZ RoutingMessageHandler_handle_node_announcement LDKRoutingMessageHandler *NONNULL_PTR this_arg, const struct LDKNodeAnnouncement *NONNULL_PTR msg
+ public static native long RoutingMessageHandler_handle_node_announcement(long this_arg, long msg);
+ // LDKCResult_boolLightningErrorZ RoutingMessageHandler_handle_channel_announcement LDKRoutingMessageHandler *NONNULL_PTR this_arg, const struct LDKChannelAnnouncement *NONNULL_PTR msg
+ public static native long RoutingMessageHandler_handle_channel_announcement(long this_arg, long msg);
+ // LDKCResult_boolLightningErrorZ RoutingMessageHandler_handle_channel_update LDKRoutingMessageHandler *NONNULL_PTR this_arg, const struct LDKChannelUpdate *NONNULL_PTR msg
+ public static native long RoutingMessageHandler_handle_channel_update(long this_arg, long msg);
+ // LDKCOption_C3Tuple_ChannelAnnouncementChannelUpdateChannelUpdateZZ RoutingMessageHandler_get_next_channel_announcement LDKRoutingMessageHandler *NONNULL_PTR this_arg, uint64_t starting_point
+ public static native long RoutingMessageHandler_get_next_channel_announcement(long this_arg, long starting_point);
+ // LDKNodeAnnouncement RoutingMessageHandler_get_next_node_announcement LDKRoutingMessageHandler *NONNULL_PTR this_arg, struct LDKNodeId starting_point
+ public static native long RoutingMessageHandler_get_next_node_announcement(long this_arg, long starting_point);
+ // LDKCResult_NoneNoneZ RoutingMessageHandler_peer_connected LDKRoutingMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKInit *NONNULL_PTR init, bool inbound
+ public static native long RoutingMessageHandler_peer_connected(long this_arg, byte[] their_node_id, long init, boolean inbound);
+ // LDKCResult_NoneLightningErrorZ RoutingMessageHandler_handle_reply_channel_range LDKRoutingMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, struct LDKReplyChannelRange msg
+ public static native long RoutingMessageHandler_handle_reply_channel_range(long this_arg, byte[] their_node_id, long msg);
+ // LDKCResult_NoneLightningErrorZ RoutingMessageHandler_handle_reply_short_channel_ids_end LDKRoutingMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, struct LDKReplyShortChannelIdsEnd msg
+ public static native long RoutingMessageHandler_handle_reply_short_channel_ids_end(long this_arg, byte[] their_node_id, long msg);
+ // LDKCResult_NoneLightningErrorZ RoutingMessageHandler_handle_query_channel_range LDKRoutingMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, struct LDKQueryChannelRange msg
+ public static native long RoutingMessageHandler_handle_query_channel_range(long this_arg, byte[] their_node_id, long msg);
+ // LDKCResult_NoneLightningErrorZ RoutingMessageHandler_handle_query_short_channel_ids LDKRoutingMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, struct LDKQueryShortChannelIds msg
+ public static native long RoutingMessageHandler_handle_query_short_channel_ids(long this_arg, byte[] their_node_id, long msg);
+ // bool RoutingMessageHandler_processing_queue_high LDKRoutingMessageHandler *NONNULL_PTR this_arg
+ public static native boolean RoutingMessageHandler_processing_queue_high(long this_arg);
+ // LDKNodeFeatures RoutingMessageHandler_provided_node_features LDKRoutingMessageHandler *NONNULL_PTR this_arg
+ public static native long RoutingMessageHandler_provided_node_features(long this_arg);
+ // LDKInitFeatures RoutingMessageHandler_provided_init_features LDKRoutingMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id
+ public static native long RoutingMessageHandler_provided_init_features(long this_arg, byte[] their_node_id);
+ public interface LDKOnionMessageHandler {
+ void handle_onion_message(byte[] peer_node_id, long msg);
+ long next_onion_message_for_peer(byte[] peer_node_id);
+ long peer_connected(byte[] their_node_id, long init, boolean inbound);
+ void peer_disconnected(byte[] their_node_id);
+ long provided_node_features();
+ long provided_init_features(byte[] their_node_id);
+ }
+ public static native long LDKOnionMessageHandler_new(LDKOnionMessageHandler impl);
+ // void OnionMessageHandler_handle_onion_message LDKOnionMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey peer_node_id, const struct LDKOnionMessage *NONNULL_PTR msg
+ public static native void OnionMessageHandler_handle_onion_message(long this_arg, byte[] peer_node_id, long msg);
+ // LDKOnionMessage OnionMessageHandler_next_onion_message_for_peer LDKOnionMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey peer_node_id
+ public static native long OnionMessageHandler_next_onion_message_for_peer(long this_arg, byte[] peer_node_id);
+ // LDKCResult_NoneNoneZ OnionMessageHandler_peer_connected LDKOnionMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id, const struct LDKInit *NONNULL_PTR init, bool inbound
+ public static native long OnionMessageHandler_peer_connected(long this_arg, byte[] their_node_id, long init, boolean inbound);
+ // void OnionMessageHandler_peer_disconnected LDKOnionMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id
+ public static native void OnionMessageHandler_peer_disconnected(long this_arg, byte[] their_node_id);
+ // LDKNodeFeatures OnionMessageHandler_provided_node_features LDKOnionMessageHandler *NONNULL_PTR this_arg
+ public static native long OnionMessageHandler_provided_node_features(long this_arg);
+ // LDKInitFeatures OnionMessageHandler_provided_init_features LDKOnionMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id
+ public static native long OnionMessageHandler_provided_init_features(long this_arg, byte[] their_node_id);
+ public interface LDKCustomMessageReader {
+ long read(short message_type, byte[] buffer);
+ }
+ public static native long LDKCustomMessageReader_new(LDKCustomMessageReader impl);
+ // LDKCResult_COption_TypeZDecodeErrorZ CustomMessageReader_read LDKCustomMessageReader *NONNULL_PTR this_arg, uint16_t message_type, struct LDKu8slice buffer
+ public static native long CustomMessageReader_read(long this_arg, short message_type, byte[] buffer);
+ public interface LDKCustomMessageHandler {
+ long handle_custom_message(long msg, byte[] sender_node_id);
+ long[] get_and_clear_pending_msg();
+ long provided_node_features();
+ long provided_init_features(byte[] their_node_id);
+ }
+ public static native long LDKCustomMessageHandler_new(LDKCustomMessageHandler impl, LDKCustomMessageReader CustomMessageReader);
+ public static native long LDKCustomMessageHandler_get_CustomMessageReader(long arg);
+ // LDKCResult_NoneLightningErrorZ CustomMessageHandler_handle_custom_message LDKCustomMessageHandler *NONNULL_PTR this_arg, struct LDKType msg, struct LDKPublicKey sender_node_id
+ public static native long CustomMessageHandler_handle_custom_message(long this_arg, long msg, byte[] sender_node_id);
+ // LDKCVec_C2Tuple_PublicKeyTypeZZ CustomMessageHandler_get_and_clear_pending_msg LDKCustomMessageHandler *NONNULL_PTR this_arg
+ public static native long[] CustomMessageHandler_get_and_clear_pending_msg(long this_arg);
+ // LDKNodeFeatures CustomMessageHandler_provided_node_features LDKCustomMessageHandler *NONNULL_PTR this_arg
+ public static native long CustomMessageHandler_provided_node_features(long this_arg);
+ // LDKInitFeatures CustomMessageHandler_provided_init_features LDKCustomMessageHandler *NONNULL_PTR this_arg, struct LDKPublicKey their_node_id
+ public static native long CustomMessageHandler_provided_init_features(long this_arg, byte[] their_node_id);
+ public interface LDKCustomOnionMessageHandler {
+ long handle_custom_message(long msg);
+ long read_custom_message(long message_type, byte[] buffer);
+ long[] release_pending_custom_messages();
+ }
+ public static native long LDKCustomOnionMessageHandler_new(LDKCustomOnionMessageHandler impl);
+ // LDKCOption_OnionMessageContentsZ CustomOnionMessageHandler_handle_custom_message LDKCustomOnionMessageHandler *NONNULL_PTR this_arg, struct LDKOnionMessageContents msg
+ public static native long CustomOnionMessageHandler_handle_custom_message(long this_arg, long msg);
+ // LDKCResult_COption_OnionMessageContentsZDecodeErrorZ CustomOnionMessageHandler_read_custom_message LDKCustomOnionMessageHandler *NONNULL_PTR this_arg, uint64_t message_type, struct LDKu8slice buffer
+ public static native long CustomOnionMessageHandler_read_custom_message(long this_arg, long message_type, byte[] buffer);
+ // LDKCVec_C3Tuple_OnionMessageContentsDestinationBlindedPathZZ CustomOnionMessageHandler_release_pending_custom_messages LDKCustomOnionMessageHandler *NONNULL_PTR this_arg
+ public static native long[] CustomOnionMessageHandler_release_pending_custom_messages(long this_arg);
+ public interface LDKSocketDescriptor {
+ long send_data(byte[] data, boolean resume_read);
+ void disconnect_socket();
+ boolean eq(long other_arg);
+ long hash();
+ }
+ public static native long LDKSocketDescriptor_new(LDKSocketDescriptor impl);
+ // uintptr_t SocketDescriptor_send_data LDKSocketDescriptor *NONNULL_PTR this_arg, struct LDKu8slice data, bool resume_read
+ public static native long SocketDescriptor_send_data(long this_arg, byte[] data, boolean resume_read);
+ // void SocketDescriptor_disconnect_socket LDKSocketDescriptor *NONNULL_PTR this_arg
+ public static native void SocketDescriptor_disconnect_socket(long this_arg);
+ // uint64_t SocketDescriptor_hash LDKSocketDescriptor *NONNULL_PTR this_arg
+ public static native long SocketDescriptor_hash(long this_arg);
+ public static class LDKEffectiveCapacity {
+ private LDKEffectiveCapacity() {}
+ public final static class ExactLiquidity extends LDKEffectiveCapacity {
+ public long liquidity_msat;
+ ExactLiquidity(long liquidity_msat) { this.liquidity_msat = liquidity_msat; }
+ }
+ public final static class AdvertisedMaxHTLC extends LDKEffectiveCapacity {
+ public long amount_msat;
+ AdvertisedMaxHTLC(long amount_msat) { this.amount_msat = amount_msat; }
+ }
+ public final static class Total extends LDKEffectiveCapacity {
+ public long capacity_msat;
+ public long htlc_maximum_msat;
+ Total(long capacity_msat, long htlc_maximum_msat) { this.capacity_msat = capacity_msat; this.htlc_maximum_msat = htlc_maximum_msat; }
+ }
+ public final static class Infinite extends LDKEffectiveCapacity {
+ Infinite() { }
+ }
+ public final static class HintMaxHTLC extends LDKEffectiveCapacity {
+ public long amount_msat;
+ HintMaxHTLC(long amount_msat) { this.amount_msat = amount_msat; }
+ }
+ public final static class Unknown extends LDKEffectiveCapacity {
+ Unknown() { }
+ }
+ static native void init();
+ }
+ static { LDKEffectiveCapacity.init(); }
+ public static native LDKEffectiveCapacity LDKEffectiveCapacity_ref_from_ptr(long ptr);
+ public static class LDKPayee {
+ private LDKPayee() {}
+ public final static class Blinded extends LDKPayee {
+ public long[] route_hints;
+ public long features;
+ Blinded(long[] route_hints, long features) { this.route_hints = route_hints; this.features = features; }
+ }
+ public final static class Clear extends LDKPayee {
+ public byte[] node_id;
+ public long[] route_hints;
+ public long features;
+ public int final_cltv_expiry_delta;
+ Clear(byte[] node_id, long[] route_hints, long features, int final_cltv_expiry_delta) { this.node_id = node_id; this.route_hints = route_hints; this.features = features; this.final_cltv_expiry_delta = final_cltv_expiry_delta; }
+ }
+ static native void init();
+ }
+ static { LDKPayee.init(); }
+ public static native LDKPayee LDKPayee_ref_from_ptr(long ptr);
+ public interface LDKScore {
+ byte[] write();
+ }
+ public static native long LDKScore_new(LDKScore impl, LDKScoreLookUp ScoreLookUp, LDKScoreUpdate ScoreUpdate);
+ public static native long LDKScore_get_ScoreLookUp(long arg);
+ public static native long LDKScore_get_ScoreUpdate(long arg);
+ // LDKCVec_u8Z Score_write LDKScore *NONNULL_PTR this_arg
+ public static native byte[] Score_write(long this_arg);
+ public interface LDKMessageRouter {
+ long find_path(byte[] sender, byte[][] peers, long destination);
+ }
+ public static native long LDKMessageRouter_new(LDKMessageRouter impl);
+ // LDKCResult_OnionMessagePathNoneZ MessageRouter_find_path LDKMessageRouter *NONNULL_PTR this_arg, struct LDKPublicKey sender, struct LDKCVec_PublicKeyZ peers, struct LDKDestination destination
+ public static native long MessageRouter_find_path(long this_arg, byte[] sender, byte[][] peers, long destination);
+ public interface LDKCoinSelectionSource {
+ long select_confirmed_utxos(byte[] claim_id, long[] must_spend, long[] must_pay_to, int target_feerate_sat_per_1000_weight);
+ long sign_tx(byte[] tx);
+ }
+ public static native long LDKCoinSelectionSource_new(LDKCoinSelectionSource impl);
+ // LDKCResult_CoinSelectionNoneZ CoinSelectionSource_select_confirmed_utxos LDKCoinSelectionSource *NONNULL_PTR this_arg, struct LDKThirtyTwoBytes claim_id, struct LDKCVec_InputZ must_spend, struct LDKCVec_TxOutZ must_pay_to, uint32_t target_feerate_sat_per_1000_weight
+ public static native long CoinSelectionSource_select_confirmed_utxos(long this_arg, byte[] claim_id, long[] must_spend, long[] must_pay_to, int target_feerate_sat_per_1000_weight);
+ // LDKCResult_TransactionNoneZ CoinSelectionSource_sign_tx LDKCoinSelectionSource *NONNULL_PTR this_arg, struct LDKTransaction tx
+ public static native long CoinSelectionSource_sign_tx(long this_arg, byte[] tx);
+ public interface LDKWalletSource {
+ long list_confirmed_utxos();
+ long get_change_script();
+ long sign_tx(byte[] tx);
+ }
+ public static native long LDKWalletSource_new(LDKWalletSource impl);
+ // LDKCResult_CVec_UtxoZNoneZ WalletSource_list_confirmed_utxos LDKWalletSource *NONNULL_PTR this_arg
+ public static native long WalletSource_list_confirmed_utxos(long this_arg);
+ // LDKCResult_CVec_u8ZNoneZ WalletSource_get_change_script LDKWalletSource *NONNULL_PTR this_arg
+ public static native long WalletSource_get_change_script(long this_arg);
+ // LDKCResult_TransactionNoneZ WalletSource_sign_tx LDKWalletSource *NONNULL_PTR this_arg, struct LDKTransaction tx
+ public static native long WalletSource_sign_tx(long this_arg, byte[] tx);
+ public static class LDKGossipSync {
+ private LDKGossipSync() {}
+ public final static class P2P extends LDKGossipSync {
+ public long p2p;
+ P2P(long p2p) { this.p2p = p2p; }
+ }
+ public final static class Rapid extends LDKGossipSync {
+ public long rapid;
+ Rapid(long rapid) { this.rapid = rapid; }
+ }
+ public final static class None extends LDKGossipSync {
+ None() { }
+ }
+ static native void init();
+ }
+ static { LDKGossipSync.init(); }
+ public static native LDKGossipSync LDKGossipSync_ref_from_ptr(long ptr);
+ public static class LDKFallback {
+ private LDKFallback() {}
+ public final static class SegWitProgram extends LDKFallback {
+ public byte version;
+ public byte[] program;
+ SegWitProgram(byte version, byte[] program) { this.version = version; this.program = program; }
+ }
+ public final static class PubKeyHash extends LDKFallback {
+ public byte[] pub_key_hash;
+ PubKeyHash(byte[] pub_key_hash) { this.pub_key_hash = pub_key_hash; }
+ }
+ public final static class ScriptHash extends LDKFallback {
+ public byte[] script_hash;
+ ScriptHash(byte[] script_hash) { this.script_hash = script_hash; }
+ }
+ static native void init();
+ }
+ static { LDKFallback.init(); }
+ public static native LDKFallback LDKFallback_ref_from_ptr(long ptr);
+ // struct LDKStr _ldk_get_compiled_version(void);
+ public static native String _ldk_get_compiled_version();
+ // struct LDKStr _ldk_c_bindings_get_compiled_version(void);
+ public static native String _ldk_c_bindings_get_compiled_version();
+ // struct LDKSixteenBytes U128_le_bytes(struct LDKU128 val);
+ public static native byte[] U128_le_bytes(byte[] val);
+ // struct LDKU128 U128_new(struct LDKSixteenBytes le_bytes);
+ public static native byte[] U128_new(byte[] le_bytes);
+ // struct LDKBigEndianScalar BigEndianScalar_new(struct LDKThirtyTwoBytes big_endian_bytes);
+ public static native long BigEndianScalar_new(byte[] big_endian_bytes);
+ // uint64_t Bech32Error_clone_ptr(LDKBech32Error *NONNULL_PTR arg);
+ public static native long Bech32Error_clone_ptr(long arg);
+ // struct LDKBech32Error Bech32Error_clone(const struct LDKBech32Error *NONNULL_PTR orig);
+ public static native long Bech32Error_clone(long orig);
+ // void Bech32Error_free(struct LDKBech32Error o);
+ public static native void Bech32Error_free(long o);
+ // void Transaction_free(struct LDKTransaction _res);
+ public static native void Transaction_free(byte[] _res);
+ // void Witness_free(struct LDKWitness _res);
+ public static native void Witness_free(byte[] _res);
+ // void TxIn_free(struct LDKTxIn _res);
+ public static native void TxIn_free(long _res);
+ // struct LDKTxIn TxIn_new(struct LDKWitness witness, struct LDKCVec_u8Z script_sig, uint32_t sequence, struct LDKThirtyTwoBytes previous_txid, uint32_t previous_vout);
+ public static native long TxIn_new(byte[] witness, byte[] script_sig, int sequence, byte[] previous_txid, int previous_vout);
+ // struct LDKTxOut TxOut_new(struct LDKCVec_u8Z script_pubkey, uint64_t value);
+ public static native long TxOut_new(byte[] script_pubkey, long value);
+ // void TxOut_free(struct LDKTxOut _res);
+ public static native void TxOut_free(long _res);
+ // uint64_t TxOut_clone_ptr(LDKTxOut *NONNULL_PTR arg);
+ public static native long TxOut_clone_ptr(long arg);
+ // struct LDKTxOut TxOut_clone(const struct LDKTxOut *NONNULL_PTR orig);
+ public static native long TxOut_clone(long orig);
+ // void Str_free(struct LDKStr _res);
+ public static native void Str_free(String _res);
+ // struct LDKCOption_u64Z COption_u64Z_some(uint64_t o);
+ public static native long COption_u64Z_some(long o);
+ // struct LDKCOption_u64Z COption_u64Z_none(void);
+ public static native long COption_u64Z_none();
+ // void COption_u64Z_free(struct LDKCOption_u64Z _res);
+ public static native void COption_u64Z_free(long _res);
+ // uint64_t COption_u64Z_clone_ptr(LDKCOption_u64Z *NONNULL_PTR arg);
+ public static native long COption_u64Z_clone_ptr(long arg);
+ // struct LDKCOption_u64Z COption_u64Z_clone(const struct LDKCOption_u64Z *NONNULL_PTR orig);
+ public static native long COption_u64Z_clone(long orig);
+ // void CVec_BlindedPathZ_free(struct LDKCVec_BlindedPathZ _res);
+ public static native void CVec_BlindedPathZ_free(long[] _res);
+ // struct LDKCResult_RefundBolt12ParseErrorZ CResult_RefundBolt12ParseErrorZ_ok(struct LDKRefund o);
+ public static native long CResult_RefundBolt12ParseErrorZ_ok(long o);
+ // struct LDKCResult_RefundBolt12ParseErrorZ CResult_RefundBolt12ParseErrorZ_err(struct LDKBolt12ParseError e);
+ public static native long CResult_RefundBolt12ParseErrorZ_err(long e);
+ // bool CResult_RefundBolt12ParseErrorZ_is_ok(const struct LDKCResult_RefundBolt12ParseErrorZ *NONNULL_PTR o);
+ public static native boolean CResult_RefundBolt12ParseErrorZ_is_ok(long o);
+ // void CResult_RefundBolt12ParseErrorZ_free(struct LDKCResult_RefundBolt12ParseErrorZ _res);
+ public static native void CResult_RefundBolt12ParseErrorZ_free(long _res);
+ // uint64_t CResult_RefundBolt12ParseErrorZ_clone_ptr(LDKCResult_RefundBolt12ParseErrorZ *NONNULL_PTR arg);
+ public static native long CResult_RefundBolt12ParseErrorZ_clone_ptr(long arg);
+ // struct LDKCResult_RefundBolt12ParseErrorZ CResult_RefundBolt12ParseErrorZ_clone(const struct LDKCResult_RefundBolt12ParseErrorZ *NONNULL_PTR orig);
+ public static native long CResult_RefundBolt12ParseErrorZ_clone(long orig);
+ // struct LDKCResult_RetryDecodeErrorZ CResult_RetryDecodeErrorZ_ok(struct LDKRetry o);
+ public static native long CResult_RetryDecodeErrorZ_ok(long o);
+ // struct LDKCResult_RetryDecodeErrorZ CResult_RetryDecodeErrorZ_err(struct LDKDecodeError e);
+ public static native long CResult_RetryDecodeErrorZ_err(long e);
+ // bool CResult_RetryDecodeErrorZ_is_ok(const struct LDKCResult_RetryDecodeErrorZ *NONNULL_PTR o);
+ public static native boolean CResult_RetryDecodeErrorZ_is_ok(long o);
+ // void CResult_RetryDecodeErrorZ_free(struct LDKCResult_RetryDecodeErrorZ _res);
+ public static native void CResult_RetryDecodeErrorZ_free(long _res);
+ // uint64_t CResult_RetryDecodeErrorZ_clone_ptr(LDKCResult_RetryDecodeErrorZ *NONNULL_PTR arg);
+ public static native long CResult_RetryDecodeErrorZ_clone_ptr(long arg);
+ // struct LDKCResult_RetryDecodeErrorZ CResult_RetryDecodeErrorZ_clone(const struct LDKCResult_RetryDecodeErrorZ *NONNULL_PTR orig);
+ public static native long CResult_RetryDecodeErrorZ_clone(long orig);
+ // struct LDKCResult_NoneAPIErrorZ CResult_NoneAPIErrorZ_ok(void);
+ public static native long CResult_NoneAPIErrorZ_ok();
+ // struct LDKCResult_NoneAPIErrorZ CResult_NoneAPIErrorZ_err(struct LDKAPIError e);
+ public static native long CResult_NoneAPIErrorZ_err(long e);
+ // bool CResult_NoneAPIErrorZ_is_ok(const struct LDKCResult_NoneAPIErrorZ *NONNULL_PTR o);
+ public static native boolean CResult_NoneAPIErrorZ_is_ok(long o);
+ // void CResult_NoneAPIErrorZ_free(struct LDKCResult_NoneAPIErrorZ _res);
+ public static native void CResult_NoneAPIErrorZ_free(long _res);
+ // uint64_t CResult_NoneAPIErrorZ_clone_ptr(LDKCResult_NoneAPIErrorZ *NONNULL_PTR arg);
+ public static native long CResult_NoneAPIErrorZ_clone_ptr(long arg);
+ // struct LDKCResult_NoneAPIErrorZ CResult_NoneAPIErrorZ_clone(const struct LDKCResult_NoneAPIErrorZ *NONNULL_PTR orig);
+ public static native long CResult_NoneAPIErrorZ_clone(long orig);
+ // void CVec_CResult_NoneAPIErrorZZ_free(struct LDKCVec_CResult_NoneAPIErrorZZ _res);
+ public static native void CVec_CResult_NoneAPIErrorZZ_free(long[] _res);
+ // void CVec_APIErrorZ_free(struct LDKCVec_APIErrorZ _res);
+ public static native void CVec_APIErrorZ_free(long[] _res);
+ // struct LDKCOption_ThirtyTwoBytesZ COption_ThirtyTwoBytesZ_some(struct LDKThirtyTwoBytes o);
+ public static native long COption_ThirtyTwoBytesZ_some(byte[] o);
+ // struct LDKCOption_ThirtyTwoBytesZ COption_ThirtyTwoBytesZ_none(void);
+ public static native long COption_ThirtyTwoBytesZ_none();
+ // void COption_ThirtyTwoBytesZ_free(struct LDKCOption_ThirtyTwoBytesZ _res);
+ public static native void COption_ThirtyTwoBytesZ_free(long _res);
+ // uint64_t COption_ThirtyTwoBytesZ_clone_ptr(LDKCOption_ThirtyTwoBytesZ *NONNULL_PTR arg);
+ public static native long COption_ThirtyTwoBytesZ_clone_ptr(long arg);
+ // struct LDKCOption_ThirtyTwoBytesZ COption_ThirtyTwoBytesZ_clone(const struct LDKCOption_ThirtyTwoBytesZ *NONNULL_PTR orig);
+ public static native long COption_ThirtyTwoBytesZ_clone(long orig);
+ // void CVec_u8Z_free(struct LDKCVec_u8Z _res);
+ public static native void CVec_u8Z_free(byte[] _res);
+ // struct LDKCOption_CVec_u8ZZ COption_CVec_u8ZZ_some(struct LDKCVec_u8Z o);
+ public static native long COption_CVec_u8ZZ_some(byte[] o);
+ // struct LDKCOption_CVec_u8ZZ COption_CVec_u8ZZ_none(void);
+ public static native long COption_CVec_u8ZZ_none();
+ // void COption_CVec_u8ZZ_free(struct LDKCOption_CVec_u8ZZ _res);
+ public static native void COption_CVec_u8ZZ_free(long _res);
+ // uint64_t COption_CVec_u8ZZ_clone_ptr(LDKCOption_CVec_u8ZZ *NONNULL_PTR arg);
+ public static native long COption_CVec_u8ZZ_clone_ptr(long arg);
+ // struct LDKCOption_CVec_u8ZZ COption_CVec_u8ZZ_clone(const struct LDKCOption_CVec_u8ZZ *NONNULL_PTR orig);
+ public static native long COption_CVec_u8ZZ_clone(long orig);
+ // struct LDKCResult_RecipientOnionFieldsDecodeErrorZ CResult_RecipientOnionFieldsDecodeErrorZ_ok(struct LDKRecipientOnionFields o);
+ public static native long CResult_RecipientOnionFieldsDecodeErrorZ_ok(long o);
+ // struct LDKCResult_RecipientOnionFieldsDecodeErrorZ CResult_RecipientOnionFieldsDecodeErrorZ_err(struct LDKDecodeError e);
+ public static native long CResult_RecipientOnionFieldsDecodeErrorZ_err(long e);
+ // bool CResult_RecipientOnionFieldsDecodeErrorZ_is_ok(const struct LDKCResult_RecipientOnionFieldsDecodeErrorZ *NONNULL_PTR o);
+ public static native boolean CResult_RecipientOnionFieldsDecodeErrorZ_is_ok(long o);
+ // void CResult_RecipientOnionFieldsDecodeErrorZ_free(struct LDKCResult_RecipientOnionFieldsDecodeErrorZ _res);
+ public static native void CResult_RecipientOnionFieldsDecodeErrorZ_free(long _res);
+ // uint64_t CResult_RecipientOnionFieldsDecodeErrorZ_clone_ptr(LDKCResult_RecipientOnionFieldsDecodeErrorZ *NONNULL_PTR arg);
+ public static native long CResult_RecipientOnionFieldsDecodeErrorZ_clone_ptr(long arg);
+ // struct LDKCResult_RecipientOnionFieldsDecodeErrorZ CResult_RecipientOnionFieldsDecodeErrorZ_clone(const struct LDKCResult_RecipientOnionFieldsDecodeErrorZ *NONNULL_PTR orig);
+ public static native long CResult_RecipientOnionFieldsDecodeErrorZ_clone(long orig);
+ // uint64_t C2Tuple_u64CVec_u8ZZ_clone_ptr(LDKC2Tuple_u64CVec_u8ZZ *NONNULL_PTR arg);
+ public static native long C2Tuple_u64CVec_u8ZZ_clone_ptr(long arg);
+ // struct LDKC2Tuple_u64CVec_u8ZZ C2Tuple_u64CVec_u8ZZ_clone(const struct LDKC2Tuple_u64CVec_u8ZZ *NONNULL_PTR orig);
+ public static native long C2Tuple_u64CVec_u8ZZ_clone(long orig);
+ // struct LDKC2Tuple_u64CVec_u8ZZ C2Tuple_u64CVec_u8ZZ_new(uint64_t a, struct LDKCVec_u8Z b);
+ public static native long C2Tuple_u64CVec_u8ZZ_new(long a, byte[] b);
+ // void C2Tuple_u64CVec_u8ZZ_free(struct LDKC2Tuple_u64CVec_u8ZZ _res);
+ public static native void C2Tuple_u64CVec_u8ZZ_free(long _res);
+ // void CVec_C2Tuple_u64CVec_u8ZZZ_free(struct LDKCVec_C2Tuple_u64CVec_u8ZZZ _res);
+ public static native void CVec_C2Tuple_u64CVec_u8ZZZ_free(long[] _res);
+ // struct LDKCResult_RecipientOnionFieldsNoneZ CResult_RecipientOnionFieldsNoneZ_ok(struct LDKRecipientOnionFields o);
+ public static native long CResult_RecipientOnionFieldsNoneZ_ok(long o);
+ // struct LDKCResult_RecipientOnionFieldsNoneZ CResult_RecipientOnionFieldsNoneZ_err(void);
+ public static native long CResult_RecipientOnionFieldsNoneZ_err();
+ // bool CResult_RecipientOnionFieldsNoneZ_is_ok(const struct LDKCResult_RecipientOnionFieldsNoneZ *NONNULL_PTR o);
+ public static native boolean CResult_RecipientOnionFieldsNoneZ_is_ok(long o);
+ // void CResult_RecipientOnionFieldsNoneZ_free(struct LDKCResult_RecipientOnionFieldsNoneZ _res);
+ public static native void CResult_RecipientOnionFieldsNoneZ_free(long _res);
+ // uint64_t CResult_RecipientOnionFieldsNoneZ_clone_ptr(LDKCResult_RecipientOnionFieldsNoneZ *NONNULL_PTR arg);
+ public static native long CResult_RecipientOnionFieldsNoneZ_clone_ptr(long arg);
+ // struct LDKCResult_RecipientOnionFieldsNoneZ CResult_RecipientOnionFieldsNoneZ_clone(const struct LDKCResult_RecipientOnionFieldsNoneZ *NONNULL_PTR orig);
+ public static native long CResult_RecipientOnionFieldsNoneZ_clone(long orig);
+ // void CVec_ThirtyTwoBytesZ_free(struct LDKCVec_ThirtyTwoBytesZ _res);
+ public static native void CVec_ThirtyTwoBytesZ_free(byte[][] _res);
+ // struct LDKCOption_CVec_ThirtyTwoBytesZZ COption_CVec_ThirtyTwoBytesZZ_some(struct LDKCVec_ThirtyTwoBytesZ o);
+ public static native long COption_CVec_ThirtyTwoBytesZZ_some(byte[][] o);
+ // struct LDKCOption_CVec_ThirtyTwoBytesZZ COption_CVec_ThirtyTwoBytesZZ_none(void);
+ public static native long COption_CVec_ThirtyTwoBytesZZ_none();
+ // void COption_CVec_ThirtyTwoBytesZZ_free(struct LDKCOption_CVec_ThirtyTwoBytesZZ _res);
+ public static native void COption_CVec_ThirtyTwoBytesZZ_free(long _res);
+ // uint64_t COption_CVec_ThirtyTwoBytesZZ_clone_ptr(LDKCOption_CVec_ThirtyTwoBytesZZ *NONNULL_PTR arg);
+ public static native long COption_CVec_ThirtyTwoBytesZZ_clone_ptr(long arg);
+ // struct LDKCOption_CVec_ThirtyTwoBytesZZ COption_CVec_ThirtyTwoBytesZZ_clone(const struct LDKCOption_CVec_ThirtyTwoBytesZZ *NONNULL_PTR orig);
+ public static native long COption_CVec_ThirtyTwoBytesZZ_clone(long orig);
+ // struct LDKCResult_ThirtyTwoBytesNoneZ CResult_ThirtyTwoBytesNoneZ_ok(struct LDKThirtyTwoBytes o);
+ public static native long CResult_ThirtyTwoBytesNoneZ_ok(byte[] o);
+ // struct LDKCResult_ThirtyTwoBytesNoneZ CResult_ThirtyTwoBytesNoneZ_err(void);
+ public static native long CResult_ThirtyTwoBytesNoneZ_err();
+ // bool CResult_ThirtyTwoBytesNoneZ_is_ok(const struct LDKCResult_ThirtyTwoBytesNoneZ *NONNULL_PTR o);
+ public static native boolean CResult_ThirtyTwoBytesNoneZ_is_ok(long o);
+ // void CResult_ThirtyTwoBytesNoneZ_free(struct LDKCResult_ThirtyTwoBytesNoneZ _res);
+ public static native void CResult_ThirtyTwoBytesNoneZ_free(long _res);
+ // uint64_t CResult_ThirtyTwoBytesNoneZ_clone_ptr(LDKCResult_ThirtyTwoBytesNoneZ *NONNULL_PTR arg);
+ public static native long CResult_ThirtyTwoBytesNoneZ_clone_ptr(long arg);
+ // struct LDKCResult_ThirtyTwoBytesNoneZ CResult_ThirtyTwoBytesNoneZ_clone(const struct LDKCResult_ThirtyTwoBytesNoneZ *NONNULL_PTR orig);
+ public static native long CResult_ThirtyTwoBytesNoneZ_clone(long orig);