+ * Validate the counterparty's signatures on the holder commitment transaction and HTLCs.
+ *
+ * This is required in order for the signer to make sure that releasing a commitment
+ * secret won't leave us without a broadcastable holder transaction.
+ * Policy checks should be implemented in this function, including checking the amount
+ * sent to us and checking the HTLCs.
+ *
+ * The preimages of outgoing HTLCs that were fulfilled since the last commitment are provided.
+ * A validating signer should ensure that an HTLC output is removed only when the matching
+ * preimage is provided, or when the value to holder is restored.
+ *
+ * Note that all the relevant preimages will be provided, but there may also be additional
+ * irrelevant or duplicate preimages.
+ */
+ inline LDK::CResult_NoneNoneZ validate_holder_commitment(const struct LDKHolderCommitmentTransaction *NONNULL_PTR holder_tx, struct LDKCVec_PaymentPreimageZ preimages);
+ /**
+ * Returns an arbitrary identifier describing the set of keys which are provided back to you in
+ * some [`SpendableOutputDescriptor`] types. This should be sufficient to identify this
+ * [`EcdsaChannelSigner`] object uniquely and lookup or re-derive its keys.
+ */
+ inline LDKThirtyTwoBytes channel_keys_id();
+ /**
+ * Set the counterparty static channel data, including basepoints,
+ * `counterparty_selected`/`holder_selected_contest_delay` and funding outpoint.
+ *
+ * This data is static, and will never change for a channel once set. For a given [`ChannelSigner`]
+ * instance, LDK will call this method exactly once - either immediately after construction
+ * (not including if done via [`SignerProvider::read_chan_signer`]) or when the funding
+ * information has been generated.
+ *
+ * channel_parameters.is_populated() MUST be true.
+ */
+ inline void provide_channel_parameters(const struct LDKChannelTransactionParameters *NONNULL_PTR channel_parameters);
+};
+class EcdsaChannelSigner {
+private:
+ LDKEcdsaChannelSigner self;
+public:
+ EcdsaChannelSigner(const EcdsaChannelSigner&) = delete;
+ EcdsaChannelSigner(EcdsaChannelSigner&& o) : self(o.self) { memset(&o, 0, sizeof(EcdsaChannelSigner)); }
+ EcdsaChannelSigner(LDKEcdsaChannelSigner&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKEcdsaChannelSigner)); }
+ operator LDKEcdsaChannelSigner() && { LDKEcdsaChannelSigner res = self; memset(&self, 0, sizeof(LDKEcdsaChannelSigner)); return res; }
+ ~EcdsaChannelSigner() { EcdsaChannelSigner_free(self); }
+ EcdsaChannelSigner& operator=(EcdsaChannelSigner&& o) { EcdsaChannelSigner_free(self); self = o.self; memset(&o, 0, sizeof(EcdsaChannelSigner)); return *this; }
+ LDKEcdsaChannelSigner* operator &() { return &self; }
+ LDKEcdsaChannelSigner* operator ->() { return &self; }
+ const LDKEcdsaChannelSigner* operator &() const { return &self; }
+ const LDKEcdsaChannelSigner* operator ->() const { return &self; }
+ /**
+ * Create a signature for a counterparty's commitment transaction and associated HTLC transactions.
+ *
+ * Note that if signing fails or is rejected, the channel will be force-closed.
+ *
+ * Policy checks should be implemented in this function, including checking the amount
+ * sent to us and checking the HTLCs.
+ *
+ * The preimages of outgoing HTLCs that were fulfilled since the last commitment are provided.
+ * A validating signer should ensure that an HTLC output is removed only when the matching
+ * preimage is provided, or when the value to holder is restored.
+ *
+ * Note that all the relevant preimages will be provided, but there may also be additional
+ * irrelevant or duplicate preimages.
+ */
+ inline LDK::CResult_C2Tuple_SignatureCVec_SignatureZZNoneZ sign_counterparty_commitment(const struct LDKCommitmentTransaction *NONNULL_PTR commitment_tx, struct LDKCVec_PaymentPreimageZ preimages);
+ /**
+ * Validate the counterparty's revocation.
+ *
+ * This is required in order for the signer to make sure that the state has moved
+ * forward and it is safe to sign the next counterparty commitment.
+ */
+ inline LDK::CResult_NoneNoneZ validate_counterparty_revocation(uint64_t idx, const uint8_t (*secret)[32]);
+ /**
+ * Creates a signature for a holder's commitment transaction and its claiming HTLC transactions.
+ *
+ * This will be called
+ * - with a non-revoked `commitment_tx`.
+ * - with the latest `commitment_tx` when we initiate a force-close.
+ * - with the previous `commitment_tx`, just to get claiming HTLC
+ * signatures, if we are reacting to a [`ChannelMonitor`]
+ * [replica](https://github.com/lightningdevkit/rust-lightning/blob/main/GLOSSARY.md#monitor-replicas)
+ * that decided to broadcast before it had been updated to the latest `commitment_tx`.
+ *
+ * This may be called multiple times for the same transaction.
+ *
+ * An external signer implementation should check that the commitment has not been revoked.
+ *
+ * [`ChannelMonitor`]: crate::chain::channelmonitor::ChannelMonitor
+ */
+ inline LDK::CResult_C2Tuple_SignatureCVec_SignatureZZNoneZ sign_holder_commitment_and_htlcs(const struct LDKHolderCommitmentTransaction *NONNULL_PTR commitment_tx);
+ /**
+ * Create a signature for the given input in a transaction spending an HTLC transaction output
+ * or a commitment transaction `to_local` output when our counterparty broadcasts an old state.
+ *
+ * A justice transaction may claim multiple outputs at the same time if timelocks are
+ * similar, but only a signature for the input at index `input` should be signed for here.
+ * It may be called multiple times for same output(s) if a fee-bump is needed with regards
+ * to an upcoming timelock expiration.
+ *
+ * Amount is value of the output spent by this input, committed to in the BIP 143 signature.
+ *
+ * `per_commitment_key` is revocation secret which was provided by our counterparty when they
+ * revoked the state which they eventually broadcast. It's not a _holder_ secret key and does
+ * not allow the spending of any funds by itself (you need our holder `revocation_secret` to do
+ * so).
+ */
+ inline LDK::CResult_SignatureNoneZ sign_justice_revoked_output(struct LDKTransaction justice_tx, uintptr_t input, uint64_t amount, const uint8_t (*per_commitment_key)[32]);
+ /**
+ * Create a signature for the given input in a transaction spending a commitment transaction
+ * HTLC output when our counterparty broadcasts an old state.
+ *
+ * A justice transaction may claim multiple outputs at the same time if timelocks are
+ * similar, but only a signature for the input at index `input` should be signed for here.
+ * It may be called multiple times for same output(s) if a fee-bump is needed with regards
+ * to an upcoming timelock expiration.
+ *
+ * `amount` is the value of the output spent by this input, committed to in the BIP 143
+ * signature.
+ *
+ * `per_commitment_key` is revocation secret which was provided by our counterparty when they
+ * revoked the state which they eventually broadcast. It's not a _holder_ secret key and does
+ * not allow the spending of any funds by itself (you need our holder revocation_secret to do
+ * so).
+ *
+ * `htlc` holds HTLC elements (hash, timelock), thus changing the format of the witness script
+ * (which is committed to in the BIP 143 signatures).
+ */
+ inline LDK::CResult_SignatureNoneZ sign_justice_revoked_htlc(struct LDKTransaction justice_tx, uintptr_t input, uint64_t amount, const uint8_t (*per_commitment_key)[32], const struct LDKHTLCOutputInCommitment *NONNULL_PTR htlc);
+ /**
+ * Create a signature for a claiming transaction for a HTLC output on a counterparty's commitment
+ * transaction, either offered or received.
+ *
+ * Such a transaction may claim multiples offered outputs at same time if we know the
+ * preimage for each when we create it, but only the input at index `input` should be
+ * signed for here. It may be called multiple times for same output(s) if a fee-bump is
+ * needed with regards to an upcoming timelock expiration.
+ *
+ * `witness_script` is either an offered or received script as defined in BOLT3 for HTLC
+ * outputs.
+ *
+ * `amount` is value of the output spent by this input, committed to in the BIP 143 signature.
+ *
+ * `per_commitment_point` is the dynamic point corresponding to the channel state
+ * detected onchain. It has been generated by our counterparty and is used to derive
+ * channel state keys, which are then included in the witness script and committed to in the
+ * BIP 143 signature.
+ */
+ inline LDK::CResult_SignatureNoneZ sign_counterparty_htlc_transaction(struct LDKTransaction htlc_tx, uintptr_t input, uint64_t amount, struct LDKPublicKey per_commitment_point, const struct LDKHTLCOutputInCommitment *NONNULL_PTR htlc);
+ /**
+ * Create a signature for a (proposed) closing transaction.
+ *
+ * Note that, due to rounding, there may be one "missing" satoshi, and either party may have
+ * chosen to forgo their output as dust.
+ */
+ inline LDK::CResult_SignatureNoneZ sign_closing_transaction(const struct LDKClosingTransaction *NONNULL_PTR closing_tx);
+ /**
+ * Computes the signature for a commitment transaction's anchor output used as an
+ * input within `anchor_tx`, which spends the commitment transaction, at index `input`.
+ */
+ inline LDK::CResult_SignatureNoneZ sign_holder_anchor_input(struct LDKTransaction anchor_tx, uintptr_t input);
+ /**
+ * Signs a channel announcement message with our funding key proving it comes from one of the
+ * channel participants.
+ *
+ * Channel announcements also require a signature from each node's network key. Our node
+ * signature is computed through [`NodeSigner::sign_gossip_message`].
+ *
+ * Note that if this fails or is rejected, the channel will not be publicly announced and
+ * our counterparty may (though likely will not) close the channel on us for violating the
+ * protocol.
+ */
+ inline LDK::CResult_SignatureNoneZ sign_channel_announcement_with_funding_key(const struct LDKUnsignedChannelAnnouncement *NONNULL_PTR msg);
+};
+class WriteableEcdsaChannelSigner {
+private:
+ LDKWriteableEcdsaChannelSigner self;
+public:
+ WriteableEcdsaChannelSigner(const WriteableEcdsaChannelSigner&) = delete;
+ WriteableEcdsaChannelSigner(WriteableEcdsaChannelSigner&& o) : self(o.self) { memset(&o, 0, sizeof(WriteableEcdsaChannelSigner)); }
+ WriteableEcdsaChannelSigner(LDKWriteableEcdsaChannelSigner&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKWriteableEcdsaChannelSigner)); }
+ operator LDKWriteableEcdsaChannelSigner() && { LDKWriteableEcdsaChannelSigner res = self; memset(&self, 0, sizeof(LDKWriteableEcdsaChannelSigner)); return res; }
+ ~WriteableEcdsaChannelSigner() { WriteableEcdsaChannelSigner_free(self); }
+ WriteableEcdsaChannelSigner& operator=(WriteableEcdsaChannelSigner&& o) { WriteableEcdsaChannelSigner_free(self); self = o.self; memset(&o, 0, sizeof(WriteableEcdsaChannelSigner)); return *this; }
+ LDKWriteableEcdsaChannelSigner* operator &() { return &self; }
+ LDKWriteableEcdsaChannelSigner* operator ->() { return &self; }
+ const LDKWriteableEcdsaChannelSigner* operator &() const { return &self; }
+ const LDKWriteableEcdsaChannelSigner* operator ->() const { return &self; }
+};
+class Recipient {
+private:
+ LDKRecipient self;
+public:
+ Recipient(const Recipient&) = delete;
+ Recipient(Recipient&& o) : self(o.self) { memset(&o, 0, sizeof(Recipient)); }
+ Recipient(LDKRecipient&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKRecipient)); }
+ operator LDKRecipient() && { LDKRecipient res = self; memset(&self, 0, sizeof(LDKRecipient)); return res; }
+ Recipient& operator=(Recipient&& o) { self = o.self; memset(&o, 0, sizeof(Recipient)); return *this; }
+ LDKRecipient* operator &() { return &self; }
+ LDKRecipient* operator ->() { return &self; }
+ const LDKRecipient* operator &() const { return &self; }
+ const LDKRecipient* operator ->() const { return &self; }
+};
+class EntropySource {
+private:
+ LDKEntropySource self;
+public:
+ EntropySource(const EntropySource&) = delete;
+ EntropySource(EntropySource&& o) : self(o.self) { memset(&o, 0, sizeof(EntropySource)); }
+ EntropySource(LDKEntropySource&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKEntropySource)); }
+ operator LDKEntropySource() && { LDKEntropySource res = self; memset(&self, 0, sizeof(LDKEntropySource)); return res; }
+ ~EntropySource() { EntropySource_free(self); }
+ EntropySource& operator=(EntropySource&& o) { EntropySource_free(self); self = o.self; memset(&o, 0, sizeof(EntropySource)); return *this; }
+ LDKEntropySource* operator &() { return &self; }
+ LDKEntropySource* operator ->() { return &self; }
+ const LDKEntropySource* operator &() const { return &self; }
+ const LDKEntropySource* operator ->() const { return &self; }
+ /**
+ * Gets a unique, cryptographically-secure, random 32-byte value. This method must return a
+ * different value each time it is called.
+ */
+ inline LDKThirtyTwoBytes get_secure_random_bytes();
+};
+class NodeSigner {
+private:
+ LDKNodeSigner self;
+public:
+ NodeSigner(const NodeSigner&) = delete;
+ NodeSigner(NodeSigner&& o) : self(o.self) { memset(&o, 0, sizeof(NodeSigner)); }
+ NodeSigner(LDKNodeSigner&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKNodeSigner)); }
+ operator LDKNodeSigner() && { LDKNodeSigner res = self; memset(&self, 0, sizeof(LDKNodeSigner)); return res; }
+ ~NodeSigner() { NodeSigner_free(self); }
+ NodeSigner& operator=(NodeSigner&& o) { NodeSigner_free(self); self = o.self; memset(&o, 0, sizeof(NodeSigner)); return *this; }
+ LDKNodeSigner* operator &() { return &self; }
+ LDKNodeSigner* operator ->() { return &self; }
+ const LDKNodeSigner* operator &() const { return &self; }
+ const LDKNodeSigner* operator ->() const { return &self; }
+ /**
+ * Get secret key material as bytes for use in encrypting and decrypting inbound payment data.
+ *
+ * If the implementor of this trait supports [phantom node payments], then every node that is
+ * intended to be included in the phantom invoice route hints must return the same value from
+ * this method.
+ *
+ * This method must return the same value each time it is called.
+ *
+ * [phantom node payments]: PhantomKeysManager
+ */
+ inline LDKThirtyTwoBytes get_inbound_payment_key_material();
+ /**
+ * Get node id based on the provided [`Recipient`].
+ *
+ * This method must return the same value each time it is called with a given [`Recipient`]
+ * parameter.
+ *
+ * Errors if the [`Recipient`] variant is not supported by the implementation.
+ */
+ inline LDK::CResult_PublicKeyNoneZ get_node_id(enum LDKRecipient recipient);
+ /**
+ * Gets the ECDH shared secret of our node secret and `other_key`, multiplying by `tweak` if
+ * one is provided. Note that this tweak can be applied to `other_key` instead of our node
+ * secret, though this is less efficient.
+ *
+ * Note that if this fails while attempting to forward an HTLC, LDK will panic. The error
+ * should be resolved to allow LDK to resume forwarding HTLCs.
+ *
+ * Errors if the [`Recipient`] variant is not supported by the implementation.
+ */
+ inline LDK::CResult_SharedSecretNoneZ ecdh(enum LDKRecipient recipient, struct LDKPublicKey other_key, struct LDKCOption_ScalarZ tweak);
+ /**
+ * Sign an invoice.
+ *
+ * By parameterizing by the raw invoice bytes instead of the hash, we allow implementors of
+ * this trait to parse the invoice and make sure they're signing what they expect, rather than
+ * blindly signing the hash.
+ *
+ * The `hrp_bytes` are ASCII bytes, while the `invoice_data` is base32.
+ *
+ * The secret key used to sign the invoice is dependent on the [`Recipient`].
+ *
+ * Errors if the [`Recipient`] variant is not supported by the implementation.
+ */
+ inline LDK::CResult_RecoverableSignatureNoneZ sign_invoice(struct LDKu8slice hrp_bytes, struct LDKCVec_U5Z invoice_data, enum LDKRecipient recipient);
+ /**
+ * Sign a gossip message.
+ *
+ * Note that if this fails, LDK may panic and the message will not be broadcast to the network
+ * or a possible channel counterparty. If LDK panics, the error should be resolved to allow the
+ * message to be broadcast, as otherwise it may prevent one from receiving funds over the
+ * corresponding channel.
+ */
+ inline LDK::CResult_SignatureNoneZ sign_gossip_message(struct LDKUnsignedGossipMessage msg);
+};
+class SignerProvider {
+private:
+ LDKSignerProvider self;
+public:
+ SignerProvider(const SignerProvider&) = delete;
+ SignerProvider(SignerProvider&& o) : self(o.self) { memset(&o, 0, sizeof(SignerProvider)); }
+ SignerProvider(LDKSignerProvider&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKSignerProvider)); }
+ operator LDKSignerProvider() && { LDKSignerProvider res = self; memset(&self, 0, sizeof(LDKSignerProvider)); return res; }
+ ~SignerProvider() { SignerProvider_free(self); }
+ SignerProvider& operator=(SignerProvider&& o) { SignerProvider_free(self); self = o.self; memset(&o, 0, sizeof(SignerProvider)); return *this; }
+ LDKSignerProvider* operator &() { return &self; }
+ LDKSignerProvider* operator ->() { return &self; }
+ const LDKSignerProvider* operator &() const { return &self; }
+ const LDKSignerProvider* operator ->() const { return &self; }
+ /**
+ * Generates a unique `channel_keys_id` that can be used to obtain a [`Self::Signer`] through
+ * [`SignerProvider::derive_channel_signer`]. The `user_channel_id` is provided to allow
+ * implementations of [`SignerProvider`] to maintain a mapping between itself and the generated
+ * `channel_keys_id`.
+ *
+ * This method must return a different value each time it is called.
+ */
+ inline LDKThirtyTwoBytes generate_channel_keys_id(bool inbound, uint64_t channel_value_satoshis, struct LDKU128 user_channel_id);
+ /**
+ * Derives the private key material backing a `Signer`.
+ *
+ * To derive a new `Signer`, a fresh `channel_keys_id` should be obtained through
+ * [`SignerProvider::generate_channel_keys_id`]. Otherwise, an existing `Signer` can be
+ * re-derived from its `channel_keys_id`, which can be obtained through its trait method
+ * [`ChannelSigner::channel_keys_id`].
+ */
+ inline LDK::WriteableEcdsaChannelSigner derive_channel_signer(uint64_t channel_value_satoshis, struct LDKThirtyTwoBytes channel_keys_id);
+ /**
+ * Reads a [`Signer`] for this [`SignerProvider`] from the given input stream.
+ * This is only called during deserialization of other objects which contain
+ * [`WriteableEcdsaChannelSigner`]-implementing objects (i.e., [`ChannelMonitor`]s and [`ChannelManager`]s).
+ * The bytes are exactly those which `<Self::Signer as Writeable>::write()` writes, and
+ * contain no versioning scheme. You may wish to include your own version prefix and ensure
+ * you've read all of the provided bytes to ensure no corruption occurred.
+ *
+ * This method is slowly being phased out -- it will only be called when reading objects
+ * written by LDK versions prior to 0.0.113.
+ *
+ * [`Signer`]: Self::Signer
+ * [`ChannelMonitor`]: crate::chain::channelmonitor::ChannelMonitor
+ * [`ChannelManager`]: crate::ln::channelmanager::ChannelManager
+ */
+ inline LDK::CResult_WriteableEcdsaChannelSignerDecodeErrorZ read_chan_signer(struct LDKu8slice reader);
+ /**
+ * Get a script pubkey which we send funds to when claiming on-chain contestable outputs.
+ *
+ * This method should return a different value each time it is called, to avoid linking
+ * on-chain funds across channels as controlled to the same user.
+ */
+ inline LDK::CVec_u8Z get_destination_script();
+ /**
+ * Get a script pubkey which we will send funds to when closing a channel.
+ *
+ * This method should return a different value each time it is called, to avoid linking
+ * on-chain funds across channels as controlled to the same user.
+ */
+ inline LDK::ShutdownScript get_shutdown_scriptpubkey();
+};
+class InMemorySigner {
+private:
+ LDKInMemorySigner self;
+public:
+ InMemorySigner(const InMemorySigner&) = delete;
+ InMemorySigner(InMemorySigner&& o) : self(o.self) { memset(&o, 0, sizeof(InMemorySigner)); }
+ InMemorySigner(LDKInMemorySigner&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKInMemorySigner)); }
+ operator LDKInMemorySigner() && { LDKInMemorySigner res = self; memset(&self, 0, sizeof(LDKInMemorySigner)); return res; }
+ ~InMemorySigner() { InMemorySigner_free(self); }
+ InMemorySigner& operator=(InMemorySigner&& o) { InMemorySigner_free(self); self = o.self; memset(&o, 0, sizeof(InMemorySigner)); return *this; }
+ LDKInMemorySigner* operator &() { return &self; }
+ LDKInMemorySigner* operator ->() { return &self; }
+ const LDKInMemorySigner* operator &() const { return &self; }
+ const LDKInMemorySigner* operator ->() const { return &self; }
+};
+class KeysManager {
+private:
+ LDKKeysManager self;
+public:
+ KeysManager(const KeysManager&) = delete;
+ KeysManager(KeysManager&& o) : self(o.self) { memset(&o, 0, sizeof(KeysManager)); }
+ KeysManager(LDKKeysManager&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKKeysManager)); }
+ operator LDKKeysManager() && { LDKKeysManager res = self; memset(&self, 0, sizeof(LDKKeysManager)); return res; }
+ ~KeysManager() { KeysManager_free(self); }
+ KeysManager& operator=(KeysManager&& o) { KeysManager_free(self); self = o.self; memset(&o, 0, sizeof(KeysManager)); return *this; }
+ LDKKeysManager* operator &() { return &self; }
+ LDKKeysManager* operator ->() { return &self; }
+ const LDKKeysManager* operator &() const { return &self; }
+ const LDKKeysManager* operator ->() const { return &self; }
+};
+class PhantomKeysManager {
+private:
+ LDKPhantomKeysManager self;
+public:
+ PhantomKeysManager(const PhantomKeysManager&) = delete;
+ PhantomKeysManager(PhantomKeysManager&& o) : self(o.self) { memset(&o, 0, sizeof(PhantomKeysManager)); }
+ PhantomKeysManager(LDKPhantomKeysManager&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPhantomKeysManager)); }
+ operator LDKPhantomKeysManager() && { LDKPhantomKeysManager res = self; memset(&self, 0, sizeof(LDKPhantomKeysManager)); return res; }
+ ~PhantomKeysManager() { PhantomKeysManager_free(self); }
+ PhantomKeysManager& operator=(PhantomKeysManager&& o) { PhantomKeysManager_free(self); self = o.self; memset(&o, 0, sizeof(PhantomKeysManager)); return *this; }
+ LDKPhantomKeysManager* operator &() { return &self; }
+ LDKPhantomKeysManager* operator ->() { return &self; }
+ const LDKPhantomKeysManager* operator &() const { return &self; }
+ const LDKPhantomKeysManager* operator ->() const { return &self; }
+};
+class FilesystemPersister {
+private:
+ LDKFilesystemPersister self;
+public:
+ FilesystemPersister(const FilesystemPersister&) = delete;
+ FilesystemPersister(FilesystemPersister&& o) : self(o.self) { memset(&o, 0, sizeof(FilesystemPersister)); }
+ FilesystemPersister(LDKFilesystemPersister&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKFilesystemPersister)); }
+ operator LDKFilesystemPersister() && { LDKFilesystemPersister res = self; memset(&self, 0, sizeof(LDKFilesystemPersister)); return res; }
+ ~FilesystemPersister() { FilesystemPersister_free(self); }
+ FilesystemPersister& operator=(FilesystemPersister&& o) { FilesystemPersister_free(self); self = o.self; memset(&o, 0, sizeof(FilesystemPersister)); return *this; }
+ LDKFilesystemPersister* operator &() { return &self; }
+ LDKFilesystemPersister* operator ->() { return &self; }
+ const LDKFilesystemPersister* operator &() const { return &self; }
+ const LDKFilesystemPersister* operator ->() const { return &self; }
+};
+class FailureCode {
+private:
+ LDKFailureCode self;
+public:
+ FailureCode(const FailureCode&) = delete;
+ FailureCode(FailureCode&& o) : self(o.self) { memset(&o, 0, sizeof(FailureCode)); }
+ FailureCode(LDKFailureCode&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKFailureCode)); }
+ operator LDKFailureCode() && { LDKFailureCode res = self; memset(&self, 0, sizeof(LDKFailureCode)); return res; }
+ FailureCode& operator=(FailureCode&& o) { self = o.self; memset(&o, 0, sizeof(FailureCode)); return *this; }
+ LDKFailureCode* operator &() { return &self; }
+ LDKFailureCode* operator ->() { return &self; }
+ const LDKFailureCode* operator &() const { return &self; }
+ const LDKFailureCode* operator ->() const { return &self; }
+};
+class ChannelManager {
+private:
+ LDKChannelManager self;
+public:
+ ChannelManager(const ChannelManager&) = delete;
+ ChannelManager(ChannelManager&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelManager)); }
+ ChannelManager(LDKChannelManager&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelManager)); }
+ operator LDKChannelManager() && { LDKChannelManager res = self; memset(&self, 0, sizeof(LDKChannelManager)); return res; }
+ ~ChannelManager() { ChannelManager_free(self); }
+ ChannelManager& operator=(ChannelManager&& o) { ChannelManager_free(self); self = o.self; memset(&o, 0, sizeof(ChannelManager)); return *this; }
+ LDKChannelManager* operator &() { return &self; }
+ LDKChannelManager* operator ->() { return &self; }
+ const LDKChannelManager* operator &() const { return &self; }
+ const LDKChannelManager* operator ->() const { return &self; }
+};
+class ChainParameters {
+private:
+ LDKChainParameters self;
+public:
+ ChainParameters(const ChainParameters&) = delete;
+ ChainParameters(ChainParameters&& o) : self(o.self) { memset(&o, 0, sizeof(ChainParameters)); }
+ ChainParameters(LDKChainParameters&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChainParameters)); }
+ operator LDKChainParameters() && { LDKChainParameters res = self; memset(&self, 0, sizeof(LDKChainParameters)); return res; }
+ ~ChainParameters() { ChainParameters_free(self); }
+ ChainParameters& operator=(ChainParameters&& o) { ChainParameters_free(self); self = o.self; memset(&o, 0, sizeof(ChainParameters)); return *this; }
+ LDKChainParameters* operator &() { return &self; }
+ LDKChainParameters* operator ->() { return &self; }
+ const LDKChainParameters* operator &() const { return &self; }
+ const LDKChainParameters* operator ->() const { return &self; }
+};
+class CounterpartyForwardingInfo {
+private:
+ LDKCounterpartyForwardingInfo self;
+public:
+ CounterpartyForwardingInfo(const CounterpartyForwardingInfo&) = delete;
+ CounterpartyForwardingInfo(CounterpartyForwardingInfo&& o) : self(o.self) { memset(&o, 0, sizeof(CounterpartyForwardingInfo)); }
+ CounterpartyForwardingInfo(LDKCounterpartyForwardingInfo&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKCounterpartyForwardingInfo)); }
+ operator LDKCounterpartyForwardingInfo() && { LDKCounterpartyForwardingInfo res = self; memset(&self, 0, sizeof(LDKCounterpartyForwardingInfo)); return res; }
+ ~CounterpartyForwardingInfo() { CounterpartyForwardingInfo_free(self); }
+ CounterpartyForwardingInfo& operator=(CounterpartyForwardingInfo&& o) { CounterpartyForwardingInfo_free(self); self = o.self; memset(&o, 0, sizeof(CounterpartyForwardingInfo)); return *this; }
+ LDKCounterpartyForwardingInfo* operator &() { return &self; }
+ LDKCounterpartyForwardingInfo* operator ->() { return &self; }
+ const LDKCounterpartyForwardingInfo* operator &() const { return &self; }
+ const LDKCounterpartyForwardingInfo* operator ->() const { return &self; }
+};
+class ChannelCounterparty {
+private:
+ LDKChannelCounterparty self;
+public:
+ ChannelCounterparty(const ChannelCounterparty&) = delete;
+ ChannelCounterparty(ChannelCounterparty&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelCounterparty)); }
+ ChannelCounterparty(LDKChannelCounterparty&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelCounterparty)); }
+ operator LDKChannelCounterparty() && { LDKChannelCounterparty res = self; memset(&self, 0, sizeof(LDKChannelCounterparty)); return res; }
+ ~ChannelCounterparty() { ChannelCounterparty_free(self); }
+ ChannelCounterparty& operator=(ChannelCounterparty&& o) { ChannelCounterparty_free(self); self = o.self; memset(&o, 0, sizeof(ChannelCounterparty)); return *this; }
+ LDKChannelCounterparty* operator &() { return &self; }
+ LDKChannelCounterparty* operator ->() { return &self; }
+ const LDKChannelCounterparty* operator &() const { return &self; }
+ const LDKChannelCounterparty* operator ->() const { return &self; }
+};
+class ChannelDetails {
+private:
+ LDKChannelDetails self;
+public:
+ ChannelDetails(const ChannelDetails&) = delete;
+ ChannelDetails(ChannelDetails&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelDetails)); }
+ ChannelDetails(LDKChannelDetails&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelDetails)); }
+ operator LDKChannelDetails() && { LDKChannelDetails res = self; memset(&self, 0, sizeof(LDKChannelDetails)); return res; }
+ ~ChannelDetails() { ChannelDetails_free(self); }
+ ChannelDetails& operator=(ChannelDetails&& o) { ChannelDetails_free(self); self = o.self; memset(&o, 0, sizeof(ChannelDetails)); return *this; }
+ LDKChannelDetails* operator &() { return &self; }
+ LDKChannelDetails* operator ->() { return &self; }
+ const LDKChannelDetails* operator &() const { return &self; }
+ const LDKChannelDetails* operator ->() const { return &self; }
+};
+class RecentPaymentDetails {
+private:
+ LDKRecentPaymentDetails self;
+public:
+ RecentPaymentDetails(const RecentPaymentDetails&) = delete;
+ RecentPaymentDetails(RecentPaymentDetails&& o) : self(o.self) { memset(&o, 0, sizeof(RecentPaymentDetails)); }
+ RecentPaymentDetails(LDKRecentPaymentDetails&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKRecentPaymentDetails)); }
+ operator LDKRecentPaymentDetails() && { LDKRecentPaymentDetails res = self; memset(&self, 0, sizeof(LDKRecentPaymentDetails)); return res; }
+ ~RecentPaymentDetails() { RecentPaymentDetails_free(self); }
+ RecentPaymentDetails& operator=(RecentPaymentDetails&& o) { RecentPaymentDetails_free(self); self = o.self; memset(&o, 0, sizeof(RecentPaymentDetails)); return *this; }
+ LDKRecentPaymentDetails* operator &() { return &self; }
+ LDKRecentPaymentDetails* operator ->() { return &self; }
+ const LDKRecentPaymentDetails* operator &() const { return &self; }
+ const LDKRecentPaymentDetails* operator ->() const { return &self; }
+};
+class PhantomRouteHints {
+private:
+ LDKPhantomRouteHints self;
+public:
+ PhantomRouteHints(const PhantomRouteHints&) = delete;
+ PhantomRouteHints(PhantomRouteHints&& o) : self(o.self) { memset(&o, 0, sizeof(PhantomRouteHints)); }
+ PhantomRouteHints(LDKPhantomRouteHints&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPhantomRouteHints)); }
+ operator LDKPhantomRouteHints() && { LDKPhantomRouteHints res = self; memset(&self, 0, sizeof(LDKPhantomRouteHints)); return res; }
+ ~PhantomRouteHints() { PhantomRouteHints_free(self); }
+ PhantomRouteHints& operator=(PhantomRouteHints&& o) { PhantomRouteHints_free(self); self = o.self; memset(&o, 0, sizeof(PhantomRouteHints)); return *this; }
+ LDKPhantomRouteHints* operator &() { return &self; }
+ LDKPhantomRouteHints* operator ->() { return &self; }
+ const LDKPhantomRouteHints* operator &() const { return &self; }
+ const LDKPhantomRouteHints* operator ->() const { return &self; }
+};
+class ChannelManagerReadArgs {
+private:
+ LDKChannelManagerReadArgs self;
+public:
+ ChannelManagerReadArgs(const ChannelManagerReadArgs&) = delete;
+ ChannelManagerReadArgs(ChannelManagerReadArgs&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelManagerReadArgs)); }
+ ChannelManagerReadArgs(LDKChannelManagerReadArgs&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelManagerReadArgs)); }
+ operator LDKChannelManagerReadArgs() && { LDKChannelManagerReadArgs res = self; memset(&self, 0, sizeof(LDKChannelManagerReadArgs)); return res; }
+ ~ChannelManagerReadArgs() { ChannelManagerReadArgs_free(self); }
+ ChannelManagerReadArgs& operator=(ChannelManagerReadArgs&& o) { ChannelManagerReadArgs_free(self); self = o.self; memset(&o, 0, sizeof(ChannelManagerReadArgs)); return *this; }
+ LDKChannelManagerReadArgs* operator &() { return &self; }
+ LDKChannelManagerReadArgs* operator ->() { return &self; }
+ const LDKChannelManagerReadArgs* operator &() const { return &self; }
+ const LDKChannelManagerReadArgs* operator ->() const { return &self; }
+};
+class ChannelHandshakeConfig {
+private:
+ LDKChannelHandshakeConfig self;
+public:
+ ChannelHandshakeConfig(const ChannelHandshakeConfig&) = delete;
+ ChannelHandshakeConfig(ChannelHandshakeConfig&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelHandshakeConfig)); }
+ ChannelHandshakeConfig(LDKChannelHandshakeConfig&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelHandshakeConfig)); }
+ operator LDKChannelHandshakeConfig() && { LDKChannelHandshakeConfig res = self; memset(&self, 0, sizeof(LDKChannelHandshakeConfig)); return res; }
+ ~ChannelHandshakeConfig() { ChannelHandshakeConfig_free(self); }
+ ChannelHandshakeConfig& operator=(ChannelHandshakeConfig&& o) { ChannelHandshakeConfig_free(self); self = o.self; memset(&o, 0, sizeof(ChannelHandshakeConfig)); return *this; }
+ LDKChannelHandshakeConfig* operator &() { return &self; }
+ LDKChannelHandshakeConfig* operator ->() { return &self; }
+ const LDKChannelHandshakeConfig* operator &() const { return &self; }
+ const LDKChannelHandshakeConfig* operator ->() const { return &self; }
+};
+class ChannelHandshakeLimits {
+private:
+ LDKChannelHandshakeLimits self;
+public:
+ ChannelHandshakeLimits(const ChannelHandshakeLimits&) = delete;
+ ChannelHandshakeLimits(ChannelHandshakeLimits&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelHandshakeLimits)); }
+ ChannelHandshakeLimits(LDKChannelHandshakeLimits&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelHandshakeLimits)); }
+ operator LDKChannelHandshakeLimits() && { LDKChannelHandshakeLimits res = self; memset(&self, 0, sizeof(LDKChannelHandshakeLimits)); return res; }
+ ~ChannelHandshakeLimits() { ChannelHandshakeLimits_free(self); }
+ ChannelHandshakeLimits& operator=(ChannelHandshakeLimits&& o) { ChannelHandshakeLimits_free(self); self = o.self; memset(&o, 0, sizeof(ChannelHandshakeLimits)); return *this; }
+ LDKChannelHandshakeLimits* operator &() { return &self; }
+ LDKChannelHandshakeLimits* operator ->() { return &self; }
+ const LDKChannelHandshakeLimits* operator &() const { return &self; }
+ const LDKChannelHandshakeLimits* operator ->() const { return &self; }
+};
+class ChannelConfig {
+private:
+ LDKChannelConfig self;
+public:
+ ChannelConfig(const ChannelConfig&) = delete;
+ ChannelConfig(ChannelConfig&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelConfig)); }
+ ChannelConfig(LDKChannelConfig&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelConfig)); }
+ operator LDKChannelConfig() && { LDKChannelConfig res = self; memset(&self, 0, sizeof(LDKChannelConfig)); return res; }
+ ~ChannelConfig() { ChannelConfig_free(self); }
+ ChannelConfig& operator=(ChannelConfig&& o) { ChannelConfig_free(self); self = o.self; memset(&o, 0, sizeof(ChannelConfig)); return *this; }
+ LDKChannelConfig* operator &() { return &self; }
+ LDKChannelConfig* operator ->() { return &self; }
+ const LDKChannelConfig* operator &() const { return &self; }
+ const LDKChannelConfig* operator ->() const { return &self; }
+};
+class UserConfig {
+private:
+ LDKUserConfig self;
+public:
+ UserConfig(const UserConfig&) = delete;
+ UserConfig(UserConfig&& o) : self(o.self) { memset(&o, 0, sizeof(UserConfig)); }
+ UserConfig(LDKUserConfig&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUserConfig)); }
+ operator LDKUserConfig() && { LDKUserConfig res = self; memset(&self, 0, sizeof(LDKUserConfig)); return res; }
+ ~UserConfig() { UserConfig_free(self); }
+ UserConfig& operator=(UserConfig&& o) { UserConfig_free(self); self = o.self; memset(&o, 0, sizeof(UserConfig)); return *this; }
+ LDKUserConfig* operator &() { return &self; }
+ LDKUserConfig* operator ->() { return &self; }
+ const LDKUserConfig* operator &() const { return &self; }
+ const LDKUserConfig* operator ->() const { return &self; }
+};
+class APIError {
+private:
+ LDKAPIError self;
+public:
+ APIError(const APIError&) = delete;
+ APIError(APIError&& o) : self(o.self) { memset(&o, 0, sizeof(APIError)); }
+ APIError(LDKAPIError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKAPIError)); }
+ operator LDKAPIError() && { LDKAPIError res = self; memset(&self, 0, sizeof(LDKAPIError)); return res; }
+ ~APIError() { APIError_free(self); }
+ APIError& operator=(APIError&& o) { APIError_free(self); self = o.self; memset(&o, 0, sizeof(APIError)); return *this; }
+ LDKAPIError* operator &() { return &self; }
+ LDKAPIError* operator ->() { return &self; }
+ const LDKAPIError* operator &() const { return &self; }
+ const LDKAPIError* operator ->() const { return &self; }
+};
+class BigSize {
+private:
+ LDKBigSize self;
+public:
+ BigSize(const BigSize&) = delete;
+ BigSize(BigSize&& o) : self(o.self) { memset(&o, 0, sizeof(BigSize)); }
+ BigSize(LDKBigSize&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKBigSize)); }
+ operator LDKBigSize() && { LDKBigSize res = self; memset(&self, 0, sizeof(LDKBigSize)); return res; }
+ ~BigSize() { BigSize_free(self); }
+ BigSize& operator=(BigSize&& o) { BigSize_free(self); self = o.self; memset(&o, 0, sizeof(BigSize)); return *this; }
+ LDKBigSize* operator &() { return &self; }
+ LDKBigSize* operator ->() { return &self; }
+ const LDKBigSize* operator &() const { return &self; }
+ const LDKBigSize* operator ->() const { return &self; }
+};
+class Hostname {
+private:
+ LDKHostname self;
+public:
+ Hostname(const Hostname&) = delete;
+ Hostname(Hostname&& o) : self(o.self) { memset(&o, 0, sizeof(Hostname)); }
+ Hostname(LDKHostname&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKHostname)); }
+ operator LDKHostname() && { LDKHostname res = self; memset(&self, 0, sizeof(LDKHostname)); return res; }
+ ~Hostname() { Hostname_free(self); }
+ Hostname& operator=(Hostname&& o) { Hostname_free(self); self = o.self; memset(&o, 0, sizeof(Hostname)); return *this; }
+ LDKHostname* operator &() { return &self; }
+ LDKHostname* operator ->() { return &self; }
+ const LDKHostname* operator &() const { return &self; }
+ const LDKHostname* operator ->() const { return &self; }
+};
+class UntrustedString {
+private:
+ LDKUntrustedString self;
+public:
+ UntrustedString(const UntrustedString&) = delete;
+ UntrustedString(UntrustedString&& o) : self(o.self) { memset(&o, 0, sizeof(UntrustedString)); }
+ UntrustedString(LDKUntrustedString&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUntrustedString)); }
+ operator LDKUntrustedString() && { LDKUntrustedString res = self; memset(&self, 0, sizeof(LDKUntrustedString)); return res; }
+ ~UntrustedString() { UntrustedString_free(self); }
+ UntrustedString& operator=(UntrustedString&& o) { UntrustedString_free(self); self = o.self; memset(&o, 0, sizeof(UntrustedString)); return *this; }
+ LDKUntrustedString* operator &() { return &self; }
+ LDKUntrustedString* operator ->() { return &self; }
+ const LDKUntrustedString* operator &() const { return &self; }
+ const LDKUntrustedString* operator ->() const { return &self; }
+};
+class PrintableString {
+private:
+ LDKPrintableString self;
+public:
+ PrintableString(const PrintableString&) = delete;
+ PrintableString(PrintableString&& o) : self(o.self) { memset(&o, 0, sizeof(PrintableString)); }
+ PrintableString(LDKPrintableString&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPrintableString)); }
+ operator LDKPrintableString() && { LDKPrintableString res = self; memset(&self, 0, sizeof(LDKPrintableString)); return res; }
+ ~PrintableString() { PrintableString_free(self); }
+ PrintableString& operator=(PrintableString&& o) { PrintableString_free(self); self = o.self; memset(&o, 0, sizeof(PrintableString)); return *this; }
+ LDKPrintableString* operator &() { return &self; }
+ LDKPrintableString* operator ->() { return &self; }
+ const LDKPrintableString* operator &() const { return &self; }
+ const LDKPrintableString* operator ->() const { return &self; }
+};
+class OutPoint {
+private:
+ LDKOutPoint self;
+public:
+ OutPoint(const OutPoint&) = delete;
+ OutPoint(OutPoint&& o) : self(o.self) { memset(&o, 0, sizeof(OutPoint)); }
+ OutPoint(LDKOutPoint&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKOutPoint)); }
+ operator LDKOutPoint() && { LDKOutPoint res = self; memset(&self, 0, sizeof(LDKOutPoint)); return res; }
+ ~OutPoint() { OutPoint_free(self); }
+ OutPoint& operator=(OutPoint&& o) { OutPoint_free(self); self = o.self; memset(&o, 0, sizeof(OutPoint)); return *this; }
+ LDKOutPoint* operator &() { return &self; }
+ LDKOutPoint* operator ->() { return &self; }
+ const LDKOutPoint* operator &() const { return &self; }
+ const LDKOutPoint* operator ->() const { return &self; }
+};
+class CustomMessageReader {
+private:
+ LDKCustomMessageReader self;
+public:
+ CustomMessageReader(const CustomMessageReader&) = delete;
+ CustomMessageReader(CustomMessageReader&& o) : self(o.self) { memset(&o, 0, sizeof(CustomMessageReader)); }
+ CustomMessageReader(LDKCustomMessageReader&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKCustomMessageReader)); }
+ operator LDKCustomMessageReader() && { LDKCustomMessageReader res = self; memset(&self, 0, sizeof(LDKCustomMessageReader)); return res; }
+ ~CustomMessageReader() { CustomMessageReader_free(self); }
+ CustomMessageReader& operator=(CustomMessageReader&& o) { CustomMessageReader_free(self); self = o.self; memset(&o, 0, sizeof(CustomMessageReader)); return *this; }
+ LDKCustomMessageReader* operator &() { return &self; }
+ LDKCustomMessageReader* operator ->() { return &self; }
+ const LDKCustomMessageReader* operator &() const { return &self; }
+ const LDKCustomMessageReader* operator ->() const { return &self; }
+ /**
+ * Decodes a custom message to `CustomMessageType`. If the given message type is known to the
+ * implementation and the message could be decoded, must return `Ok(Some(message))`. If the
+ * message type is unknown to the implementation, must return `Ok(None)`. If a decoding error
+ * occur, must return `Err(DecodeError::X)` where `X` details the encountered error.
+ */
+ inline LDK::CResult_COption_TypeZDecodeErrorZ read(uint16_t message_type, struct LDKu8slice buffer);
+};
+class Type {
+private:
+ LDKType self;
+public:
+ Type(const Type&) = delete;
+ Type(Type&& o) : self(o.self) { memset(&o, 0, sizeof(Type)); }
+ Type(LDKType&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKType)); }
+ operator LDKType() && { LDKType res = self; memset(&self, 0, sizeof(LDKType)); return res; }
+ ~Type() { Type_free(self); }
+ Type& operator=(Type&& o) { Type_free(self); self = o.self; memset(&o, 0, sizeof(Type)); return *this; }
+ LDKType* operator &() { return &self; }
+ LDKType* operator ->() { return &self; }
+ const LDKType* operator &() const { return &self; }
+ const LDKType* operator ->() const { return &self; }
+ /**
+ * Returns the type identifying the message payload.
+ */
+ inline uint16_t type_id();
+ /**
+ * Return a human-readable "debug" string describing this object
+ */
+ inline LDK::Str debug_str();
+};
+class PaymentError {
+private:
+ LDKPaymentError self;
+public:
+ PaymentError(const PaymentError&) = delete;
+ PaymentError(PaymentError&& o) : self(o.self) { memset(&o, 0, sizeof(PaymentError)); }
+ PaymentError(LDKPaymentError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPaymentError)); }
+ operator LDKPaymentError() && { LDKPaymentError res = self; memset(&self, 0, sizeof(LDKPaymentError)); return res; }
+ ~PaymentError() { PaymentError_free(self); }
+ PaymentError& operator=(PaymentError&& o) { PaymentError_free(self); self = o.self; memset(&o, 0, sizeof(PaymentError)); return *this; }
+ LDKPaymentError* operator &() { return &self; }
+ LDKPaymentError* operator ->() { return &self; }
+ const LDKPaymentError* operator &() const { return &self; }
+ const LDKPaymentError* operator ->() const { return &self; }
+};
+class ChannelMonitorUpdate {
+private:
+ LDKChannelMonitorUpdate self;
+public:
+ ChannelMonitorUpdate(const ChannelMonitorUpdate&) = delete;
+ ChannelMonitorUpdate(ChannelMonitorUpdate&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelMonitorUpdate)); }
+ ChannelMonitorUpdate(LDKChannelMonitorUpdate&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelMonitorUpdate)); }
+ operator LDKChannelMonitorUpdate() && { LDKChannelMonitorUpdate res = self; memset(&self, 0, sizeof(LDKChannelMonitorUpdate)); return res; }
+ ~ChannelMonitorUpdate() { ChannelMonitorUpdate_free(self); }
+ ChannelMonitorUpdate& operator=(ChannelMonitorUpdate&& o) { ChannelMonitorUpdate_free(self); self = o.self; memset(&o, 0, sizeof(ChannelMonitorUpdate)); return *this; }
+ LDKChannelMonitorUpdate* operator &() { return &self; }
+ LDKChannelMonitorUpdate* operator ->() { return &self; }
+ const LDKChannelMonitorUpdate* operator &() const { return &self; }
+ const LDKChannelMonitorUpdate* operator ->() const { return &self; }
+};
+class MonitorEvent {
+private:
+ LDKMonitorEvent self;
+public:
+ MonitorEvent(const MonitorEvent&) = delete;
+ MonitorEvent(MonitorEvent&& o) : self(o.self) { memset(&o, 0, sizeof(MonitorEvent)); }
+ MonitorEvent(LDKMonitorEvent&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKMonitorEvent)); }
+ operator LDKMonitorEvent() && { LDKMonitorEvent res = self; memset(&self, 0, sizeof(LDKMonitorEvent)); return res; }
+ ~MonitorEvent() { MonitorEvent_free(self); }
+ MonitorEvent& operator=(MonitorEvent&& o) { MonitorEvent_free(self); self = o.self; memset(&o, 0, sizeof(MonitorEvent)); return *this; }
+ LDKMonitorEvent* operator &() { return &self; }
+ LDKMonitorEvent* operator ->() { return &self; }
+ const LDKMonitorEvent* operator &() const { return &self; }
+ const LDKMonitorEvent* operator ->() const { return &self; }
+};
+class HTLCUpdate {
+private:
+ LDKHTLCUpdate self;
+public:
+ HTLCUpdate(const HTLCUpdate&) = delete;
+ HTLCUpdate(HTLCUpdate&& o) : self(o.self) { memset(&o, 0, sizeof(HTLCUpdate)); }
+ HTLCUpdate(LDKHTLCUpdate&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKHTLCUpdate)); }
+ operator LDKHTLCUpdate() && { LDKHTLCUpdate res = self; memset(&self, 0, sizeof(LDKHTLCUpdate)); return res; }
+ ~HTLCUpdate() { HTLCUpdate_free(self); }
+ HTLCUpdate& operator=(HTLCUpdate&& o) { HTLCUpdate_free(self); self = o.self; memset(&o, 0, sizeof(HTLCUpdate)); return *this; }
+ LDKHTLCUpdate* operator &() { return &self; }
+ LDKHTLCUpdate* operator ->() { return &self; }
+ const LDKHTLCUpdate* operator &() const { return &self; }
+ const LDKHTLCUpdate* operator ->() const { return &self; }
+};
+class Balance {
+private:
+ LDKBalance self;
+public:
+ Balance(const Balance&) = delete;
+ Balance(Balance&& o) : self(o.self) { memset(&o, 0, sizeof(Balance)); }
+ Balance(LDKBalance&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKBalance)); }
+ operator LDKBalance() && { LDKBalance res = self; memset(&self, 0, sizeof(LDKBalance)); return res; }
+ ~Balance() { Balance_free(self); }
+ Balance& operator=(Balance&& o) { Balance_free(self); self = o.self; memset(&o, 0, sizeof(Balance)); return *this; }
+ LDKBalance* operator &() { return &self; }
+ LDKBalance* operator ->() { return &self; }
+ const LDKBalance* operator &() const { return &self; }
+ const LDKBalance* operator ->() const { return &self; }
+};
+class ChannelMonitor {
+private:
+ LDKChannelMonitor self;
+public:
+ ChannelMonitor(const ChannelMonitor&) = delete;
+ ChannelMonitor(ChannelMonitor&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelMonitor)); }
+ ChannelMonitor(LDKChannelMonitor&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelMonitor)); }
+ operator LDKChannelMonitor() && { LDKChannelMonitor res = self; memset(&self, 0, sizeof(LDKChannelMonitor)); return res; }
+ ~ChannelMonitor() { ChannelMonitor_free(self); }
+ ChannelMonitor& operator=(ChannelMonitor&& o) { ChannelMonitor_free(self); self = o.self; memset(&o, 0, sizeof(ChannelMonitor)); return *this; }
+ LDKChannelMonitor* operator &() { return &self; }
+ LDKChannelMonitor* operator ->() { return &self; }
+ const LDKChannelMonitor* operator &() const { return &self; }
+ const LDKChannelMonitor* operator ->() const { return &self; }
+};
+class ExpandedKey {
+private:
+ LDKExpandedKey self;
+public:
+ ExpandedKey(const ExpandedKey&) = delete;
+ ExpandedKey(ExpandedKey&& o) : self(o.self) { memset(&o, 0, sizeof(ExpandedKey)); }
+ ExpandedKey(LDKExpandedKey&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKExpandedKey)); }
+ operator LDKExpandedKey() && { LDKExpandedKey res = self; memset(&self, 0, sizeof(LDKExpandedKey)); return res; }
+ ~ExpandedKey() { ExpandedKey_free(self); }
+ ExpandedKey& operator=(ExpandedKey&& o) { ExpandedKey_free(self); self = o.self; memset(&o, 0, sizeof(ExpandedKey)); return *this; }
+ LDKExpandedKey* operator &() { return &self; }
+ LDKExpandedKey* operator ->() { return &self; }
+ const LDKExpandedKey* operator &() const { return &self; }
+ const LDKExpandedKey* operator ->() const { return &self; }
+};
+class CustomMessageHandler {
+private:
+ LDKCustomMessageHandler self;
+public:
+ CustomMessageHandler(const CustomMessageHandler&) = delete;
+ CustomMessageHandler(CustomMessageHandler&& o) : self(o.self) { memset(&o, 0, sizeof(CustomMessageHandler)); }
+ CustomMessageHandler(LDKCustomMessageHandler&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKCustomMessageHandler)); }
+ operator LDKCustomMessageHandler() && { LDKCustomMessageHandler res = self; memset(&self, 0, sizeof(LDKCustomMessageHandler)); return res; }
+ ~CustomMessageHandler() { CustomMessageHandler_free(self); }
+ CustomMessageHandler& operator=(CustomMessageHandler&& o) { CustomMessageHandler_free(self); self = o.self; memset(&o, 0, sizeof(CustomMessageHandler)); return *this; }
+ LDKCustomMessageHandler* operator &() { return &self; }
+ LDKCustomMessageHandler* operator ->() { return &self; }
+ const LDKCustomMessageHandler* operator &() const { return &self; }
+ const LDKCustomMessageHandler* operator ->() const { return &self; }
+ /**
+ * Handles the given message sent from `sender_node_id`, possibly producing messages for
+ * [`CustomMessageHandler::get_and_clear_pending_msg`] to return and thus for [`PeerManager`]
+ * to send.
+ */
+ inline LDK::CResult_NoneLightningErrorZ handle_custom_message(struct LDKType msg, struct LDKPublicKey sender_node_id);
+ /**
+ * Returns the list of pending messages that were generated by the handler, clearing the list
+ * in the process. Each message is paired with the node id of the intended recipient. If no
+ * connection to the node exists, then the message is simply not sent.
+ */
+ inline LDK::CVec_C2Tuple_PublicKeyTypeZZ get_and_clear_pending_msg();
+};
+class IgnoringMessageHandler {
+private:
+ LDKIgnoringMessageHandler self;
+public:
+ IgnoringMessageHandler(const IgnoringMessageHandler&) = delete;
+ IgnoringMessageHandler(IgnoringMessageHandler&& o) : self(o.self) { memset(&o, 0, sizeof(IgnoringMessageHandler)); }
+ IgnoringMessageHandler(LDKIgnoringMessageHandler&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKIgnoringMessageHandler)); }
+ operator LDKIgnoringMessageHandler() && { LDKIgnoringMessageHandler res = self; memset(&self, 0, sizeof(LDKIgnoringMessageHandler)); return res; }
+ ~IgnoringMessageHandler() { IgnoringMessageHandler_free(self); }
+ IgnoringMessageHandler& operator=(IgnoringMessageHandler&& o) { IgnoringMessageHandler_free(self); self = o.self; memset(&o, 0, sizeof(IgnoringMessageHandler)); return *this; }
+ LDKIgnoringMessageHandler* operator &() { return &self; }
+ LDKIgnoringMessageHandler* operator ->() { return &self; }
+ const LDKIgnoringMessageHandler* operator &() const { return &self; }
+ const LDKIgnoringMessageHandler* operator ->() const { return &self; }
+};
+class ErroringMessageHandler {
+private:
+ LDKErroringMessageHandler self;
+public:
+ ErroringMessageHandler(const ErroringMessageHandler&) = delete;
+ ErroringMessageHandler(ErroringMessageHandler&& o) : self(o.self) { memset(&o, 0, sizeof(ErroringMessageHandler)); }
+ ErroringMessageHandler(LDKErroringMessageHandler&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKErroringMessageHandler)); }
+ operator LDKErroringMessageHandler() && { LDKErroringMessageHandler res = self; memset(&self, 0, sizeof(LDKErroringMessageHandler)); return res; }
+ ~ErroringMessageHandler() { ErroringMessageHandler_free(self); }
+ ErroringMessageHandler& operator=(ErroringMessageHandler&& o) { ErroringMessageHandler_free(self); self = o.self; memset(&o, 0, sizeof(ErroringMessageHandler)); return *this; }
+ LDKErroringMessageHandler* operator &() { return &self; }
+ LDKErroringMessageHandler* operator ->() { return &self; }
+ const LDKErroringMessageHandler* operator &() const { return &self; }
+ const LDKErroringMessageHandler* operator ->() const { return &self; }
+};
+class MessageHandler {
+private:
+ LDKMessageHandler self;
+public:
+ MessageHandler(const MessageHandler&) = delete;
+ MessageHandler(MessageHandler&& o) : self(o.self) { memset(&o, 0, sizeof(MessageHandler)); }
+ MessageHandler(LDKMessageHandler&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKMessageHandler)); }
+ operator LDKMessageHandler() && { LDKMessageHandler res = self; memset(&self, 0, sizeof(LDKMessageHandler)); return res; }
+ ~MessageHandler() { MessageHandler_free(self); }
+ MessageHandler& operator=(MessageHandler&& o) { MessageHandler_free(self); self = o.self; memset(&o, 0, sizeof(MessageHandler)); return *this; }
+ LDKMessageHandler* operator &() { return &self; }
+ LDKMessageHandler* operator ->() { return &self; }
+ const LDKMessageHandler* operator &() const { return &self; }
+ const LDKMessageHandler* operator ->() const { return &self; }
+};
+class SocketDescriptor {
+private:
+ LDKSocketDescriptor self;
+public:
+ SocketDescriptor(const SocketDescriptor&) = delete;
+ SocketDescriptor(SocketDescriptor&& o) : self(o.self) { memset(&o, 0, sizeof(SocketDescriptor)); }
+ SocketDescriptor(LDKSocketDescriptor&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKSocketDescriptor)); }
+ operator LDKSocketDescriptor() && { LDKSocketDescriptor res = self; memset(&self, 0, sizeof(LDKSocketDescriptor)); return res; }
+ ~SocketDescriptor() { SocketDescriptor_free(self); }
+ SocketDescriptor& operator=(SocketDescriptor&& o) { SocketDescriptor_free(self); self = o.self; memset(&o, 0, sizeof(SocketDescriptor)); return *this; }
+ LDKSocketDescriptor* operator &() { return &self; }
+ LDKSocketDescriptor* operator ->() { return &self; }
+ const LDKSocketDescriptor* operator &() const { return &self; }
+ const LDKSocketDescriptor* operator ->() const { return &self; }
+ /**
+ * Attempts to send some data from the given slice to the peer.
+ *
+ * Returns the amount of data which was sent, possibly 0 if the socket has since disconnected.
+ * Note that in the disconnected case, [`PeerManager::socket_disconnected`] must still be
+ * called and further write attempts may occur until that time.
+ *
+ * If the returned size is smaller than `data.len()`, a
+ * [`PeerManager::write_buffer_space_avail`] call must be made the next time more data can be
+ * written. Additionally, until a `send_data` event completes fully, no further
+ * [`PeerManager::read_event`] calls should be made for the same peer! Because this is to
+ * prevent denial-of-service issues, you should not read or buffer any data from the socket
+ * until then.
+ *
+ * If a [`PeerManager::read_event`] call on this descriptor had previously returned true
+ * (indicating that read events should be paused to prevent DoS in the send buffer),
+ * `resume_read` may be set indicating that read events on this descriptor should resume. A
+ * `resume_read` of false carries no meaning, and should not cause any action.
+ */
+ inline uintptr_t send_data(struct LDKu8slice data, bool resume_read);
+ /**
+ * Disconnect the socket pointed to by this SocketDescriptor.
+ *
+ * You do *not* need to call [`PeerManager::socket_disconnected`] with this socket after this
+ * call (doing so is a noop).
+ */
+ inline void disconnect_socket();
+ /** Checks if two objects are equal given this object's this_arg pointer and another object. */
+ inline bool eq(const struct LDKSocketDescriptor *NONNULL_PTR other_arg);
+ /**
+ * Calculate a succinct non-cryptographic hash for an object given its this_arg pointer.
+ * This is used, for example, for inclusion of this object in a hash map.
+ */
+ inline uint64_t hash();
+};
+class PeerHandleError {
+private:
+ LDKPeerHandleError self;
+public:
+ PeerHandleError(const PeerHandleError&) = delete;
+ PeerHandleError(PeerHandleError&& o) : self(o.self) { memset(&o, 0, sizeof(PeerHandleError)); }
+ PeerHandleError(LDKPeerHandleError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPeerHandleError)); }
+ operator LDKPeerHandleError() && { LDKPeerHandleError res = self; memset(&self, 0, sizeof(LDKPeerHandleError)); return res; }
+ ~PeerHandleError() { PeerHandleError_free(self); }
+ PeerHandleError& operator=(PeerHandleError&& o) { PeerHandleError_free(self); self = o.self; memset(&o, 0, sizeof(PeerHandleError)); return *this; }
+ LDKPeerHandleError* operator &() { return &self; }
+ LDKPeerHandleError* operator ->() { return &self; }
+ const LDKPeerHandleError* operator &() const { return &self; }
+ const LDKPeerHandleError* operator ->() const { return &self; }
+};
+class PeerManager {
+private:
+ LDKPeerManager self;
+public:
+ PeerManager(const PeerManager&) = delete;
+ PeerManager(PeerManager&& o) : self(o.self) { memset(&o, 0, sizeof(PeerManager)); }
+ PeerManager(LDKPeerManager&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPeerManager)); }
+ operator LDKPeerManager() && { LDKPeerManager res = self; memset(&self, 0, sizeof(LDKPeerManager)); return res; }
+ ~PeerManager() { PeerManager_free(self); }
+ PeerManager& operator=(PeerManager&& o) { PeerManager_free(self); self = o.self; memset(&o, 0, sizeof(PeerManager)); return *this; }
+ LDKPeerManager* operator &() { return &self; }
+ LDKPeerManager* operator ->() { return &self; }
+ const LDKPeerManager* operator &() const { return &self; }
+ const LDKPeerManager* operator ->() const { return &self; }
+};
+class UtxoLookupError {
+private:
+ LDKUtxoLookupError self;
+public:
+ UtxoLookupError(const UtxoLookupError&) = delete;
+ UtxoLookupError(UtxoLookupError&& o) : self(o.self) { memset(&o, 0, sizeof(UtxoLookupError)); }
+ UtxoLookupError(LDKUtxoLookupError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUtxoLookupError)); }
+ operator LDKUtxoLookupError() && { LDKUtxoLookupError res = self; memset(&self, 0, sizeof(LDKUtxoLookupError)); return res; }
+ UtxoLookupError& operator=(UtxoLookupError&& o) { self = o.self; memset(&o, 0, sizeof(UtxoLookupError)); return *this; }
+ LDKUtxoLookupError* operator &() { return &self; }
+ LDKUtxoLookupError* operator ->() { return &self; }
+ const LDKUtxoLookupError* operator &() const { return &self; }
+ const LDKUtxoLookupError* operator ->() const { return &self; }
+};
+class UtxoResult {
+private:
+ LDKUtxoResult self;
+public:
+ UtxoResult(const UtxoResult&) = delete;
+ UtxoResult(UtxoResult&& o) : self(o.self) { memset(&o, 0, sizeof(UtxoResult)); }
+ UtxoResult(LDKUtxoResult&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUtxoResult)); }
+ operator LDKUtxoResult() && { LDKUtxoResult res = self; memset(&self, 0, sizeof(LDKUtxoResult)); return res; }
+ ~UtxoResult() { UtxoResult_free(self); }
+ UtxoResult& operator=(UtxoResult&& o) { UtxoResult_free(self); self = o.self; memset(&o, 0, sizeof(UtxoResult)); return *this; }
+ LDKUtxoResult* operator &() { return &self; }
+ LDKUtxoResult* operator ->() { return &self; }
+ const LDKUtxoResult* operator &() const { return &self; }
+ const LDKUtxoResult* operator ->() const { return &self; }
+};
+class UtxoLookup {
+private:
+ LDKUtxoLookup self;
+public:
+ UtxoLookup(const UtxoLookup&) = delete;
+ UtxoLookup(UtxoLookup&& o) : self(o.self) { memset(&o, 0, sizeof(UtxoLookup)); }
+ UtxoLookup(LDKUtxoLookup&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUtxoLookup)); }
+ operator LDKUtxoLookup() && { LDKUtxoLookup res = self; memset(&self, 0, sizeof(LDKUtxoLookup)); return res; }
+ ~UtxoLookup() { UtxoLookup_free(self); }
+ UtxoLookup& operator=(UtxoLookup&& o) { UtxoLookup_free(self); self = o.self; memset(&o, 0, sizeof(UtxoLookup)); return *this; }
+ LDKUtxoLookup* operator &() { return &self; }
+ LDKUtxoLookup* operator ->() { return &self; }
+ const LDKUtxoLookup* operator &() const { return &self; }
+ const LDKUtxoLookup* operator ->() const { return &self; }
+ /**
+ * Returns the transaction output of a funding transaction encoded by [`short_channel_id`].
+ * Returns an error if `genesis_hash` is for a different chain or if such a transaction output
+ * is unknown.
+ *
+ * [`short_channel_id`]: https://github.com/lightning/bolts/blob/master/07-routing-gossip.md#definition-of-short_channel_id
+ */
+ inline LDK::UtxoResult get_utxo(const uint8_t (*genesis_hash)[32], uint64_t short_channel_id);
+};
+class UtxoFuture {
+private:
+ LDKUtxoFuture self;
+public:
+ UtxoFuture(const UtxoFuture&) = delete;
+ UtxoFuture(UtxoFuture&& o) : self(o.self) { memset(&o, 0, sizeof(UtxoFuture)); }
+ UtxoFuture(LDKUtxoFuture&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUtxoFuture)); }
+ operator LDKUtxoFuture() && { LDKUtxoFuture res = self; memset(&self, 0, sizeof(LDKUtxoFuture)); return res; }
+ ~UtxoFuture() { UtxoFuture_free(self); }
+ UtxoFuture& operator=(UtxoFuture&& o) { UtxoFuture_free(self); self = o.self; memset(&o, 0, sizeof(UtxoFuture)); return *this; }
+ LDKUtxoFuture* operator &() { return &self; }
+ LDKUtxoFuture* operator ->() { return &self; }
+ const LDKUtxoFuture* operator &() const { return &self; }
+ const LDKUtxoFuture* operator ->() const { return &self; }
+};
+class OnionMessenger {
+private:
+ LDKOnionMessenger self;
+public:
+ OnionMessenger(const OnionMessenger&) = delete;
+ OnionMessenger(OnionMessenger&& o) : self(o.self) { memset(&o, 0, sizeof(OnionMessenger)); }
+ OnionMessenger(LDKOnionMessenger&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKOnionMessenger)); }
+ operator LDKOnionMessenger() && { LDKOnionMessenger res = self; memset(&self, 0, sizeof(LDKOnionMessenger)); return res; }
+ ~OnionMessenger() { OnionMessenger_free(self); }
+ OnionMessenger& operator=(OnionMessenger&& o) { OnionMessenger_free(self); self = o.self; memset(&o, 0, sizeof(OnionMessenger)); return *this; }
+ LDKOnionMessenger* operator &() { return &self; }
+ LDKOnionMessenger* operator ->() { return &self; }
+ const LDKOnionMessenger* operator &() const { return &self; }
+ const LDKOnionMessenger* operator ->() const { return &self; }
+};
+class Destination {
+private:
+ LDKDestination self;
+public:
+ Destination(const Destination&) = delete;
+ Destination(Destination&& o) : self(o.self) { memset(&o, 0, sizeof(Destination)); }
+ Destination(LDKDestination&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKDestination)); }
+ operator LDKDestination() && { LDKDestination res = self; memset(&self, 0, sizeof(LDKDestination)); return res; }
+ ~Destination() { Destination_free(self); }
+ Destination& operator=(Destination&& o) { Destination_free(self); self = o.self; memset(&o, 0, sizeof(Destination)); return *this; }
+ LDKDestination* operator &() { return &self; }
+ LDKDestination* operator ->() { return &self; }
+ const LDKDestination* operator &() const { return &self; }
+ const LDKDestination* operator ->() const { return &self; }
+};
+class SendError {
+private:
+ LDKSendError self;
+public:
+ SendError(const SendError&) = delete;
+ SendError(SendError&& o) : self(o.self) { memset(&o, 0, sizeof(SendError)); }
+ SendError(LDKSendError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKSendError)); }
+ operator LDKSendError() && { LDKSendError res = self; memset(&self, 0, sizeof(LDKSendError)); return res; }
+ ~SendError() { SendError_free(self); }
+ SendError& operator=(SendError&& o) { SendError_free(self); self = o.self; memset(&o, 0, sizeof(SendError)); return *this; }
+ LDKSendError* operator &() { return &self; }
+ LDKSendError* operator ->() { return &self; }
+ const LDKSendError* operator &() const { return &self; }
+ const LDKSendError* operator ->() const { return &self; }
+};
+class CustomOnionMessageHandler {
+private:
+ LDKCustomOnionMessageHandler self;
+public:
+ CustomOnionMessageHandler(const CustomOnionMessageHandler&) = delete;
+ CustomOnionMessageHandler(CustomOnionMessageHandler&& o) : self(o.self) { memset(&o, 0, sizeof(CustomOnionMessageHandler)); }
+ CustomOnionMessageHandler(LDKCustomOnionMessageHandler&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKCustomOnionMessageHandler)); }
+ operator LDKCustomOnionMessageHandler() && { LDKCustomOnionMessageHandler res = self; memset(&self, 0, sizeof(LDKCustomOnionMessageHandler)); return res; }
+ ~CustomOnionMessageHandler() { CustomOnionMessageHandler_free(self); }
+ CustomOnionMessageHandler& operator=(CustomOnionMessageHandler&& o) { CustomOnionMessageHandler_free(self); self = o.self; memset(&o, 0, sizeof(CustomOnionMessageHandler)); return *this; }
+ LDKCustomOnionMessageHandler* operator &() { return &self; }
+ LDKCustomOnionMessageHandler* operator ->() { return &self; }
+ const LDKCustomOnionMessageHandler* operator &() const { return &self; }
+ const LDKCustomOnionMessageHandler* operator ->() const { return &self; }
+ /**
+ * Called with the custom message that was received.
+ */
+ inline void handle_custom_message(struct LDKCustomOnionMessageContents msg);
+ /**
+ * Read a custom message of type `message_type` from `buffer`, returning `Ok(None)` if the
+ * message type is unknown.
+ */
+ inline LDK::CResult_COption_CustomOnionMessageContentsZDecodeErrorZ read_custom_message(uint64_t message_type, struct LDKu8slice buffer);
+};
+class BlindedPath {
+private:
+ LDKBlindedPath self;
+public:
+ BlindedPath(const BlindedPath&) = delete;
+ BlindedPath(BlindedPath&& o) : self(o.self) { memset(&o, 0, sizeof(BlindedPath)); }
+ BlindedPath(LDKBlindedPath&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKBlindedPath)); }
+ operator LDKBlindedPath() && { LDKBlindedPath res = self; memset(&self, 0, sizeof(LDKBlindedPath)); return res; }
+ ~BlindedPath() { BlindedPath_free(self); }
+ BlindedPath& operator=(BlindedPath&& o) { BlindedPath_free(self); self = o.self; memset(&o, 0, sizeof(BlindedPath)); return *this; }
+ LDKBlindedPath* operator &() { return &self; }
+ LDKBlindedPath* operator ->() { return &self; }
+ const LDKBlindedPath* operator &() const { return &self; }
+ const LDKBlindedPath* operator ->() const { return &self; }
+};
+class BlindedHop {
+private:
+ LDKBlindedHop self;
+public:
+ BlindedHop(const BlindedHop&) = delete;
+ BlindedHop(BlindedHop&& o) : self(o.self) { memset(&o, 0, sizeof(BlindedHop)); }
+ BlindedHop(LDKBlindedHop&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKBlindedHop)); }
+ operator LDKBlindedHop() && { LDKBlindedHop res = self; memset(&self, 0, sizeof(LDKBlindedHop)); return res; }
+ ~BlindedHop() { BlindedHop_free(self); }
+ BlindedHop& operator=(BlindedHop&& o) { BlindedHop_free(self); self = o.self; memset(&o, 0, sizeof(BlindedHop)); return *this; }
+ LDKBlindedHop* operator &() { return &self; }
+ LDKBlindedHop* operator ->() { return &self; }
+ const LDKBlindedHop* operator &() const { return &self; }
+ const LDKBlindedHop* operator ->() const { return &self; }
+};
+class ParseError {
+private:
+ LDKParseError self;
+public:
+ ParseError(const ParseError&) = delete;
+ ParseError(ParseError&& o) : self(o.self) { memset(&o, 0, sizeof(ParseError)); }
+ ParseError(LDKParseError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKParseError)); }
+ operator LDKParseError() && { LDKParseError res = self; memset(&self, 0, sizeof(LDKParseError)); return res; }
+ ~ParseError() { ParseError_free(self); }
+ ParseError& operator=(ParseError&& o) { ParseError_free(self); self = o.self; memset(&o, 0, sizeof(ParseError)); return *this; }
+ LDKParseError* operator &() { return &self; }
+ LDKParseError* operator ->() { return &self; }
+ const LDKParseError* operator &() const { return &self; }
+ const LDKParseError* operator ->() const { return &self; }
+};
+class ParseOrSemanticError {
+private:
+ LDKParseOrSemanticError self;
+public:
+ ParseOrSemanticError(const ParseOrSemanticError&) = delete;
+ ParseOrSemanticError(ParseOrSemanticError&& o) : self(o.self) { memset(&o, 0, sizeof(ParseOrSemanticError)); }
+ ParseOrSemanticError(LDKParseOrSemanticError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKParseOrSemanticError)); }
+ operator LDKParseOrSemanticError() && { LDKParseOrSemanticError res = self; memset(&self, 0, sizeof(LDKParseOrSemanticError)); return res; }
+ ~ParseOrSemanticError() { ParseOrSemanticError_free(self); }
+ ParseOrSemanticError& operator=(ParseOrSemanticError&& o) { ParseOrSemanticError_free(self); self = o.self; memset(&o, 0, sizeof(ParseOrSemanticError)); return *this; }
+ LDKParseOrSemanticError* operator &() { return &self; }
+ LDKParseOrSemanticError* operator ->() { return &self; }
+ const LDKParseOrSemanticError* operator &() const { return &self; }
+ const LDKParseOrSemanticError* operator ->() const { return &self; }
+};
+class Invoice {
+private:
+ LDKInvoice self;
+public:
+ Invoice(const Invoice&) = delete;
+ Invoice(Invoice&& o) : self(o.self) { memset(&o, 0, sizeof(Invoice)); }
+ Invoice(LDKInvoice&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKInvoice)); }
+ operator LDKInvoice() && { LDKInvoice res = self; memset(&self, 0, sizeof(LDKInvoice)); return res; }
+ ~Invoice() { Invoice_free(self); }
+ Invoice& operator=(Invoice&& o) { Invoice_free(self); self = o.self; memset(&o, 0, sizeof(Invoice)); return *this; }
+ LDKInvoice* operator &() { return &self; }
+ LDKInvoice* operator ->() { return &self; }
+ const LDKInvoice* operator &() const { return &self; }
+ const LDKInvoice* operator ->() const { return &self; }
+};
+class SignedRawInvoice {
+private:
+ LDKSignedRawInvoice self;
+public:
+ SignedRawInvoice(const SignedRawInvoice&) = delete;
+ SignedRawInvoice(SignedRawInvoice&& o) : self(o.self) { memset(&o, 0, sizeof(SignedRawInvoice)); }
+ SignedRawInvoice(LDKSignedRawInvoice&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKSignedRawInvoice)); }
+ operator LDKSignedRawInvoice() && { LDKSignedRawInvoice res = self; memset(&self, 0, sizeof(LDKSignedRawInvoice)); return res; }
+ ~SignedRawInvoice() { SignedRawInvoice_free(self); }
+ SignedRawInvoice& operator=(SignedRawInvoice&& o) { SignedRawInvoice_free(self); self = o.self; memset(&o, 0, sizeof(SignedRawInvoice)); return *this; }
+ LDKSignedRawInvoice* operator &() { return &self; }
+ LDKSignedRawInvoice* operator ->() { return &self; }
+ const LDKSignedRawInvoice* operator &() const { return &self; }
+ const LDKSignedRawInvoice* operator ->() const { return &self; }
+};
+class RawInvoice {
+private:
+ LDKRawInvoice self;
+public:
+ RawInvoice(const RawInvoice&) = delete;
+ RawInvoice(RawInvoice&& o) : self(o.self) { memset(&o, 0, sizeof(RawInvoice)); }
+ RawInvoice(LDKRawInvoice&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKRawInvoice)); }
+ operator LDKRawInvoice() && { LDKRawInvoice res = self; memset(&self, 0, sizeof(LDKRawInvoice)); return res; }
+ ~RawInvoice() { RawInvoice_free(self); }
+ RawInvoice& operator=(RawInvoice&& o) { RawInvoice_free(self); self = o.self; memset(&o, 0, sizeof(RawInvoice)); return *this; }
+ LDKRawInvoice* operator &() { return &self; }
+ LDKRawInvoice* operator ->() { return &self; }
+ const LDKRawInvoice* operator &() const { return &self; }
+ const LDKRawInvoice* operator ->() const { return &self; }
+};
+class RawDataPart {
+private:
+ LDKRawDataPart self;
+public:
+ RawDataPart(const RawDataPart&) = delete;
+ RawDataPart(RawDataPart&& o) : self(o.self) { memset(&o, 0, sizeof(RawDataPart)); }
+ RawDataPart(LDKRawDataPart&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKRawDataPart)); }
+ operator LDKRawDataPart() && { LDKRawDataPart res = self; memset(&self, 0, sizeof(LDKRawDataPart)); return res; }
+ ~RawDataPart() { RawDataPart_free(self); }
+ RawDataPart& operator=(RawDataPart&& o) { RawDataPart_free(self); self = o.self; memset(&o, 0, sizeof(RawDataPart)); return *this; }
+ LDKRawDataPart* operator &() { return &self; }
+ LDKRawDataPart* operator ->() { return &self; }
+ const LDKRawDataPart* operator &() const { return &self; }
+ const LDKRawDataPart* operator ->() const { return &self; }
+};
+class PositiveTimestamp {
+private:
+ LDKPositiveTimestamp self;
+public:
+ PositiveTimestamp(const PositiveTimestamp&) = delete;
+ PositiveTimestamp(PositiveTimestamp&& o) : self(o.self) { memset(&o, 0, sizeof(PositiveTimestamp)); }
+ PositiveTimestamp(LDKPositiveTimestamp&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPositiveTimestamp)); }
+ operator LDKPositiveTimestamp() && { LDKPositiveTimestamp res = self; memset(&self, 0, sizeof(LDKPositiveTimestamp)); return res; }
+ ~PositiveTimestamp() { PositiveTimestamp_free(self); }
+ PositiveTimestamp& operator=(PositiveTimestamp&& o) { PositiveTimestamp_free(self); self = o.self; memset(&o, 0, sizeof(PositiveTimestamp)); return *this; }
+ LDKPositiveTimestamp* operator &() { return &self; }
+ LDKPositiveTimestamp* operator ->() { return &self; }
+ const LDKPositiveTimestamp* operator &() const { return &self; }
+ const LDKPositiveTimestamp* operator ->() const { return &self; }
+};
+class SiPrefix {
+private:
+ LDKSiPrefix self;
+public:
+ SiPrefix(const SiPrefix&) = delete;
+ SiPrefix(SiPrefix&& o) : self(o.self) { memset(&o, 0, sizeof(SiPrefix)); }
+ SiPrefix(LDKSiPrefix&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKSiPrefix)); }
+ operator LDKSiPrefix() && { LDKSiPrefix res = self; memset(&self, 0, sizeof(LDKSiPrefix)); return res; }
+ SiPrefix& operator=(SiPrefix&& o) { self = o.self; memset(&o, 0, sizeof(SiPrefix)); return *this; }
+ LDKSiPrefix* operator &() { return &self; }
+ LDKSiPrefix* operator ->() { return &self; }
+ const LDKSiPrefix* operator &() const { return &self; }
+ const LDKSiPrefix* operator ->() const { return &self; }
+};
+class Currency {
+private:
+ LDKCurrency self;
+public:
+ Currency(const Currency&) = delete;
+ Currency(Currency&& o) : self(o.self) { memset(&o, 0, sizeof(Currency)); }
+ Currency(LDKCurrency&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKCurrency)); }
+ operator LDKCurrency() && { LDKCurrency res = self; memset(&self, 0, sizeof(LDKCurrency)); return res; }
+ Currency& operator=(Currency&& o) { self = o.self; memset(&o, 0, sizeof(Currency)); return *this; }
+ LDKCurrency* operator &() { return &self; }
+ LDKCurrency* operator ->() { return &self; }
+ const LDKCurrency* operator &() const { return &self; }
+ const LDKCurrency* operator ->() const { return &self; }
+};
+class Sha256 {
+private:
+ LDKSha256 self;
+public:
+ Sha256(const Sha256&) = delete;
+ Sha256(Sha256&& o) : self(o.self) { memset(&o, 0, sizeof(Sha256)); }
+ Sha256(LDKSha256&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKSha256)); }
+ operator LDKSha256() && { LDKSha256 res = self; memset(&self, 0, sizeof(LDKSha256)); return res; }
+ ~Sha256() { Sha256_free(self); }
+ Sha256& operator=(Sha256&& o) { Sha256_free(self); self = o.self; memset(&o, 0, sizeof(Sha256)); return *this; }
+ LDKSha256* operator &() { return &self; }
+ LDKSha256* operator ->() { return &self; }
+ const LDKSha256* operator &() const { return &self; }
+ const LDKSha256* operator ->() const { return &self; }
+};
+class Description {
+private:
+ LDKDescription self;
+public:
+ Description(const Description&) = delete;
+ Description(Description&& o) : self(o.self) { memset(&o, 0, sizeof(Description)); }
+ Description(LDKDescription&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKDescription)); }
+ operator LDKDescription() && { LDKDescription res = self; memset(&self, 0, sizeof(LDKDescription)); return res; }
+ ~Description() { Description_free(self); }
+ Description& operator=(Description&& o) { Description_free(self); self = o.self; memset(&o, 0, sizeof(Description)); return *this; }
+ LDKDescription* operator &() { return &self; }
+ LDKDescription* operator ->() { return &self; }
+ const LDKDescription* operator &() const { return &self; }
+ const LDKDescription* operator ->() const { return &self; }
+};
+class PayeePubKey {
+private:
+ LDKPayeePubKey self;
+public:
+ PayeePubKey(const PayeePubKey&) = delete;
+ PayeePubKey(PayeePubKey&& o) : self(o.self) { memset(&o, 0, sizeof(PayeePubKey)); }
+ PayeePubKey(LDKPayeePubKey&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPayeePubKey)); }
+ operator LDKPayeePubKey() && { LDKPayeePubKey res = self; memset(&self, 0, sizeof(LDKPayeePubKey)); return res; }
+ ~PayeePubKey() { PayeePubKey_free(self); }
+ PayeePubKey& operator=(PayeePubKey&& o) { PayeePubKey_free(self); self = o.self; memset(&o, 0, sizeof(PayeePubKey)); return *this; }
+ LDKPayeePubKey* operator &() { return &self; }
+ LDKPayeePubKey* operator ->() { return &self; }
+ const LDKPayeePubKey* operator &() const { return &self; }
+ const LDKPayeePubKey* operator ->() const { return &self; }
+};
+class ExpiryTime {
+private:
+ LDKExpiryTime self;
+public:
+ ExpiryTime(const ExpiryTime&) = delete;
+ ExpiryTime(ExpiryTime&& o) : self(o.self) { memset(&o, 0, sizeof(ExpiryTime)); }
+ ExpiryTime(LDKExpiryTime&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKExpiryTime)); }
+ operator LDKExpiryTime() && { LDKExpiryTime res = self; memset(&self, 0, sizeof(LDKExpiryTime)); return res; }
+ ~ExpiryTime() { ExpiryTime_free(self); }
+ ExpiryTime& operator=(ExpiryTime&& o) { ExpiryTime_free(self); self = o.self; memset(&o, 0, sizeof(ExpiryTime)); return *this; }
+ LDKExpiryTime* operator &() { return &self; }
+ LDKExpiryTime* operator ->() { return &self; }
+ const LDKExpiryTime* operator &() const { return &self; }
+ const LDKExpiryTime* operator ->() const { return &self; }
+};
+class MinFinalCltvExpiryDelta {
+private:
+ LDKMinFinalCltvExpiryDelta self;
+public:
+ MinFinalCltvExpiryDelta(const MinFinalCltvExpiryDelta&) = delete;
+ MinFinalCltvExpiryDelta(MinFinalCltvExpiryDelta&& o) : self(o.self) { memset(&o, 0, sizeof(MinFinalCltvExpiryDelta)); }
+ MinFinalCltvExpiryDelta(LDKMinFinalCltvExpiryDelta&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKMinFinalCltvExpiryDelta)); }
+ operator LDKMinFinalCltvExpiryDelta() && { LDKMinFinalCltvExpiryDelta res = self; memset(&self, 0, sizeof(LDKMinFinalCltvExpiryDelta)); return res; }
+ ~MinFinalCltvExpiryDelta() { MinFinalCltvExpiryDelta_free(self); }
+ MinFinalCltvExpiryDelta& operator=(MinFinalCltvExpiryDelta&& o) { MinFinalCltvExpiryDelta_free(self); self = o.self; memset(&o, 0, sizeof(MinFinalCltvExpiryDelta)); return *this; }
+ LDKMinFinalCltvExpiryDelta* operator &() { return &self; }
+ LDKMinFinalCltvExpiryDelta* operator ->() { return &self; }
+ const LDKMinFinalCltvExpiryDelta* operator &() const { return &self; }
+ const LDKMinFinalCltvExpiryDelta* operator ->() const { return &self; }
+};
+class Fallback {
+private:
+ LDKFallback self;
+public:
+ Fallback(const Fallback&) = delete;
+ Fallback(Fallback&& o) : self(o.self) { memset(&o, 0, sizeof(Fallback)); }
+ Fallback(LDKFallback&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKFallback)); }
+ operator LDKFallback() && { LDKFallback res = self; memset(&self, 0, sizeof(LDKFallback)); return res; }
+ ~Fallback() { Fallback_free(self); }
+ Fallback& operator=(Fallback&& o) { Fallback_free(self); self = o.self; memset(&o, 0, sizeof(Fallback)); return *this; }
+ LDKFallback* operator &() { return &self; }
+ LDKFallback* operator ->() { return &self; }
+ const LDKFallback* operator &() const { return &self; }
+ const LDKFallback* operator ->() const { return &self; }
+};
+class InvoiceSignature {
+private:
+ LDKInvoiceSignature self;
+public:
+ InvoiceSignature(const InvoiceSignature&) = delete;
+ InvoiceSignature(InvoiceSignature&& o) : self(o.self) { memset(&o, 0, sizeof(InvoiceSignature)); }
+ InvoiceSignature(LDKInvoiceSignature&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKInvoiceSignature)); }
+ operator LDKInvoiceSignature() && { LDKInvoiceSignature res = self; memset(&self, 0, sizeof(LDKInvoiceSignature)); return res; }
+ ~InvoiceSignature() { InvoiceSignature_free(self); }
+ InvoiceSignature& operator=(InvoiceSignature&& o) { InvoiceSignature_free(self); self = o.self; memset(&o, 0, sizeof(InvoiceSignature)); return *this; }
+ LDKInvoiceSignature* operator &() { return &self; }
+ LDKInvoiceSignature* operator ->() { return &self; }
+ const LDKInvoiceSignature* operator &() const { return &self; }
+ const LDKInvoiceSignature* operator ->() const { return &self; }
+};
+class PrivateRoute {
+private:
+ LDKPrivateRoute self;
+public:
+ PrivateRoute(const PrivateRoute&) = delete;
+ PrivateRoute(PrivateRoute&& o) : self(o.self) { memset(&o, 0, sizeof(PrivateRoute)); }
+ PrivateRoute(LDKPrivateRoute&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPrivateRoute)); }
+ operator LDKPrivateRoute() && { LDKPrivateRoute res = self; memset(&self, 0, sizeof(LDKPrivateRoute)); return res; }
+ ~PrivateRoute() { PrivateRoute_free(self); }
+ PrivateRoute& operator=(PrivateRoute&& o) { PrivateRoute_free(self); self = o.self; memset(&o, 0, sizeof(PrivateRoute)); return *this; }
+ LDKPrivateRoute* operator &() { return &self; }
+ LDKPrivateRoute* operator ->() { return &self; }
+ const LDKPrivateRoute* operator &() const { return &self; }
+ const LDKPrivateRoute* operator ->() const { return &self; }
+};
+class CreationError {
+private:
+ LDKCreationError self;
+public:
+ CreationError(const CreationError&) = delete;
+ CreationError(CreationError&& o) : self(o.self) { memset(&o, 0, sizeof(CreationError)); }
+ CreationError(LDKCreationError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKCreationError)); }
+ operator LDKCreationError() && { LDKCreationError res = self; memset(&self, 0, sizeof(LDKCreationError)); return res; }
+ CreationError& operator=(CreationError&& o) { self = o.self; memset(&o, 0, sizeof(CreationError)); return *this; }
+ LDKCreationError* operator &() { return &self; }
+ LDKCreationError* operator ->() { return &self; }
+ const LDKCreationError* operator &() const { return &self; }
+ const LDKCreationError* operator ->() const { return &self; }
+};
+class SemanticError {
+private:
+ LDKSemanticError self;
+public:
+ SemanticError(const SemanticError&) = delete;
+ SemanticError(SemanticError&& o) : self(o.self) { memset(&o, 0, sizeof(SemanticError)); }
+ SemanticError(LDKSemanticError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKSemanticError)); }
+ operator LDKSemanticError() && { LDKSemanticError res = self; memset(&self, 0, sizeof(LDKSemanticError)); return res; }
+ SemanticError& operator=(SemanticError&& o) { self = o.self; memset(&o, 0, sizeof(SemanticError)); return *this; }
+ LDKSemanticError* operator &() { return &self; }
+ LDKSemanticError* operator ->() { return &self; }
+ const LDKSemanticError* operator &() const { return &self; }
+ const LDKSemanticError* operator ->() const { return &self; }
+};
+class SignOrCreationError {
+private:
+ LDKSignOrCreationError self;
+public:
+ SignOrCreationError(const SignOrCreationError&) = delete;
+ SignOrCreationError(SignOrCreationError&& o) : self(o.self) { memset(&o, 0, sizeof(SignOrCreationError)); }
+ SignOrCreationError(LDKSignOrCreationError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKSignOrCreationError)); }
+ operator LDKSignOrCreationError() && { LDKSignOrCreationError res = self; memset(&self, 0, sizeof(LDKSignOrCreationError)); return res; }
+ ~SignOrCreationError() { SignOrCreationError_free(self); }
+ SignOrCreationError& operator=(SignOrCreationError&& o) { SignOrCreationError_free(self); self = o.self; memset(&o, 0, sizeof(SignOrCreationError)); return *this; }
+ LDKSignOrCreationError* operator &() { return &self; }
+ LDKSignOrCreationError* operator ->() { return &self; }
+ const LDKSignOrCreationError* operator &() const { return &self; }
+ const LDKSignOrCreationError* operator ->() const { return &self; }
+};
+class Persister {
+private:
+ LDKPersister self;
+public:
+ Persister(const Persister&) = delete;
+ Persister(Persister&& o) : self(o.self) { memset(&o, 0, sizeof(Persister)); }
+ Persister(LDKPersister&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPersister)); }
+ operator LDKPersister() && { LDKPersister res = self; memset(&self, 0, sizeof(LDKPersister)); return res; }
+ ~Persister() { Persister_free(self); }
+ Persister& operator=(Persister&& o) { Persister_free(self); self = o.self; memset(&o, 0, sizeof(Persister)); return *this; }
+ LDKPersister* operator &() { return &self; }
+ LDKPersister* operator ->() { return &self; }
+ const LDKPersister* operator &() const { return &self; }
+ const LDKPersister* operator ->() const { return &self; }
+ /**
+ * Persist the given ['ChannelManager'] to disk, returning an error if persistence failed.
+ */
+ inline LDK::CResult_NoneErrorZ persist_manager(const struct LDKChannelManager *NONNULL_PTR channel_manager);
+ /**
+ * Persist the given [`NetworkGraph`] to disk, returning an error if persistence failed.
+ */
+ inline LDK::CResult_NoneErrorZ persist_graph(const struct LDKNetworkGraph *NONNULL_PTR network_graph);
+ /**
+ * Persist the given [`WriteableScore`] to disk, returning an error if persistence failed.
+ */
+ inline LDK::CResult_NoneErrorZ persist_scorer(const struct LDKWriteableScore *NONNULL_PTR scorer);
+};
+class DecodeError {
+private:
+ LDKDecodeError self;
+public:
+ DecodeError(const DecodeError&) = delete;
+ DecodeError(DecodeError&& o) : self(o.self) { memset(&o, 0, sizeof(DecodeError)); }
+ DecodeError(LDKDecodeError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKDecodeError)); }
+ operator LDKDecodeError() && { LDKDecodeError res = self; memset(&self, 0, sizeof(LDKDecodeError)); return res; }
+ ~DecodeError() { DecodeError_free(self); }
+ DecodeError& operator=(DecodeError&& o) { DecodeError_free(self); self = o.self; memset(&o, 0, sizeof(DecodeError)); return *this; }
+ LDKDecodeError* operator &() { return &self; }
+ LDKDecodeError* operator ->() { return &self; }
+ const LDKDecodeError* operator &() const { return &self; }
+ const LDKDecodeError* operator ->() const { return &self; }
+};
+class Init {
+private:
+ LDKInit self;
+public:
+ Init(const Init&) = delete;
+ Init(Init&& o) : self(o.self) { memset(&o, 0, sizeof(Init)); }
+ Init(LDKInit&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKInit)); }
+ operator LDKInit() && { LDKInit res = self; memset(&self, 0, sizeof(LDKInit)); return res; }
+ ~Init() { Init_free(self); }
+ Init& operator=(Init&& o) { Init_free(self); self = o.self; memset(&o, 0, sizeof(Init)); return *this; }
+ LDKInit* operator &() { return &self; }
+ LDKInit* operator ->() { return &self; }
+ const LDKInit* operator &() const { return &self; }
+ const LDKInit* operator ->() const { return &self; }
+};
+class ErrorMessage {
+private:
+ LDKErrorMessage self;
+public:
+ ErrorMessage(const ErrorMessage&) = delete;
+ ErrorMessage(ErrorMessage&& o) : self(o.self) { memset(&o, 0, sizeof(ErrorMessage)); }
+ ErrorMessage(LDKErrorMessage&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKErrorMessage)); }
+ operator LDKErrorMessage() && { LDKErrorMessage res = self; memset(&self, 0, sizeof(LDKErrorMessage)); return res; }
+ ~ErrorMessage() { ErrorMessage_free(self); }
+ ErrorMessage& operator=(ErrorMessage&& o) { ErrorMessage_free(self); self = o.self; memset(&o, 0, sizeof(ErrorMessage)); return *this; }
+ LDKErrorMessage* operator &() { return &self; }
+ LDKErrorMessage* operator ->() { return &self; }
+ const LDKErrorMessage* operator &() const { return &self; }
+ const LDKErrorMessage* operator ->() const { return &self; }
+};
+class WarningMessage {
+private:
+ LDKWarningMessage self;
+public:
+ WarningMessage(const WarningMessage&) = delete;
+ WarningMessage(WarningMessage&& o) : self(o.self) { memset(&o, 0, sizeof(WarningMessage)); }
+ WarningMessage(LDKWarningMessage&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKWarningMessage)); }
+ operator LDKWarningMessage() && { LDKWarningMessage res = self; memset(&self, 0, sizeof(LDKWarningMessage)); return res; }
+ ~WarningMessage() { WarningMessage_free(self); }
+ WarningMessage& operator=(WarningMessage&& o) { WarningMessage_free(self); self = o.self; memset(&o, 0, sizeof(WarningMessage)); return *this; }
+ LDKWarningMessage* operator &() { return &self; }
+ LDKWarningMessage* operator ->() { return &self; }
+ const LDKWarningMessage* operator &() const { return &self; }
+ const LDKWarningMessage* operator ->() const { return &self; }
+};
+class Ping {
+private:
+ LDKPing self;
+public:
+ Ping(const Ping&) = delete;
+ Ping(Ping&& o) : self(o.self) { memset(&o, 0, sizeof(Ping)); }
+ Ping(LDKPing&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPing)); }
+ operator LDKPing() && { LDKPing res = self; memset(&self, 0, sizeof(LDKPing)); return res; }
+ ~Ping() { Ping_free(self); }
+ Ping& operator=(Ping&& o) { Ping_free(self); self = o.self; memset(&o, 0, sizeof(Ping)); return *this; }
+ LDKPing* operator &() { return &self; }
+ LDKPing* operator ->() { return &self; }
+ const LDKPing* operator &() const { return &self; }
+ const LDKPing* operator ->() const { return &self; }
+};
+class Pong {
+private:
+ LDKPong self;
+public:
+ Pong(const Pong&) = delete;
+ Pong(Pong&& o) : self(o.self) { memset(&o, 0, sizeof(Pong)); }
+ Pong(LDKPong&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKPong)); }
+ operator LDKPong() && { LDKPong res = self; memset(&self, 0, sizeof(LDKPong)); return res; }
+ ~Pong() { Pong_free(self); }
+ Pong& operator=(Pong&& o) { Pong_free(self); self = o.self; memset(&o, 0, sizeof(Pong)); return *this; }
+ LDKPong* operator &() { return &self; }
+ LDKPong* operator ->() { return &self; }
+ const LDKPong* operator &() const { return &self; }
+ const LDKPong* operator ->() const { return &self; }
+};
+class OpenChannel {
+private:
+ LDKOpenChannel self;
+public:
+ OpenChannel(const OpenChannel&) = delete;
+ OpenChannel(OpenChannel&& o) : self(o.self) { memset(&o, 0, sizeof(OpenChannel)); }
+ OpenChannel(LDKOpenChannel&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKOpenChannel)); }
+ operator LDKOpenChannel() && { LDKOpenChannel res = self; memset(&self, 0, sizeof(LDKOpenChannel)); return res; }
+ ~OpenChannel() { OpenChannel_free(self); }
+ OpenChannel& operator=(OpenChannel&& o) { OpenChannel_free(self); self = o.self; memset(&o, 0, sizeof(OpenChannel)); return *this; }
+ LDKOpenChannel* operator &() { return &self; }
+ LDKOpenChannel* operator ->() { return &self; }
+ const LDKOpenChannel* operator &() const { return &self; }
+ const LDKOpenChannel* operator ->() const { return &self; }
+};
+class AcceptChannel {
+private:
+ LDKAcceptChannel self;
+public:
+ AcceptChannel(const AcceptChannel&) = delete;
+ AcceptChannel(AcceptChannel&& o) : self(o.self) { memset(&o, 0, sizeof(AcceptChannel)); }
+ AcceptChannel(LDKAcceptChannel&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKAcceptChannel)); }
+ operator LDKAcceptChannel() && { LDKAcceptChannel res = self; memset(&self, 0, sizeof(LDKAcceptChannel)); return res; }
+ ~AcceptChannel() { AcceptChannel_free(self); }
+ AcceptChannel& operator=(AcceptChannel&& o) { AcceptChannel_free(self); self = o.self; memset(&o, 0, sizeof(AcceptChannel)); return *this; }
+ LDKAcceptChannel* operator &() { return &self; }
+ LDKAcceptChannel* operator ->() { return &self; }
+ const LDKAcceptChannel* operator &() const { return &self; }
+ const LDKAcceptChannel* operator ->() const { return &self; }
+};
+class FundingCreated {
+private:
+ LDKFundingCreated self;
+public:
+ FundingCreated(const FundingCreated&) = delete;
+ FundingCreated(FundingCreated&& o) : self(o.self) { memset(&o, 0, sizeof(FundingCreated)); }
+ FundingCreated(LDKFundingCreated&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKFundingCreated)); }
+ operator LDKFundingCreated() && { LDKFundingCreated res = self; memset(&self, 0, sizeof(LDKFundingCreated)); return res; }
+ ~FundingCreated() { FundingCreated_free(self); }
+ FundingCreated& operator=(FundingCreated&& o) { FundingCreated_free(self); self = o.self; memset(&o, 0, sizeof(FundingCreated)); return *this; }
+ LDKFundingCreated* operator &() { return &self; }
+ LDKFundingCreated* operator ->() { return &self; }
+ const LDKFundingCreated* operator &() const { return &self; }
+ const LDKFundingCreated* operator ->() const { return &self; }
+};
+class FundingSigned {
+private:
+ LDKFundingSigned self;
+public:
+ FundingSigned(const FundingSigned&) = delete;
+ FundingSigned(FundingSigned&& o) : self(o.self) { memset(&o, 0, sizeof(FundingSigned)); }
+ FundingSigned(LDKFundingSigned&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKFundingSigned)); }
+ operator LDKFundingSigned() && { LDKFundingSigned res = self; memset(&self, 0, sizeof(LDKFundingSigned)); return res; }
+ ~FundingSigned() { FundingSigned_free(self); }
+ FundingSigned& operator=(FundingSigned&& o) { FundingSigned_free(self); self = o.self; memset(&o, 0, sizeof(FundingSigned)); return *this; }
+ LDKFundingSigned* operator &() { return &self; }
+ LDKFundingSigned* operator ->() { return &self; }
+ const LDKFundingSigned* operator &() const { return &self; }
+ const LDKFundingSigned* operator ->() const { return &self; }
+};
+class ChannelReady {
+private:
+ LDKChannelReady self;
+public:
+ ChannelReady(const ChannelReady&) = delete;
+ ChannelReady(ChannelReady&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelReady)); }
+ ChannelReady(LDKChannelReady&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelReady)); }
+ operator LDKChannelReady() && { LDKChannelReady res = self; memset(&self, 0, sizeof(LDKChannelReady)); return res; }
+ ~ChannelReady() { ChannelReady_free(self); }
+ ChannelReady& operator=(ChannelReady&& o) { ChannelReady_free(self); self = o.self; memset(&o, 0, sizeof(ChannelReady)); return *this; }
+ LDKChannelReady* operator &() { return &self; }
+ LDKChannelReady* operator ->() { return &self; }
+ const LDKChannelReady* operator &() const { return &self; }
+ const LDKChannelReady* operator ->() const { return &self; }
+};
+class Shutdown {
+private:
+ LDKShutdown self;
+public:
+ Shutdown(const Shutdown&) = delete;
+ Shutdown(Shutdown&& o) : self(o.self) { memset(&o, 0, sizeof(Shutdown)); }
+ Shutdown(LDKShutdown&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKShutdown)); }
+ operator LDKShutdown() && { LDKShutdown res = self; memset(&self, 0, sizeof(LDKShutdown)); return res; }
+ ~Shutdown() { Shutdown_free(self); }
+ Shutdown& operator=(Shutdown&& o) { Shutdown_free(self); self = o.self; memset(&o, 0, sizeof(Shutdown)); return *this; }
+ LDKShutdown* operator &() { return &self; }
+ LDKShutdown* operator ->() { return &self; }
+ const LDKShutdown* operator &() const { return &self; }
+ const LDKShutdown* operator ->() const { return &self; }
+};
+class ClosingSignedFeeRange {
+private:
+ LDKClosingSignedFeeRange self;
+public:
+ ClosingSignedFeeRange(const ClosingSignedFeeRange&) = delete;
+ ClosingSignedFeeRange(ClosingSignedFeeRange&& o) : self(o.self) { memset(&o, 0, sizeof(ClosingSignedFeeRange)); }
+ ClosingSignedFeeRange(LDKClosingSignedFeeRange&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKClosingSignedFeeRange)); }
+ operator LDKClosingSignedFeeRange() && { LDKClosingSignedFeeRange res = self; memset(&self, 0, sizeof(LDKClosingSignedFeeRange)); return res; }
+ ~ClosingSignedFeeRange() { ClosingSignedFeeRange_free(self); }
+ ClosingSignedFeeRange& operator=(ClosingSignedFeeRange&& o) { ClosingSignedFeeRange_free(self); self = o.self; memset(&o, 0, sizeof(ClosingSignedFeeRange)); return *this; }
+ LDKClosingSignedFeeRange* operator &() { return &self; }
+ LDKClosingSignedFeeRange* operator ->() { return &self; }
+ const LDKClosingSignedFeeRange* operator &() const { return &self; }
+ const LDKClosingSignedFeeRange* operator ->() const { return &self; }
+};
+class ClosingSigned {
+private:
+ LDKClosingSigned self;
+public:
+ ClosingSigned(const ClosingSigned&) = delete;
+ ClosingSigned(ClosingSigned&& o) : self(o.self) { memset(&o, 0, sizeof(ClosingSigned)); }
+ ClosingSigned(LDKClosingSigned&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKClosingSigned)); }
+ operator LDKClosingSigned() && { LDKClosingSigned res = self; memset(&self, 0, sizeof(LDKClosingSigned)); return res; }
+ ~ClosingSigned() { ClosingSigned_free(self); }
+ ClosingSigned& operator=(ClosingSigned&& o) { ClosingSigned_free(self); self = o.self; memset(&o, 0, sizeof(ClosingSigned)); return *this; }
+ LDKClosingSigned* operator &() { return &self; }
+ LDKClosingSigned* operator ->() { return &self; }
+ const LDKClosingSigned* operator &() const { return &self; }
+ const LDKClosingSigned* operator ->() const { return &self; }
+};
+class UpdateAddHTLC {
+private:
+ LDKUpdateAddHTLC self;
+public:
+ UpdateAddHTLC(const UpdateAddHTLC&) = delete;
+ UpdateAddHTLC(UpdateAddHTLC&& o) : self(o.self) { memset(&o, 0, sizeof(UpdateAddHTLC)); }
+ UpdateAddHTLC(LDKUpdateAddHTLC&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUpdateAddHTLC)); }
+ operator LDKUpdateAddHTLC() && { LDKUpdateAddHTLC res = self; memset(&self, 0, sizeof(LDKUpdateAddHTLC)); return res; }
+ ~UpdateAddHTLC() { UpdateAddHTLC_free(self); }
+ UpdateAddHTLC& operator=(UpdateAddHTLC&& o) { UpdateAddHTLC_free(self); self = o.self; memset(&o, 0, sizeof(UpdateAddHTLC)); return *this; }
+ LDKUpdateAddHTLC* operator &() { return &self; }
+ LDKUpdateAddHTLC* operator ->() { return &self; }
+ const LDKUpdateAddHTLC* operator &() const { return &self; }
+ const LDKUpdateAddHTLC* operator ->() const { return &self; }
+};
+class OnionMessage {
+private:
+ LDKOnionMessage self;
+public:
+ OnionMessage(const OnionMessage&) = delete;
+ OnionMessage(OnionMessage&& o) : self(o.self) { memset(&o, 0, sizeof(OnionMessage)); }
+ OnionMessage(LDKOnionMessage&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKOnionMessage)); }
+ operator LDKOnionMessage() && { LDKOnionMessage res = self; memset(&self, 0, sizeof(LDKOnionMessage)); return res; }
+ ~OnionMessage() { OnionMessage_free(self); }
+ OnionMessage& operator=(OnionMessage&& o) { OnionMessage_free(self); self = o.self; memset(&o, 0, sizeof(OnionMessage)); return *this; }
+ LDKOnionMessage* operator &() { return &self; }
+ LDKOnionMessage* operator ->() { return &self; }
+ const LDKOnionMessage* operator &() const { return &self; }
+ const LDKOnionMessage* operator ->() const { return &self; }
+};
+class UpdateFulfillHTLC {
+private:
+ LDKUpdateFulfillHTLC self;
+public:
+ UpdateFulfillHTLC(const UpdateFulfillHTLC&) = delete;
+ UpdateFulfillHTLC(UpdateFulfillHTLC&& o) : self(o.self) { memset(&o, 0, sizeof(UpdateFulfillHTLC)); }
+ UpdateFulfillHTLC(LDKUpdateFulfillHTLC&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUpdateFulfillHTLC)); }
+ operator LDKUpdateFulfillHTLC() && { LDKUpdateFulfillHTLC res = self; memset(&self, 0, sizeof(LDKUpdateFulfillHTLC)); return res; }
+ ~UpdateFulfillHTLC() { UpdateFulfillHTLC_free(self); }
+ UpdateFulfillHTLC& operator=(UpdateFulfillHTLC&& o) { UpdateFulfillHTLC_free(self); self = o.self; memset(&o, 0, sizeof(UpdateFulfillHTLC)); return *this; }
+ LDKUpdateFulfillHTLC* operator &() { return &self; }
+ LDKUpdateFulfillHTLC* operator ->() { return &self; }
+ const LDKUpdateFulfillHTLC* operator &() const { return &self; }
+ const LDKUpdateFulfillHTLC* operator ->() const { return &self; }
+};
+class UpdateFailHTLC {
+private:
+ LDKUpdateFailHTLC self;
+public:
+ UpdateFailHTLC(const UpdateFailHTLC&) = delete;
+ UpdateFailHTLC(UpdateFailHTLC&& o) : self(o.self) { memset(&o, 0, sizeof(UpdateFailHTLC)); }
+ UpdateFailHTLC(LDKUpdateFailHTLC&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUpdateFailHTLC)); }
+ operator LDKUpdateFailHTLC() && { LDKUpdateFailHTLC res = self; memset(&self, 0, sizeof(LDKUpdateFailHTLC)); return res; }
+ ~UpdateFailHTLC() { UpdateFailHTLC_free(self); }
+ UpdateFailHTLC& operator=(UpdateFailHTLC&& o) { UpdateFailHTLC_free(self); self = o.self; memset(&o, 0, sizeof(UpdateFailHTLC)); return *this; }
+ LDKUpdateFailHTLC* operator &() { return &self; }
+ LDKUpdateFailHTLC* operator ->() { return &self; }
+ const LDKUpdateFailHTLC* operator &() const { return &self; }
+ const LDKUpdateFailHTLC* operator ->() const { return &self; }
+};
+class UpdateFailMalformedHTLC {
+private:
+ LDKUpdateFailMalformedHTLC self;
+public:
+ UpdateFailMalformedHTLC(const UpdateFailMalformedHTLC&) = delete;
+ UpdateFailMalformedHTLC(UpdateFailMalformedHTLC&& o) : self(o.self) { memset(&o, 0, sizeof(UpdateFailMalformedHTLC)); }
+ UpdateFailMalformedHTLC(LDKUpdateFailMalformedHTLC&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUpdateFailMalformedHTLC)); }
+ operator LDKUpdateFailMalformedHTLC() && { LDKUpdateFailMalformedHTLC res = self; memset(&self, 0, sizeof(LDKUpdateFailMalformedHTLC)); return res; }
+ ~UpdateFailMalformedHTLC() { UpdateFailMalformedHTLC_free(self); }
+ UpdateFailMalformedHTLC& operator=(UpdateFailMalformedHTLC&& o) { UpdateFailMalformedHTLC_free(self); self = o.self; memset(&o, 0, sizeof(UpdateFailMalformedHTLC)); return *this; }
+ LDKUpdateFailMalformedHTLC* operator &() { return &self; }
+ LDKUpdateFailMalformedHTLC* operator ->() { return &self; }
+ const LDKUpdateFailMalformedHTLC* operator &() const { return &self; }
+ const LDKUpdateFailMalformedHTLC* operator ->() const { return &self; }
+};
+class CommitmentSigned {
+private:
+ LDKCommitmentSigned self;
+public:
+ CommitmentSigned(const CommitmentSigned&) = delete;
+ CommitmentSigned(CommitmentSigned&& o) : self(o.self) { memset(&o, 0, sizeof(CommitmentSigned)); }
+ CommitmentSigned(LDKCommitmentSigned&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKCommitmentSigned)); }
+ operator LDKCommitmentSigned() && { LDKCommitmentSigned res = self; memset(&self, 0, sizeof(LDKCommitmentSigned)); return res; }
+ ~CommitmentSigned() { CommitmentSigned_free(self); }
+ CommitmentSigned& operator=(CommitmentSigned&& o) { CommitmentSigned_free(self); self = o.self; memset(&o, 0, sizeof(CommitmentSigned)); return *this; }
+ LDKCommitmentSigned* operator &() { return &self; }
+ LDKCommitmentSigned* operator ->() { return &self; }
+ const LDKCommitmentSigned* operator &() const { return &self; }
+ const LDKCommitmentSigned* operator ->() const { return &self; }
+};
+class RevokeAndACK {
+private:
+ LDKRevokeAndACK self;
+public:
+ RevokeAndACK(const RevokeAndACK&) = delete;
+ RevokeAndACK(RevokeAndACK&& o) : self(o.self) { memset(&o, 0, sizeof(RevokeAndACK)); }
+ RevokeAndACK(LDKRevokeAndACK&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKRevokeAndACK)); }
+ operator LDKRevokeAndACK() && { LDKRevokeAndACK res = self; memset(&self, 0, sizeof(LDKRevokeAndACK)); return res; }
+ ~RevokeAndACK() { RevokeAndACK_free(self); }
+ RevokeAndACK& operator=(RevokeAndACK&& o) { RevokeAndACK_free(self); self = o.self; memset(&o, 0, sizeof(RevokeAndACK)); return *this; }
+ LDKRevokeAndACK* operator &() { return &self; }
+ LDKRevokeAndACK* operator ->() { return &self; }
+ const LDKRevokeAndACK* operator &() const { return &self; }
+ const LDKRevokeAndACK* operator ->() const { return &self; }
+};
+class UpdateFee {
+private:
+ LDKUpdateFee self;
+public:
+ UpdateFee(const UpdateFee&) = delete;
+ UpdateFee(UpdateFee&& o) : self(o.self) { memset(&o, 0, sizeof(UpdateFee)); }
+ UpdateFee(LDKUpdateFee&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUpdateFee)); }
+ operator LDKUpdateFee() && { LDKUpdateFee res = self; memset(&self, 0, sizeof(LDKUpdateFee)); return res; }
+ ~UpdateFee() { UpdateFee_free(self); }
+ UpdateFee& operator=(UpdateFee&& o) { UpdateFee_free(self); self = o.self; memset(&o, 0, sizeof(UpdateFee)); return *this; }
+ LDKUpdateFee* operator &() { return &self; }
+ LDKUpdateFee* operator ->() { return &self; }
+ const LDKUpdateFee* operator &() const { return &self; }
+ const LDKUpdateFee* operator ->() const { return &self; }
+};
+class DataLossProtect {
+private:
+ LDKDataLossProtect self;
+public:
+ DataLossProtect(const DataLossProtect&) = delete;
+ DataLossProtect(DataLossProtect&& o) : self(o.self) { memset(&o, 0, sizeof(DataLossProtect)); }
+ DataLossProtect(LDKDataLossProtect&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKDataLossProtect)); }
+ operator LDKDataLossProtect() && { LDKDataLossProtect res = self; memset(&self, 0, sizeof(LDKDataLossProtect)); return res; }
+ ~DataLossProtect() { DataLossProtect_free(self); }
+ DataLossProtect& operator=(DataLossProtect&& o) { DataLossProtect_free(self); self = o.self; memset(&o, 0, sizeof(DataLossProtect)); return *this; }
+ LDKDataLossProtect* operator &() { return &self; }
+ LDKDataLossProtect* operator ->() { return &self; }
+ const LDKDataLossProtect* operator &() const { return &self; }
+ const LDKDataLossProtect* operator ->() const { return &self; }
+};
+class ChannelReestablish {
+private:
+ LDKChannelReestablish self;
+public:
+ ChannelReestablish(const ChannelReestablish&) = delete;
+ ChannelReestablish(ChannelReestablish&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelReestablish)); }
+ ChannelReestablish(LDKChannelReestablish&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelReestablish)); }
+ operator LDKChannelReestablish() && { LDKChannelReestablish res = self; memset(&self, 0, sizeof(LDKChannelReestablish)); return res; }
+ ~ChannelReestablish() { ChannelReestablish_free(self); }
+ ChannelReestablish& operator=(ChannelReestablish&& o) { ChannelReestablish_free(self); self = o.self; memset(&o, 0, sizeof(ChannelReestablish)); return *this; }
+ LDKChannelReestablish* operator &() { return &self; }
+ LDKChannelReestablish* operator ->() { return &self; }
+ const LDKChannelReestablish* operator &() const { return &self; }
+ const LDKChannelReestablish* operator ->() const { return &self; }
+};
+class AnnouncementSignatures {
+private:
+ LDKAnnouncementSignatures self;
+public:
+ AnnouncementSignatures(const AnnouncementSignatures&) = delete;
+ AnnouncementSignatures(AnnouncementSignatures&& o) : self(o.self) { memset(&o, 0, sizeof(AnnouncementSignatures)); }
+ AnnouncementSignatures(LDKAnnouncementSignatures&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKAnnouncementSignatures)); }
+ operator LDKAnnouncementSignatures() && { LDKAnnouncementSignatures res = self; memset(&self, 0, sizeof(LDKAnnouncementSignatures)); return res; }
+ ~AnnouncementSignatures() { AnnouncementSignatures_free(self); }
+ AnnouncementSignatures& operator=(AnnouncementSignatures&& o) { AnnouncementSignatures_free(self); self = o.self; memset(&o, 0, sizeof(AnnouncementSignatures)); return *this; }
+ LDKAnnouncementSignatures* operator &() { return &self; }
+ LDKAnnouncementSignatures* operator ->() { return &self; }
+ const LDKAnnouncementSignatures* operator &() const { return &self; }
+ const LDKAnnouncementSignatures* operator ->() const { return &self; }
+};
+class NetAddress {
+private:
+ LDKNetAddress self;
+public:
+ NetAddress(const NetAddress&) = delete;
+ NetAddress(NetAddress&& o) : self(o.self) { memset(&o, 0, sizeof(NetAddress)); }
+ NetAddress(LDKNetAddress&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKNetAddress)); }
+ operator LDKNetAddress() && { LDKNetAddress res = self; memset(&self, 0, sizeof(LDKNetAddress)); return res; }
+ ~NetAddress() { NetAddress_free(self); }
+ NetAddress& operator=(NetAddress&& o) { NetAddress_free(self); self = o.self; memset(&o, 0, sizeof(NetAddress)); return *this; }
+ LDKNetAddress* operator &() { return &self; }
+ LDKNetAddress* operator ->() { return &self; }
+ const LDKNetAddress* operator &() const { return &self; }
+ const LDKNetAddress* operator ->() const { return &self; }
+};
+class UnsignedGossipMessage {
+private:
+ LDKUnsignedGossipMessage self;
+public:
+ UnsignedGossipMessage(const UnsignedGossipMessage&) = delete;
+ UnsignedGossipMessage(UnsignedGossipMessage&& o) : self(o.self) { memset(&o, 0, sizeof(UnsignedGossipMessage)); }
+ UnsignedGossipMessage(LDKUnsignedGossipMessage&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUnsignedGossipMessage)); }
+ operator LDKUnsignedGossipMessage() && { LDKUnsignedGossipMessage res = self; memset(&self, 0, sizeof(LDKUnsignedGossipMessage)); return res; }
+ ~UnsignedGossipMessage() { UnsignedGossipMessage_free(self); }
+ UnsignedGossipMessage& operator=(UnsignedGossipMessage&& o) { UnsignedGossipMessage_free(self); self = o.self; memset(&o, 0, sizeof(UnsignedGossipMessage)); return *this; }
+ LDKUnsignedGossipMessage* operator &() { return &self; }
+ LDKUnsignedGossipMessage* operator ->() { return &self; }
+ const LDKUnsignedGossipMessage* operator &() const { return &self; }
+ const LDKUnsignedGossipMessage* operator ->() const { return &self; }
+};
+class UnsignedNodeAnnouncement {
+private:
+ LDKUnsignedNodeAnnouncement self;
+public:
+ UnsignedNodeAnnouncement(const UnsignedNodeAnnouncement&) = delete;
+ UnsignedNodeAnnouncement(UnsignedNodeAnnouncement&& o) : self(o.self) { memset(&o, 0, sizeof(UnsignedNodeAnnouncement)); }
+ UnsignedNodeAnnouncement(LDKUnsignedNodeAnnouncement&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUnsignedNodeAnnouncement)); }
+ operator LDKUnsignedNodeAnnouncement() && { LDKUnsignedNodeAnnouncement res = self; memset(&self, 0, sizeof(LDKUnsignedNodeAnnouncement)); return res; }
+ ~UnsignedNodeAnnouncement() { UnsignedNodeAnnouncement_free(self); }
+ UnsignedNodeAnnouncement& operator=(UnsignedNodeAnnouncement&& o) { UnsignedNodeAnnouncement_free(self); self = o.self; memset(&o, 0, sizeof(UnsignedNodeAnnouncement)); return *this; }
+ LDKUnsignedNodeAnnouncement* operator &() { return &self; }
+ LDKUnsignedNodeAnnouncement* operator ->() { return &self; }
+ const LDKUnsignedNodeAnnouncement* operator &() const { return &self; }
+ const LDKUnsignedNodeAnnouncement* operator ->() const { return &self; }
+};
+class NodeAnnouncement {
+private:
+ LDKNodeAnnouncement self;
+public:
+ NodeAnnouncement(const NodeAnnouncement&) = delete;
+ NodeAnnouncement(NodeAnnouncement&& o) : self(o.self) { memset(&o, 0, sizeof(NodeAnnouncement)); }
+ NodeAnnouncement(LDKNodeAnnouncement&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKNodeAnnouncement)); }
+ operator LDKNodeAnnouncement() && { LDKNodeAnnouncement res = self; memset(&self, 0, sizeof(LDKNodeAnnouncement)); return res; }
+ ~NodeAnnouncement() { NodeAnnouncement_free(self); }
+ NodeAnnouncement& operator=(NodeAnnouncement&& o) { NodeAnnouncement_free(self); self = o.self; memset(&o, 0, sizeof(NodeAnnouncement)); return *this; }
+ LDKNodeAnnouncement* operator &() { return &self; }
+ LDKNodeAnnouncement* operator ->() { return &self; }
+ const LDKNodeAnnouncement* operator &() const { return &self; }
+ const LDKNodeAnnouncement* operator ->() const { return &self; }
+};
+class UnsignedChannelAnnouncement {
+private:
+ LDKUnsignedChannelAnnouncement self;
+public:
+ UnsignedChannelAnnouncement(const UnsignedChannelAnnouncement&) = delete;
+ UnsignedChannelAnnouncement(UnsignedChannelAnnouncement&& o) : self(o.self) { memset(&o, 0, sizeof(UnsignedChannelAnnouncement)); }
+ UnsignedChannelAnnouncement(LDKUnsignedChannelAnnouncement&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUnsignedChannelAnnouncement)); }
+ operator LDKUnsignedChannelAnnouncement() && { LDKUnsignedChannelAnnouncement res = self; memset(&self, 0, sizeof(LDKUnsignedChannelAnnouncement)); return res; }
+ ~UnsignedChannelAnnouncement() { UnsignedChannelAnnouncement_free(self); }
+ UnsignedChannelAnnouncement& operator=(UnsignedChannelAnnouncement&& o) { UnsignedChannelAnnouncement_free(self); self = o.self; memset(&o, 0, sizeof(UnsignedChannelAnnouncement)); return *this; }
+ LDKUnsignedChannelAnnouncement* operator &() { return &self; }
+ LDKUnsignedChannelAnnouncement* operator ->() { return &self; }
+ const LDKUnsignedChannelAnnouncement* operator &() const { return &self; }
+ const LDKUnsignedChannelAnnouncement* operator ->() const { return &self; }
+};
+class ChannelAnnouncement {
+private:
+ LDKChannelAnnouncement self;
+public:
+ ChannelAnnouncement(const ChannelAnnouncement&) = delete;
+ ChannelAnnouncement(ChannelAnnouncement&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelAnnouncement)); }
+ ChannelAnnouncement(LDKChannelAnnouncement&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelAnnouncement)); }
+ operator LDKChannelAnnouncement() && { LDKChannelAnnouncement res = self; memset(&self, 0, sizeof(LDKChannelAnnouncement)); return res; }
+ ~ChannelAnnouncement() { ChannelAnnouncement_free(self); }
+ ChannelAnnouncement& operator=(ChannelAnnouncement&& o) { ChannelAnnouncement_free(self); self = o.self; memset(&o, 0, sizeof(ChannelAnnouncement)); return *this; }
+ LDKChannelAnnouncement* operator &() { return &self; }
+ LDKChannelAnnouncement* operator ->() { return &self; }
+ const LDKChannelAnnouncement* operator &() const { return &self; }
+ const LDKChannelAnnouncement* operator ->() const { return &self; }
+};
+class UnsignedChannelUpdate {
+private:
+ LDKUnsignedChannelUpdate self;
+public:
+ UnsignedChannelUpdate(const UnsignedChannelUpdate&) = delete;
+ UnsignedChannelUpdate(UnsignedChannelUpdate&& o) : self(o.self) { memset(&o, 0, sizeof(UnsignedChannelUpdate)); }
+ UnsignedChannelUpdate(LDKUnsignedChannelUpdate&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKUnsignedChannelUpdate)); }
+ operator LDKUnsignedChannelUpdate() && { LDKUnsignedChannelUpdate res = self; memset(&self, 0, sizeof(LDKUnsignedChannelUpdate)); return res; }
+ ~UnsignedChannelUpdate() { UnsignedChannelUpdate_free(self); }
+ UnsignedChannelUpdate& operator=(UnsignedChannelUpdate&& o) { UnsignedChannelUpdate_free(self); self = o.self; memset(&o, 0, sizeof(UnsignedChannelUpdate)); return *this; }
+ LDKUnsignedChannelUpdate* operator &() { return &self; }
+ LDKUnsignedChannelUpdate* operator ->() { return &self; }
+ const LDKUnsignedChannelUpdate* operator &() const { return &self; }
+ const LDKUnsignedChannelUpdate* operator ->() const { return &self; }
+};
+class ChannelUpdate {
+private:
+ LDKChannelUpdate self;
+public:
+ ChannelUpdate(const ChannelUpdate&) = delete;
+ ChannelUpdate(ChannelUpdate&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelUpdate)); }
+ ChannelUpdate(LDKChannelUpdate&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelUpdate)); }
+ operator LDKChannelUpdate() && { LDKChannelUpdate res = self; memset(&self, 0, sizeof(LDKChannelUpdate)); return res; }
+ ~ChannelUpdate() { ChannelUpdate_free(self); }
+ ChannelUpdate& operator=(ChannelUpdate&& o) { ChannelUpdate_free(self); self = o.self; memset(&o, 0, sizeof(ChannelUpdate)); return *this; }
+ LDKChannelUpdate* operator &() { return &self; }
+ LDKChannelUpdate* operator ->() { return &self; }
+ const LDKChannelUpdate* operator &() const { return &self; }
+ const LDKChannelUpdate* operator ->() const { return &self; }
+};
+class QueryChannelRange {
+private:
+ LDKQueryChannelRange self;
+public:
+ QueryChannelRange(const QueryChannelRange&) = delete;
+ QueryChannelRange(QueryChannelRange&& o) : self(o.self) { memset(&o, 0, sizeof(QueryChannelRange)); }
+ QueryChannelRange(LDKQueryChannelRange&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKQueryChannelRange)); }
+ operator LDKQueryChannelRange() && { LDKQueryChannelRange res = self; memset(&self, 0, sizeof(LDKQueryChannelRange)); return res; }
+ ~QueryChannelRange() { QueryChannelRange_free(self); }
+ QueryChannelRange& operator=(QueryChannelRange&& o) { QueryChannelRange_free(self); self = o.self; memset(&o, 0, sizeof(QueryChannelRange)); return *this; }
+ LDKQueryChannelRange* operator &() { return &self; }
+ LDKQueryChannelRange* operator ->() { return &self; }
+ const LDKQueryChannelRange* operator &() const { return &self; }
+ const LDKQueryChannelRange* operator ->() const { return &self; }
+};
+class ReplyChannelRange {
+private:
+ LDKReplyChannelRange self;
+public:
+ ReplyChannelRange(const ReplyChannelRange&) = delete;
+ ReplyChannelRange(ReplyChannelRange&& o) : self(o.self) { memset(&o, 0, sizeof(ReplyChannelRange)); }
+ ReplyChannelRange(LDKReplyChannelRange&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKReplyChannelRange)); }
+ operator LDKReplyChannelRange() && { LDKReplyChannelRange res = self; memset(&self, 0, sizeof(LDKReplyChannelRange)); return res; }
+ ~ReplyChannelRange() { ReplyChannelRange_free(self); }
+ ReplyChannelRange& operator=(ReplyChannelRange&& o) { ReplyChannelRange_free(self); self = o.self; memset(&o, 0, sizeof(ReplyChannelRange)); return *this; }
+ LDKReplyChannelRange* operator &() { return &self; }
+ LDKReplyChannelRange* operator ->() { return &self; }
+ const LDKReplyChannelRange* operator &() const { return &self; }
+ const LDKReplyChannelRange* operator ->() const { return &self; }
+};
+class QueryShortChannelIds {
+private:
+ LDKQueryShortChannelIds self;
+public:
+ QueryShortChannelIds(const QueryShortChannelIds&) = delete;
+ QueryShortChannelIds(QueryShortChannelIds&& o) : self(o.self) { memset(&o, 0, sizeof(QueryShortChannelIds)); }
+ QueryShortChannelIds(LDKQueryShortChannelIds&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKQueryShortChannelIds)); }
+ operator LDKQueryShortChannelIds() && { LDKQueryShortChannelIds res = self; memset(&self, 0, sizeof(LDKQueryShortChannelIds)); return res; }
+ ~QueryShortChannelIds() { QueryShortChannelIds_free(self); }
+ QueryShortChannelIds& operator=(QueryShortChannelIds&& o) { QueryShortChannelIds_free(self); self = o.self; memset(&o, 0, sizeof(QueryShortChannelIds)); return *this; }
+ LDKQueryShortChannelIds* operator &() { return &self; }
+ LDKQueryShortChannelIds* operator ->() { return &self; }
+ const LDKQueryShortChannelIds* operator &() const { return &self; }
+ const LDKQueryShortChannelIds* operator ->() const { return &self; }
+};
+class ReplyShortChannelIdsEnd {
+private:
+ LDKReplyShortChannelIdsEnd self;
+public:
+ ReplyShortChannelIdsEnd(const ReplyShortChannelIdsEnd&) = delete;
+ ReplyShortChannelIdsEnd(ReplyShortChannelIdsEnd&& o) : self(o.self) { memset(&o, 0, sizeof(ReplyShortChannelIdsEnd)); }
+ ReplyShortChannelIdsEnd(LDKReplyShortChannelIdsEnd&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKReplyShortChannelIdsEnd)); }
+ operator LDKReplyShortChannelIdsEnd() && { LDKReplyShortChannelIdsEnd res = self; memset(&self, 0, sizeof(LDKReplyShortChannelIdsEnd)); return res; }
+ ~ReplyShortChannelIdsEnd() { ReplyShortChannelIdsEnd_free(self); }
+ ReplyShortChannelIdsEnd& operator=(ReplyShortChannelIdsEnd&& o) { ReplyShortChannelIdsEnd_free(self); self = o.self; memset(&o, 0, sizeof(ReplyShortChannelIdsEnd)); return *this; }
+ LDKReplyShortChannelIdsEnd* operator &() { return &self; }
+ LDKReplyShortChannelIdsEnd* operator ->() { return &self; }
+ const LDKReplyShortChannelIdsEnd* operator &() const { return &self; }
+ const LDKReplyShortChannelIdsEnd* operator ->() const { return &self; }
+};
+class GossipTimestampFilter {
+private:
+ LDKGossipTimestampFilter self;
+public:
+ GossipTimestampFilter(const GossipTimestampFilter&) = delete;
+ GossipTimestampFilter(GossipTimestampFilter&& o) : self(o.self) { memset(&o, 0, sizeof(GossipTimestampFilter)); }
+ GossipTimestampFilter(LDKGossipTimestampFilter&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKGossipTimestampFilter)); }
+ operator LDKGossipTimestampFilter() && { LDKGossipTimestampFilter res = self; memset(&self, 0, sizeof(LDKGossipTimestampFilter)); return res; }
+ ~GossipTimestampFilter() { GossipTimestampFilter_free(self); }
+ GossipTimestampFilter& operator=(GossipTimestampFilter&& o) { GossipTimestampFilter_free(self); self = o.self; memset(&o, 0, sizeof(GossipTimestampFilter)); return *this; }
+ LDKGossipTimestampFilter* operator &() { return &self; }
+ LDKGossipTimestampFilter* operator ->() { return &self; }
+ const LDKGossipTimestampFilter* operator &() const { return &self; }
+ const LDKGossipTimestampFilter* operator ->() const { return &self; }
+};
+class ErrorAction {
+private:
+ LDKErrorAction self;
+public:
+ ErrorAction(const ErrorAction&) = delete;
+ ErrorAction(ErrorAction&& o) : self(o.self) { memset(&o, 0, sizeof(ErrorAction)); }
+ ErrorAction(LDKErrorAction&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKErrorAction)); }
+ operator LDKErrorAction() && { LDKErrorAction res = self; memset(&self, 0, sizeof(LDKErrorAction)); return res; }
+ ~ErrorAction() { ErrorAction_free(self); }
+ ErrorAction& operator=(ErrorAction&& o) { ErrorAction_free(self); self = o.self; memset(&o, 0, sizeof(ErrorAction)); return *this; }
+ LDKErrorAction* operator &() { return &self; }
+ LDKErrorAction* operator ->() { return &self; }
+ const LDKErrorAction* operator &() const { return &self; }
+ const LDKErrorAction* operator ->() const { return &self; }
+};
+class LightningError {
+private:
+ LDKLightningError self;
+public:
+ LightningError(const LightningError&) = delete;
+ LightningError(LightningError&& o) : self(o.self) { memset(&o, 0, sizeof(LightningError)); }
+ LightningError(LDKLightningError&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKLightningError)); }
+ operator LDKLightningError() && { LDKLightningError res = self; memset(&self, 0, sizeof(LDKLightningError)); return res; }
+ ~LightningError() { LightningError_free(self); }
+ LightningError& operator=(LightningError&& o) { LightningError_free(self); self = o.self; memset(&o, 0, sizeof(LightningError)); return *this; }
+ LDKLightningError* operator &() { return &self; }
+ LDKLightningError* operator ->() { return &self; }
+ const LDKLightningError* operator &() const { return &self; }
+ const LDKLightningError* operator ->() const { return &self; }
+};
+class CommitmentUpdate {
+private:
+ LDKCommitmentUpdate self;
+public:
+ CommitmentUpdate(const CommitmentUpdate&) = delete;
+ CommitmentUpdate(CommitmentUpdate&& o) : self(o.self) { memset(&o, 0, sizeof(CommitmentUpdate)); }
+ CommitmentUpdate(LDKCommitmentUpdate&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKCommitmentUpdate)); }
+ operator LDKCommitmentUpdate() && { LDKCommitmentUpdate res = self; memset(&self, 0, sizeof(LDKCommitmentUpdate)); return res; }
+ ~CommitmentUpdate() { CommitmentUpdate_free(self); }
+ CommitmentUpdate& operator=(CommitmentUpdate&& o) { CommitmentUpdate_free(self); self = o.self; memset(&o, 0, sizeof(CommitmentUpdate)); return *this; }
+ LDKCommitmentUpdate* operator &() { return &self; }
+ LDKCommitmentUpdate* operator ->() { return &self; }
+ const LDKCommitmentUpdate* operator &() const { return &self; }
+ const LDKCommitmentUpdate* operator ->() const { return &self; }
+};
+class ChannelMessageHandler {
+private:
+ LDKChannelMessageHandler self;
+public:
+ ChannelMessageHandler(const ChannelMessageHandler&) = delete;
+ ChannelMessageHandler(ChannelMessageHandler&& o) : self(o.self) { memset(&o, 0, sizeof(ChannelMessageHandler)); }
+ ChannelMessageHandler(LDKChannelMessageHandler&& m_self) : self(m_self) { memset(&m_self, 0, sizeof(LDKChannelMessageHandler)); }
+ operator LDKChannelMessageHandler() && { LDKChannelMessageHandler res = self; memset(&self, 0, sizeof(LDKChannelMessageHandler)); return res; }
+ ~ChannelMessageHandler() { ChannelMessageHandler_free(self); }
+ ChannelMessageHandler& operator=(ChannelMessageHandler&& o) { ChannelMessageHandler_free(self); self = o.self; memset(&o, 0, sizeof(ChannelMessageHandler)); return *this; }
+ LDKChannelMessageHandler* operator &() { return &self; }
+ LDKChannelMessageHandler* operator ->() { return &self; }
+ const LDKChannelMessageHandler* operator &() const { return &self; }
+ const LDKChannelMessageHandler* operator ->() const { return &self; }
+ /**
+ * Handle an incoming `open_channel` message from the given peer.