Files
breez-sdk-liquid/lib/core/src/frb_generated.io.rs
Ross Savage 6b78919df8 Add sign_message and check_message (#443)
* Add sign and check message methods

* Use lightning message_signing module to verify the message signature

* Use hash engine
2024-08-29 08:42:16 +02:00

4308 lines
142 KiB
Rust

// This file is automatically generated, so please do not edit it.
// Generated by `flutter_rust_bridge`@ 2.0.0.
// Section: imports
use super::*;
use crate::bindings::*;
use crate::model::EventListener;
use flutter_rust_bridge::for_generated::byteorder::{NativeEndian, ReadBytesExt, WriteBytesExt};
use flutter_rust_bridge::for_generated::{transform_result_dco, Lifetimeable, Lockable};
use flutter_rust_bridge::{Handler, IntoIntoDart};
// Section: boilerplate
flutter_rust_bridge::frb_generated_boilerplate_io!();
// Section: dart2rust
impl CstDecode<flutter_rust_bridge::for_generated::anyhow::Error>
for *mut wire_cst_list_prim_u_8_strict
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> flutter_rust_bridge::for_generated::anyhow::Error {
unimplemented!()
}
}
impl CstDecode<BindingLiquidSdk> for usize {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> BindingLiquidSdk {
flutter_rust_bridge::for_generated::rust_auto_opaque_decode_owned(CstDecode::<
RustOpaqueNom<
flutter_rust_bridge::for_generated::RustAutoOpaqueInner<BindingLiquidSdk>,
>,
>::cst_decode(
self
))
}
}
impl
CstDecode<
RustOpaqueNom<flutter_rust_bridge::for_generated::RustAutoOpaqueInner<BindingLiquidSdk>>,
> for usize
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(
self,
) -> RustOpaqueNom<flutter_rust_bridge::for_generated::RustAutoOpaqueInner<BindingLiquidSdk>>
{
unsafe { decode_rust_opaque_nom(self as _) }
}
}
impl CstDecode<StreamSink<crate::model::LogEntry, flutter_rust_bridge::for_generated::DcoCodec>>
for *mut wire_cst_list_prim_u_8_strict
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(
self,
) -> StreamSink<crate::model::LogEntry, flutter_rust_bridge::for_generated::DcoCodec> {
let raw: String = self.cst_decode();
StreamSink::deserialize(raw)
}
}
impl CstDecode<StreamSink<crate::model::SdkEvent, flutter_rust_bridge::for_generated::DcoCodec>>
for *mut wire_cst_list_prim_u_8_strict
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(
self,
) -> StreamSink<crate::model::SdkEvent, flutter_rust_bridge::for_generated::DcoCodec> {
let raw: String = self.cst_decode();
StreamSink::deserialize(raw)
}
}
impl CstDecode<String> for *mut wire_cst_list_prim_u_8_strict {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> String {
let vec: Vec<u8> = self.cst_decode();
String::from_utf8(vec).unwrap()
}
}
impl CstDecode<crate::bindings::AesSuccessActionDataDecrypted>
for wire_cst_aes_success_action_data_decrypted
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::AesSuccessActionDataDecrypted {
crate::bindings::AesSuccessActionDataDecrypted {
description: self.description.cst_decode(),
plaintext: self.plaintext.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::AesSuccessActionDataResult>
for wire_cst_aes_success_action_data_result
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::AesSuccessActionDataResult {
match self.tag {
0 => {
let ans = unsafe { self.kind.Decrypted };
crate::bindings::AesSuccessActionDataResult::Decrypted {
data: ans.data.cst_decode(),
}
}
1 => {
let ans = unsafe { self.kind.ErrorStatus };
crate::bindings::AesSuccessActionDataResult::ErrorStatus {
reason: ans.reason.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::model::BackupRequest> for wire_cst_backup_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::BackupRequest {
crate::model::BackupRequest {
backup_path: self.backup_path.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::BindingEventListener> for wire_cst_binding_event_listener {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::BindingEventListener {
crate::bindings::BindingEventListener {
stream: self.stream.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::BitcoinAddressData> for wire_cst_bitcoin_address_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::BitcoinAddressData {
crate::bindings::BitcoinAddressData {
address: self.address.cst_decode(),
network: self.network.cst_decode(),
amount_sat: self.amount_sat.cst_decode(),
label: self.label.cst_decode(),
message: self.message.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::AesSuccessActionDataDecrypted>
for *mut wire_cst_aes_success_action_data_decrypted
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::AesSuccessActionDataDecrypted {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::AesSuccessActionDataDecrypted>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::AesSuccessActionDataResult>
for *mut wire_cst_aes_success_action_data_result
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::AesSuccessActionDataResult {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::AesSuccessActionDataResult>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::BackupRequest> for *mut wire_cst_backup_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::BackupRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::BackupRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::BindingEventListener> for *mut wire_cst_binding_event_listener {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::BindingEventListener {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::BindingEventListener>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::BitcoinAddressData> for *mut wire_cst_bitcoin_address_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::BitcoinAddressData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::BitcoinAddressData>::cst_decode(*wrap).into()
}
}
impl CstDecode<bool> for *mut bool {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> bool {
unsafe { *flutter_rust_bridge::for_generated::box_from_leak_ptr(self) }
}
}
impl CstDecode<crate::model::BuyBitcoinRequest> for *mut wire_cst_buy_bitcoin_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::BuyBitcoinRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::BuyBitcoinRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::CheckMessageRequest> for *mut wire_cst_check_message_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::CheckMessageRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::CheckMessageRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::ConnectRequest> for *mut wire_cst_connect_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::ConnectRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::ConnectRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<i64> for *mut i64 {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> i64 {
unsafe { *flutter_rust_bridge::for_generated::box_from_leak_ptr(self) }
}
}
impl CstDecode<crate::model::ListPaymentsRequest> for *mut wire_cst_list_payments_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::ListPaymentsRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::ListPaymentsRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::LNInvoice> for *mut wire_cst_ln_invoice {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LNInvoice {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::LNInvoice>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::LnUrlAuthRequestData> for *mut wire_cst_ln_url_auth_request_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlAuthRequestData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::LnUrlAuthRequestData>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::LnUrlErrorData> for *mut wire_cst_ln_url_error_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlErrorData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::LnUrlErrorData>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::LnUrlPayErrorData> for *mut wire_cst_ln_url_pay_error_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlPayErrorData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::LnUrlPayErrorData>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::LnUrlPayRequest> for *mut wire_cst_ln_url_pay_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlPayRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::LnUrlPayRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::LnUrlPayRequestData> for *mut wire_cst_ln_url_pay_request_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlPayRequestData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::LnUrlPayRequestData>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::LnUrlPaySuccessData> for *mut wire_cst_ln_url_pay_success_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::LnUrlPaySuccessData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::LnUrlPaySuccessData>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::LnUrlWithdrawRequest> for *mut wire_cst_ln_url_withdraw_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlWithdrawRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::LnUrlWithdrawRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::LnUrlWithdrawRequestData>
for *mut wire_cst_ln_url_withdraw_request_data
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlWithdrawRequestData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::LnUrlWithdrawRequestData>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::duplicates::LnUrlWithdrawSuccessData>
for *mut wire_cst_ln_url_withdraw_success_data
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::duplicates::LnUrlWithdrawSuccessData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::duplicates::LnUrlWithdrawSuccessData>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::MessageSuccessActionData>
for *mut wire_cst_message_success_action_data
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::MessageSuccessActionData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::MessageSuccessActionData>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::PayOnchainRequest> for *mut wire_cst_pay_onchain_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PayOnchainRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::PayOnchainRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::Payment> for *mut wire_cst_payment {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::Payment {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::Payment>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::PrepareBuyBitcoinRequest>
for *mut wire_cst_prepare_buy_bitcoin_request
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareBuyBitcoinRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::PrepareBuyBitcoinRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::PreparePayOnchainRequest>
for *mut wire_cst_prepare_pay_onchain_request
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PreparePayOnchainRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::PreparePayOnchainRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::PrepareReceiveOnchainRequest>
for *mut wire_cst_prepare_receive_onchain_request
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareReceiveOnchainRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::PrepareReceiveOnchainRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::PrepareReceiveOnchainResponse>
for *mut wire_cst_prepare_receive_onchain_response
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareReceiveOnchainResponse {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::PrepareReceiveOnchainResponse>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::PrepareReceivePaymentRequest>
for *mut wire_cst_prepare_receive_payment_request
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareReceivePaymentRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::PrepareReceivePaymentRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::PrepareRefundRequest> for *mut wire_cst_prepare_refund_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareRefundRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::PrepareRefundRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::PrepareSendRequest> for *mut wire_cst_prepare_send_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareSendRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::PrepareSendRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::PrepareSendResponse> for *mut wire_cst_prepare_send_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareSendResponse {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::PrepareSendResponse>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::ReceivePaymentRequest> for *mut wire_cst_receive_payment_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::ReceivePaymentRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::ReceivePaymentRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::RefundRequest> for *mut wire_cst_refund_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::RefundRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::RefundRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::RestoreRequest> for *mut wire_cst_restore_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::RestoreRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::RestoreRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::SdkEvent> for *mut wire_cst_sdk_event {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::SdkEvent {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::SdkEvent>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::SignMessageRequest> for *mut wire_cst_sign_message_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::SignMessageRequest {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::model::SignMessageRequest>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::SuccessActionProcessed> for *mut wire_cst_success_action_processed {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::SuccessActionProcessed {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::SuccessActionProcessed>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::bindings::Symbol> for *mut wire_cst_symbol {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::Symbol {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::Symbol>::cst_decode(*wrap).into()
}
}
impl CstDecode<u32> for *mut u32 {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> u32 {
unsafe { *flutter_rust_bridge::for_generated::box_from_leak_ptr(self) }
}
}
impl CstDecode<u64> for *mut u64 {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> u64 {
unsafe { *flutter_rust_bridge::for_generated::box_from_leak_ptr(self) }
}
}
impl CstDecode<crate::bindings::UrlSuccessActionData> for *mut wire_cst_url_success_action_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::UrlSuccessActionData {
let wrap = unsafe { flutter_rust_bridge::for_generated::box_from_leak_ptr(self) };
CstDecode::<crate::bindings::UrlSuccessActionData>::cst_decode(*wrap).into()
}
}
impl CstDecode<crate::model::BuyBitcoinRequest> for wire_cst_buy_bitcoin_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::BuyBitcoinRequest {
crate::model::BuyBitcoinRequest {
prepare_res: self.prepare_res.cst_decode(),
redirect_url: self.redirect_url.cst_decode(),
}
}
}
impl CstDecode<crate::model::CheckMessageRequest> for wire_cst_check_message_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::CheckMessageRequest {
crate::model::CheckMessageRequest {
message: self.message.cst_decode(),
pubkey: self.pubkey.cst_decode(),
signature: self.signature.cst_decode(),
}
}
}
impl CstDecode<crate::model::CheckMessageResponse> for wire_cst_check_message_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::CheckMessageResponse {
crate::model::CheckMessageResponse {
is_valid: self.is_valid.cst_decode(),
}
}
}
impl CstDecode<crate::model::Config> for wire_cst_config {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::Config {
crate::model::Config {
liquid_electrum_url: self.liquid_electrum_url.cst_decode(),
bitcoin_electrum_url: self.bitcoin_electrum_url.cst_decode(),
mempoolspace_url: self.mempoolspace_url.cst_decode(),
working_dir: self.working_dir.cst_decode(),
network: self.network.cst_decode(),
payment_timeout_sec: self.payment_timeout_sec.cst_decode(),
zero_conf_min_fee_rate_msat: self.zero_conf_min_fee_rate_msat.cst_decode(),
zero_conf_max_amount_sat: self.zero_conf_max_amount_sat.cst_decode(),
}
}
}
impl CstDecode<crate::model::ConnectRequest> for wire_cst_connect_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::ConnectRequest {
crate::model::ConnectRequest {
mnemonic: self.mnemonic.cst_decode(),
config: self.config.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::CurrencyInfo> for wire_cst_currency_info {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::CurrencyInfo {
crate::bindings::CurrencyInfo {
name: self.name.cst_decode(),
fraction_size: self.fraction_size.cst_decode(),
spacing: self.spacing.cst_decode(),
symbol: self.symbol.cst_decode(),
uniq_symbol: self.uniq_symbol.cst_decode(),
localized_name: self.localized_name.cst_decode(),
locale_overrides: self.locale_overrides.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::FiatCurrency> for wire_cst_fiat_currency {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::FiatCurrency {
crate::bindings::FiatCurrency {
id: self.id.cst_decode(),
info: self.info.cst_decode(),
}
}
}
impl CstDecode<crate::model::GetInfoResponse> for wire_cst_get_info_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::GetInfoResponse {
crate::model::GetInfoResponse {
balance_sat: self.balance_sat.cst_decode(),
pending_send_sat: self.pending_send_sat.cst_decode(),
pending_receive_sat: self.pending_receive_sat.cst_decode(),
pubkey: self.pubkey.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::InputType> for wire_cst_input_type {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::InputType {
match self.tag {
0 => {
let ans = unsafe { self.kind.BitcoinAddress };
crate::bindings::InputType::BitcoinAddress {
address: ans.address.cst_decode(),
}
}
1 => {
let ans = unsafe { self.kind.Bolt11 };
crate::bindings::InputType::Bolt11 {
invoice: ans.invoice.cst_decode(),
}
}
2 => {
let ans = unsafe { self.kind.NodeId };
crate::bindings::InputType::NodeId {
node_id: ans.node_id.cst_decode(),
}
}
3 => {
let ans = unsafe { self.kind.Url };
crate::bindings::InputType::Url {
url: ans.url.cst_decode(),
}
}
4 => {
let ans = unsafe { self.kind.LnUrlPay };
crate::bindings::InputType::LnUrlPay {
data: ans.data.cst_decode(),
}
}
5 => {
let ans = unsafe { self.kind.LnUrlWithdraw };
crate::bindings::InputType::LnUrlWithdraw {
data: ans.data.cst_decode(),
}
}
6 => {
let ans = unsafe { self.kind.LnUrlAuth };
crate::bindings::InputType::LnUrlAuth {
data: ans.data.cst_decode(),
}
}
7 => {
let ans = unsafe { self.kind.LnUrlError };
crate::bindings::InputType::LnUrlError {
data: ans.data.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::model::LightningPaymentLimitsResponse>
for wire_cst_lightning_payment_limits_response
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::LightningPaymentLimitsResponse {
crate::model::LightningPaymentLimitsResponse {
send: self.send.cst_decode(),
receive: self.receive.cst_decode(),
}
}
}
impl CstDecode<crate::model::Limits> for wire_cst_limits {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::Limits {
crate::model::Limits {
min_sat: self.min_sat.cst_decode(),
max_sat: self.max_sat.cst_decode(),
max_zero_conf_sat: self.max_zero_conf_sat.cst_decode(),
}
}
}
impl CstDecode<Vec<crate::bindings::FiatCurrency>> for *mut wire_cst_list_fiat_currency {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<crate::bindings::FiatCurrency> {
let vec = unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
};
vec.into_iter().map(CstDecode::cst_decode).collect()
}
}
impl CstDecode<Vec<crate::bindings::LocaleOverrides>> for *mut wire_cst_list_locale_overrides {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<crate::bindings::LocaleOverrides> {
let vec = unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
};
vec.into_iter().map(CstDecode::cst_decode).collect()
}
}
impl CstDecode<Vec<crate::bindings::LocalizedName>> for *mut wire_cst_list_localized_name {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<crate::bindings::LocalizedName> {
let vec = unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
};
vec.into_iter().map(CstDecode::cst_decode).collect()
}
}
impl CstDecode<Vec<crate::model::Payment>> for *mut wire_cst_list_payment {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<crate::model::Payment> {
let vec = unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
};
vec.into_iter().map(CstDecode::cst_decode).collect()
}
}
impl CstDecode<Vec<crate::model::PaymentType>> for *mut wire_cst_list_payment_type {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<crate::model::PaymentType> {
let vec = unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
};
vec.into_iter().map(CstDecode::cst_decode).collect()
}
}
impl CstDecode<crate::model::ListPaymentsRequest> for wire_cst_list_payments_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::ListPaymentsRequest {
crate::model::ListPaymentsRequest {
filters: self.filters.cst_decode(),
from_timestamp: self.from_timestamp.cst_decode(),
to_timestamp: self.to_timestamp.cst_decode(),
offset: self.offset.cst_decode(),
limit: self.limit.cst_decode(),
}
}
}
impl CstDecode<Vec<u8>> for *mut wire_cst_list_prim_u_8_strict {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<u8> {
unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
}
}
}
impl CstDecode<Vec<crate::bindings::Rate>> for *mut wire_cst_list_rate {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<crate::bindings::Rate> {
let vec = unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
};
vec.into_iter().map(CstDecode::cst_decode).collect()
}
}
impl CstDecode<Vec<crate::model::RefundableSwap>> for *mut wire_cst_list_refundable_swap {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<crate::model::RefundableSwap> {
let vec = unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
};
vec.into_iter().map(CstDecode::cst_decode).collect()
}
}
impl CstDecode<Vec<crate::bindings::RouteHint>> for *mut wire_cst_list_route_hint {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<crate::bindings::RouteHint> {
let vec = unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
};
vec.into_iter().map(CstDecode::cst_decode).collect()
}
}
impl CstDecode<Vec<crate::bindings::RouteHintHop>> for *mut wire_cst_list_route_hint_hop {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> Vec<crate::bindings::RouteHintHop> {
let vec = unsafe {
let wrap = flutter_rust_bridge::for_generated::box_from_leak_ptr(self);
flutter_rust_bridge::for_generated::vec_from_leak_ptr(wrap.ptr, wrap.len)
};
vec.into_iter().map(CstDecode::cst_decode).collect()
}
}
impl CstDecode<crate::bindings::LNInvoice> for wire_cst_ln_invoice {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LNInvoice {
crate::bindings::LNInvoice {
bolt11: self.bolt11.cst_decode(),
network: self.network.cst_decode(),
payee_pubkey: self.payee_pubkey.cst_decode(),
payment_hash: self.payment_hash.cst_decode(),
description: self.description.cst_decode(),
description_hash: self.description_hash.cst_decode(),
amount_msat: self.amount_msat.cst_decode(),
timestamp: self.timestamp.cst_decode(),
expiry: self.expiry.cst_decode(),
routing_hints: self.routing_hints.cst_decode(),
payment_secret: self.payment_secret.cst_decode(),
min_final_cltv_expiry_delta: self.min_final_cltv_expiry_delta.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::duplicates::LnUrlAuthError> for wire_cst_ln_url_auth_error {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::duplicates::LnUrlAuthError {
match self.tag {
0 => {
let ans = unsafe { self.kind.Generic };
crate::bindings::duplicates::LnUrlAuthError::Generic {
err: ans.err.cst_decode(),
}
}
1 => {
let ans = unsafe { self.kind.InvalidUri };
crate::bindings::duplicates::LnUrlAuthError::InvalidUri {
err: ans.err.cst_decode(),
}
}
2 => {
let ans = unsafe { self.kind.ServiceConnectivity };
crate::bindings::duplicates::LnUrlAuthError::ServiceConnectivity {
err: ans.err.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::bindings::LnUrlAuthRequestData> for wire_cst_ln_url_auth_request_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlAuthRequestData {
crate::bindings::LnUrlAuthRequestData {
k1: self.k1.cst_decode(),
action: self.action.cst_decode(),
domain: self.domain.cst_decode(),
url: self.url.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::duplicates::LnUrlCallbackStatus>
for wire_cst_ln_url_callback_status
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::duplicates::LnUrlCallbackStatus {
match self.tag {
0 => crate::bindings::duplicates::LnUrlCallbackStatus::Ok,
1 => {
let ans = unsafe { self.kind.ErrorStatus };
crate::bindings::duplicates::LnUrlCallbackStatus::ErrorStatus {
data: ans.data.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::bindings::LnUrlErrorData> for wire_cst_ln_url_error_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlErrorData {
crate::bindings::LnUrlErrorData {
reason: self.reason.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::duplicates::LnUrlPayError> for wire_cst_ln_url_pay_error {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::duplicates::LnUrlPayError {
match self.tag {
0 => crate::bindings::duplicates::LnUrlPayError::AlreadyPaid,
1 => {
let ans = unsafe { self.kind.Generic };
crate::bindings::duplicates::LnUrlPayError::Generic {
err: ans.err.cst_decode(),
}
}
2 => {
let ans = unsafe { self.kind.InvalidAmount };
crate::bindings::duplicates::LnUrlPayError::InvalidAmount {
err: ans.err.cst_decode(),
}
}
3 => {
let ans = unsafe { self.kind.InvalidInvoice };
crate::bindings::duplicates::LnUrlPayError::InvalidInvoice {
err: ans.err.cst_decode(),
}
}
4 => {
let ans = unsafe { self.kind.InvalidNetwork };
crate::bindings::duplicates::LnUrlPayError::InvalidNetwork {
err: ans.err.cst_decode(),
}
}
5 => {
let ans = unsafe { self.kind.InvalidUri };
crate::bindings::duplicates::LnUrlPayError::InvalidUri {
err: ans.err.cst_decode(),
}
}
6 => {
let ans = unsafe { self.kind.InvoiceExpired };
crate::bindings::duplicates::LnUrlPayError::InvoiceExpired {
err: ans.err.cst_decode(),
}
}
7 => {
let ans = unsafe { self.kind.PaymentFailed };
crate::bindings::duplicates::LnUrlPayError::PaymentFailed {
err: ans.err.cst_decode(),
}
}
8 => {
let ans = unsafe { self.kind.PaymentTimeout };
crate::bindings::duplicates::LnUrlPayError::PaymentTimeout {
err: ans.err.cst_decode(),
}
}
9 => {
let ans = unsafe { self.kind.RouteNotFound };
crate::bindings::duplicates::LnUrlPayError::RouteNotFound {
err: ans.err.cst_decode(),
}
}
10 => {
let ans = unsafe { self.kind.RouteTooExpensive };
crate::bindings::duplicates::LnUrlPayError::RouteTooExpensive {
err: ans.err.cst_decode(),
}
}
11 => {
let ans = unsafe { self.kind.ServiceConnectivity };
crate::bindings::duplicates::LnUrlPayError::ServiceConnectivity {
err: ans.err.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::bindings::LnUrlPayErrorData> for wire_cst_ln_url_pay_error_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlPayErrorData {
crate::bindings::LnUrlPayErrorData {
payment_hash: self.payment_hash.cst_decode(),
reason: self.reason.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::LnUrlPayRequest> for wire_cst_ln_url_pay_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlPayRequest {
crate::bindings::LnUrlPayRequest {
data: self.data.cst_decode(),
amount_msat: self.amount_msat.cst_decode(),
comment: self.comment.cst_decode(),
payment_label: self.payment_label.cst_decode(),
validate_success_action_url: self.validate_success_action_url.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::LnUrlPayRequestData> for wire_cst_ln_url_pay_request_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlPayRequestData {
crate::bindings::LnUrlPayRequestData {
callback: self.callback.cst_decode(),
min_sendable: self.min_sendable.cst_decode(),
max_sendable: self.max_sendable.cst_decode(),
metadata_str: self.metadata_str.cst_decode(),
comment_allowed: self.comment_allowed.cst_decode(),
domain: self.domain.cst_decode(),
allows_nostr: self.allows_nostr.cst_decode(),
nostr_pubkey: self.nostr_pubkey.cst_decode(),
ln_address: self.ln_address.cst_decode(),
}
}
}
impl CstDecode<crate::model::LnUrlPayResult> for wire_cst_ln_url_pay_result {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::LnUrlPayResult {
match self.tag {
0 => {
let ans = unsafe { self.kind.EndpointSuccess };
crate::model::LnUrlPayResult::EndpointSuccess {
data: ans.data.cst_decode(),
}
}
1 => {
let ans = unsafe { self.kind.EndpointError };
crate::model::LnUrlPayResult::EndpointError {
data: ans.data.cst_decode(),
}
}
2 => {
let ans = unsafe { self.kind.PayError };
crate::model::LnUrlPayResult::PayError {
data: ans.data.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::model::LnUrlPaySuccessData> for wire_cst_ln_url_pay_success_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::LnUrlPaySuccessData {
crate::model::LnUrlPaySuccessData {
payment: self.payment.cst_decode(),
success_action: self.success_action.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::duplicates::LnUrlWithdrawError> for wire_cst_ln_url_withdraw_error {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::duplicates::LnUrlWithdrawError {
match self.tag {
0 => {
let ans = unsafe { self.kind.Generic };
crate::bindings::duplicates::LnUrlWithdrawError::Generic {
err: ans.err.cst_decode(),
}
}
1 => {
let ans = unsafe { self.kind.InvalidAmount };
crate::bindings::duplicates::LnUrlWithdrawError::InvalidAmount {
err: ans.err.cst_decode(),
}
}
2 => {
let ans = unsafe { self.kind.InvalidInvoice };
crate::bindings::duplicates::LnUrlWithdrawError::InvalidInvoice {
err: ans.err.cst_decode(),
}
}
3 => {
let ans = unsafe { self.kind.InvalidUri };
crate::bindings::duplicates::LnUrlWithdrawError::InvalidUri {
err: ans.err.cst_decode(),
}
}
4 => {
let ans = unsafe { self.kind.InvoiceNoRoutingHints };
crate::bindings::duplicates::LnUrlWithdrawError::InvoiceNoRoutingHints {
err: ans.err.cst_decode(),
}
}
5 => {
let ans = unsafe { self.kind.ServiceConnectivity };
crate::bindings::duplicates::LnUrlWithdrawError::ServiceConnectivity {
err: ans.err.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::bindings::LnUrlWithdrawRequest> for wire_cst_ln_url_withdraw_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlWithdrawRequest {
crate::bindings::LnUrlWithdrawRequest {
data: self.data.cst_decode(),
amount_msat: self.amount_msat.cst_decode(),
description: self.description.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::LnUrlWithdrawRequestData>
for wire_cst_ln_url_withdraw_request_data
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LnUrlWithdrawRequestData {
crate::bindings::LnUrlWithdrawRequestData {
callback: self.callback.cst_decode(),
k1: self.k1.cst_decode(),
default_description: self.default_description.cst_decode(),
min_withdrawable: self.min_withdrawable.cst_decode(),
max_withdrawable: self.max_withdrawable.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::duplicates::LnUrlWithdrawResult>
for wire_cst_ln_url_withdraw_result
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::duplicates::LnUrlWithdrawResult {
match self.tag {
0 => {
let ans = unsafe { self.kind.Ok };
crate::bindings::duplicates::LnUrlWithdrawResult::Ok {
data: ans.data.cst_decode(),
}
}
1 => {
let ans = unsafe { self.kind.Timeout };
crate::bindings::duplicates::LnUrlWithdrawResult::Timeout {
data: ans.data.cst_decode(),
}
}
2 => {
let ans = unsafe { self.kind.ErrorStatus };
crate::bindings::duplicates::LnUrlWithdrawResult::ErrorStatus {
data: ans.data.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::bindings::duplicates::LnUrlWithdrawSuccessData>
for wire_cst_ln_url_withdraw_success_data
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::duplicates::LnUrlWithdrawSuccessData {
crate::bindings::duplicates::LnUrlWithdrawSuccessData {
invoice: self.invoice.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::LocaleOverrides> for wire_cst_locale_overrides {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LocaleOverrides {
crate::bindings::LocaleOverrides {
locale: self.locale.cst_decode(),
spacing: self.spacing.cst_decode(),
symbol: self.symbol.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::LocalizedName> for wire_cst_localized_name {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::LocalizedName {
crate::bindings::LocalizedName {
locale: self.locale.cst_decode(),
name: self.name.cst_decode(),
}
}
}
impl CstDecode<crate::model::LogEntry> for wire_cst_log_entry {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::LogEntry {
crate::model::LogEntry {
line: self.line.cst_decode(),
level: self.level.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::MessageSuccessActionData> for wire_cst_message_success_action_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::MessageSuccessActionData {
crate::bindings::MessageSuccessActionData {
message: self.message.cst_decode(),
}
}
}
impl CstDecode<crate::model::OnchainPaymentLimitsResponse>
for wire_cst_onchain_payment_limits_response
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::OnchainPaymentLimitsResponse {
crate::model::OnchainPaymentLimitsResponse {
send: self.send.cst_decode(),
receive: self.receive.cst_decode(),
}
}
}
impl CstDecode<crate::model::PayOnchainRequest> for wire_cst_pay_onchain_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PayOnchainRequest {
crate::model::PayOnchainRequest {
address: self.address.cst_decode(),
prepare_res: self.prepare_res.cst_decode(),
}
}
}
impl CstDecode<crate::model::Payment> for wire_cst_payment {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::Payment {
crate::model::Payment {
tx_id: self.tx_id.cst_decode(),
swap_id: self.swap_id.cst_decode(),
timestamp: self.timestamp.cst_decode(),
amount_sat: self.amount_sat.cst_decode(),
fees_sat: self.fees_sat.cst_decode(),
preimage: self.preimage.cst_decode(),
bolt11: self.bolt11.cst_decode(),
description: self.description.cst_decode(),
refund_tx_id: self.refund_tx_id.cst_decode(),
refund_tx_amount_sat: self.refund_tx_amount_sat.cst_decode(),
payment_type: self.payment_type.cst_decode(),
status: self.status.cst_decode(),
}
}
}
impl CstDecode<crate::error::PaymentError> for wire_cst_payment_error {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::error::PaymentError {
match self.tag {
0 => crate::error::PaymentError::AlreadyClaimed,
1 => crate::error::PaymentError::AlreadyPaid,
2 => crate::error::PaymentError::PaymentInProgress,
3 => crate::error::PaymentError::AmountOutOfRange,
4 => {
let ans = unsafe { self.kind.Generic };
crate::error::PaymentError::Generic {
err: ans.err.cst_decode(),
}
}
5 => crate::error::PaymentError::InvalidOrExpiredFees,
6 => crate::error::PaymentError::InsufficientFunds,
7 => {
let ans = unsafe { self.kind.InvalidDescription };
crate::error::PaymentError::InvalidDescription {
err: ans.err.cst_decode(),
}
}
8 => {
let ans = unsafe { self.kind.InvalidInvoice };
crate::error::PaymentError::InvalidInvoice {
err: ans.err.cst_decode(),
}
}
9 => crate::error::PaymentError::InvalidPreimage,
10 => {
let ans = unsafe { self.kind.LwkError };
crate::error::PaymentError::LwkError {
err: ans.err.cst_decode(),
}
}
11 => crate::error::PaymentError::PairsNotFound,
12 => crate::error::PaymentError::PaymentTimeout,
13 => crate::error::PaymentError::PersistError,
14 => {
let ans = unsafe { self.kind.ReceiveError };
crate::error::PaymentError::ReceiveError {
err: ans.err.cst_decode(),
}
}
15 => {
let ans = unsafe { self.kind.Refunded };
crate::error::PaymentError::Refunded {
err: ans.err.cst_decode(),
refund_tx_id: ans.refund_tx_id.cst_decode(),
}
}
16 => crate::error::PaymentError::SelfTransferNotSupported,
17 => {
let ans = unsafe { self.kind.SendError };
crate::error::PaymentError::SendError {
err: ans.err.cst_decode(),
}
}
18 => {
let ans = unsafe { self.kind.SignerError };
crate::error::PaymentError::SignerError {
err: ans.err.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::model::PrepareBuyBitcoinRequest> for wire_cst_prepare_buy_bitcoin_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareBuyBitcoinRequest {
crate::model::PrepareBuyBitcoinRequest {
provider: self.provider.cst_decode(),
amount_sat: self.amount_sat.cst_decode(),
}
}
}
impl CstDecode<crate::model::PrepareBuyBitcoinResponse> for wire_cst_prepare_buy_bitcoin_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareBuyBitcoinResponse {
crate::model::PrepareBuyBitcoinResponse {
provider: self.provider.cst_decode(),
amount_sat: self.amount_sat.cst_decode(),
fees_sat: self.fees_sat.cst_decode(),
}
}
}
impl CstDecode<crate::model::PreparePayOnchainRequest> for wire_cst_prepare_pay_onchain_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PreparePayOnchainRequest {
crate::model::PreparePayOnchainRequest {
receiver_amount_sat: self.receiver_amount_sat.cst_decode(),
sat_per_vbyte: self.sat_per_vbyte.cst_decode(),
}
}
}
impl CstDecode<crate::model::PreparePayOnchainResponse> for wire_cst_prepare_pay_onchain_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PreparePayOnchainResponse {
crate::model::PreparePayOnchainResponse {
receiver_amount_sat: self.receiver_amount_sat.cst_decode(),
claim_fees_sat: self.claim_fees_sat.cst_decode(),
total_fees_sat: self.total_fees_sat.cst_decode(),
}
}
}
impl CstDecode<crate::model::PrepareReceiveOnchainRequest>
for wire_cst_prepare_receive_onchain_request
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareReceiveOnchainRequest {
crate::model::PrepareReceiveOnchainRequest {
payer_amount_sat: self.payer_amount_sat.cst_decode(),
}
}
}
impl CstDecode<crate::model::PrepareReceiveOnchainResponse>
for wire_cst_prepare_receive_onchain_response
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareReceiveOnchainResponse {
crate::model::PrepareReceiveOnchainResponse {
payer_amount_sat: self.payer_amount_sat.cst_decode(),
fees_sat: self.fees_sat.cst_decode(),
}
}
}
impl CstDecode<crate::model::PrepareReceivePaymentRequest>
for wire_cst_prepare_receive_payment_request
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareReceivePaymentRequest {
crate::model::PrepareReceivePaymentRequest {
payer_amount_sat: self.payer_amount_sat.cst_decode(),
}
}
}
impl CstDecode<crate::model::PrepareReceivePaymentResponse>
for wire_cst_prepare_receive_payment_response
{
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareReceivePaymentResponse {
crate::model::PrepareReceivePaymentResponse {
payer_amount_sat: self.payer_amount_sat.cst_decode(),
fees_sat: self.fees_sat.cst_decode(),
}
}
}
impl CstDecode<crate::model::PrepareRefundRequest> for wire_cst_prepare_refund_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareRefundRequest {
crate::model::PrepareRefundRequest {
swap_address: self.swap_address.cst_decode(),
refund_address: self.refund_address.cst_decode(),
sat_per_vbyte: self.sat_per_vbyte.cst_decode(),
}
}
}
impl CstDecode<crate::model::PrepareRefundResponse> for wire_cst_prepare_refund_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareRefundResponse {
crate::model::PrepareRefundResponse {
tx_vsize: self.tx_vsize.cst_decode(),
tx_fee_sat: self.tx_fee_sat.cst_decode(),
refund_tx_id: self.refund_tx_id.cst_decode(),
}
}
}
impl CstDecode<crate::model::PrepareSendRequest> for wire_cst_prepare_send_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareSendRequest {
crate::model::PrepareSendRequest {
invoice: self.invoice.cst_decode(),
}
}
}
impl CstDecode<crate::model::PrepareSendResponse> for wire_cst_prepare_send_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::PrepareSendResponse {
crate::model::PrepareSendResponse {
invoice: self.invoice.cst_decode(),
fees_sat: self.fees_sat.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::Rate> for wire_cst_rate {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::Rate {
crate::bindings::Rate {
coin: self.coin.cst_decode(),
value: self.value.cst_decode(),
}
}
}
impl CstDecode<crate::model::ReceiveOnchainResponse> for wire_cst_receive_onchain_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::ReceiveOnchainResponse {
crate::model::ReceiveOnchainResponse {
address: self.address.cst_decode(),
bip21: self.bip21.cst_decode(),
}
}
}
impl CstDecode<crate::model::ReceivePaymentRequest> for wire_cst_receive_payment_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::ReceivePaymentRequest {
crate::model::ReceivePaymentRequest {
prepare_res: self.prepare_res.cst_decode(),
description: self.description.cst_decode(),
use_description_hash: self.use_description_hash.cst_decode(),
}
}
}
impl CstDecode<crate::model::ReceivePaymentResponse> for wire_cst_receive_payment_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::ReceivePaymentResponse {
crate::model::ReceivePaymentResponse {
id: self.id.cst_decode(),
invoice: self.invoice.cst_decode(),
}
}
}
impl CstDecode<crate::model::RecommendedFees> for wire_cst_recommended_fees {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::RecommendedFees {
crate::model::RecommendedFees {
fastest_fee: self.fastest_fee.cst_decode(),
half_hour_fee: self.half_hour_fee.cst_decode(),
hour_fee: self.hour_fee.cst_decode(),
economy_fee: self.economy_fee.cst_decode(),
minimum_fee: self.minimum_fee.cst_decode(),
}
}
}
impl CstDecode<crate::model::RefundRequest> for wire_cst_refund_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::RefundRequest {
crate::model::RefundRequest {
swap_address: self.swap_address.cst_decode(),
refund_address: self.refund_address.cst_decode(),
sat_per_vbyte: self.sat_per_vbyte.cst_decode(),
}
}
}
impl CstDecode<crate::model::RefundResponse> for wire_cst_refund_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::RefundResponse {
crate::model::RefundResponse {
refund_tx_id: self.refund_tx_id.cst_decode(),
}
}
}
impl CstDecode<crate::model::RefundableSwap> for wire_cst_refundable_swap {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::RefundableSwap {
crate::model::RefundableSwap {
swap_address: self.swap_address.cst_decode(),
timestamp: self.timestamp.cst_decode(),
amount_sat: self.amount_sat.cst_decode(),
}
}
}
impl CstDecode<crate::model::RestoreRequest> for wire_cst_restore_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::RestoreRequest {
crate::model::RestoreRequest {
backup_path: self.backup_path.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::RouteHint> for wire_cst_route_hint {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::RouteHint {
crate::bindings::RouteHint {
hops: self.hops.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::RouteHintHop> for wire_cst_route_hint_hop {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::RouteHintHop {
crate::bindings::RouteHintHop {
src_node_id: self.src_node_id.cst_decode(),
short_channel_id: self.short_channel_id.cst_decode(),
fees_base_msat: self.fees_base_msat.cst_decode(),
fees_proportional_millionths: self.fees_proportional_millionths.cst_decode(),
cltv_expiry_delta: self.cltv_expiry_delta.cst_decode(),
htlc_minimum_msat: self.htlc_minimum_msat.cst_decode(),
htlc_maximum_msat: self.htlc_maximum_msat.cst_decode(),
}
}
}
impl CstDecode<crate::error::SdkError> for wire_cst_sdk_error {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::error::SdkError {
match self.tag {
0 => crate::error::SdkError::AlreadyStarted,
1 => {
let ans = unsafe { self.kind.Generic };
crate::error::SdkError::Generic {
err: ans.err.cst_decode(),
}
}
2 => crate::error::SdkError::NotStarted,
3 => {
let ans = unsafe { self.kind.ServiceConnectivity };
crate::error::SdkError::ServiceConnectivity {
err: ans.err.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::model::SdkEvent> for wire_cst_sdk_event {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::SdkEvent {
match self.tag {
0 => {
let ans = unsafe { self.kind.PaymentFailed };
crate::model::SdkEvent::PaymentFailed {
details: ans.details.cst_decode(),
}
}
1 => {
let ans = unsafe { self.kind.PaymentPending };
crate::model::SdkEvent::PaymentPending {
details: ans.details.cst_decode(),
}
}
2 => {
let ans = unsafe { self.kind.PaymentRefunded };
crate::model::SdkEvent::PaymentRefunded {
details: ans.details.cst_decode(),
}
}
3 => {
let ans = unsafe { self.kind.PaymentRefundPending };
crate::model::SdkEvent::PaymentRefundPending {
details: ans.details.cst_decode(),
}
}
4 => {
let ans = unsafe { self.kind.PaymentSucceeded };
crate::model::SdkEvent::PaymentSucceeded {
details: ans.details.cst_decode(),
}
}
5 => {
let ans = unsafe { self.kind.PaymentWaitingConfirmation };
crate::model::SdkEvent::PaymentWaitingConfirmation {
details: ans.details.cst_decode(),
}
}
6 => crate::model::SdkEvent::Synced,
_ => unreachable!(),
}
}
}
impl CstDecode<crate::model::SendPaymentResponse> for wire_cst_send_payment_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::SendPaymentResponse {
crate::model::SendPaymentResponse {
payment: self.payment.cst_decode(),
}
}
}
impl CstDecode<crate::model::SignMessageRequest> for wire_cst_sign_message_request {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::SignMessageRequest {
crate::model::SignMessageRequest {
message: self.message.cst_decode(),
}
}
}
impl CstDecode<crate::model::SignMessageResponse> for wire_cst_sign_message_response {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::model::SignMessageResponse {
crate::model::SignMessageResponse {
signature: self.signature.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::SuccessActionProcessed> for wire_cst_success_action_processed {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::SuccessActionProcessed {
match self.tag {
0 => {
let ans = unsafe { self.kind.Aes };
crate::bindings::SuccessActionProcessed::Aes {
result: ans.result.cst_decode(),
}
}
1 => {
let ans = unsafe { self.kind.Message };
crate::bindings::SuccessActionProcessed::Message {
data: ans.data.cst_decode(),
}
}
2 => {
let ans = unsafe { self.kind.Url };
crate::bindings::SuccessActionProcessed::Url {
data: ans.data.cst_decode(),
}
}
_ => unreachable!(),
}
}
}
impl CstDecode<crate::bindings::Symbol> for wire_cst_symbol {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::Symbol {
crate::bindings::Symbol {
grapheme: self.grapheme.cst_decode(),
template: self.template.cst_decode(),
rtl: self.rtl.cst_decode(),
position: self.position.cst_decode(),
}
}
}
impl CstDecode<crate::bindings::UrlSuccessActionData> for wire_cst_url_success_action_data {
// Codec=Cst (C-struct based), see doc to use other codecs
fn cst_decode(self) -> crate::bindings::UrlSuccessActionData {
crate::bindings::UrlSuccessActionData {
description: self.description.cst_decode(),
url: self.url.cst_decode(),
matches_callback_domain: self.matches_callback_domain.cst_decode(),
}
}
}
impl NewWithNullPtr for wire_cst_aes_success_action_data_decrypted {
fn new_with_null_ptr() -> Self {
Self {
description: core::ptr::null_mut(),
plaintext: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_aes_success_action_data_decrypted {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_aes_success_action_data_result {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: AesSuccessActionDataResultKind { nil__: () },
}
}
}
impl Default for wire_cst_aes_success_action_data_result {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_backup_request {
fn new_with_null_ptr() -> Self {
Self {
backup_path: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_backup_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_binding_event_listener {
fn new_with_null_ptr() -> Self {
Self {
stream: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_binding_event_listener {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_bitcoin_address_data {
fn new_with_null_ptr() -> Self {
Self {
address: core::ptr::null_mut(),
network: Default::default(),
amount_sat: core::ptr::null_mut(),
label: core::ptr::null_mut(),
message: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_bitcoin_address_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_buy_bitcoin_request {
fn new_with_null_ptr() -> Self {
Self {
prepare_res: Default::default(),
redirect_url: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_buy_bitcoin_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_check_message_request {
fn new_with_null_ptr() -> Self {
Self {
message: core::ptr::null_mut(),
pubkey: core::ptr::null_mut(),
signature: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_check_message_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_check_message_response {
fn new_with_null_ptr() -> Self {
Self {
is_valid: Default::default(),
}
}
}
impl Default for wire_cst_check_message_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_config {
fn new_with_null_ptr() -> Self {
Self {
liquid_electrum_url: core::ptr::null_mut(),
bitcoin_electrum_url: core::ptr::null_mut(),
mempoolspace_url: core::ptr::null_mut(),
working_dir: core::ptr::null_mut(),
network: Default::default(),
payment_timeout_sec: Default::default(),
zero_conf_min_fee_rate_msat: Default::default(),
zero_conf_max_amount_sat: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_config {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_connect_request {
fn new_with_null_ptr() -> Self {
Self {
mnemonic: core::ptr::null_mut(),
config: Default::default(),
}
}
}
impl Default for wire_cst_connect_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_currency_info {
fn new_with_null_ptr() -> Self {
Self {
name: core::ptr::null_mut(),
fraction_size: Default::default(),
spacing: core::ptr::null_mut(),
symbol: core::ptr::null_mut(),
uniq_symbol: core::ptr::null_mut(),
localized_name: core::ptr::null_mut(),
locale_overrides: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_currency_info {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_fiat_currency {
fn new_with_null_ptr() -> Self {
Self {
id: core::ptr::null_mut(),
info: Default::default(),
}
}
}
impl Default for wire_cst_fiat_currency {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_get_info_response {
fn new_with_null_ptr() -> Self {
Self {
balance_sat: Default::default(),
pending_send_sat: Default::default(),
pending_receive_sat: Default::default(),
pubkey: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_get_info_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_input_type {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: InputTypeKind { nil__: () },
}
}
}
impl Default for wire_cst_input_type {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_lightning_payment_limits_response {
fn new_with_null_ptr() -> Self {
Self {
send: Default::default(),
receive: Default::default(),
}
}
}
impl Default for wire_cst_lightning_payment_limits_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_limits {
fn new_with_null_ptr() -> Self {
Self {
min_sat: Default::default(),
max_sat: Default::default(),
max_zero_conf_sat: Default::default(),
}
}
}
impl Default for wire_cst_limits {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_list_payments_request {
fn new_with_null_ptr() -> Self {
Self {
filters: core::ptr::null_mut(),
from_timestamp: core::ptr::null_mut(),
to_timestamp: core::ptr::null_mut(),
offset: core::ptr::null_mut(),
limit: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_list_payments_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_invoice {
fn new_with_null_ptr() -> Self {
Self {
bolt11: core::ptr::null_mut(),
network: Default::default(),
payee_pubkey: core::ptr::null_mut(),
payment_hash: core::ptr::null_mut(),
description: core::ptr::null_mut(),
description_hash: core::ptr::null_mut(),
amount_msat: core::ptr::null_mut(),
timestamp: Default::default(),
expiry: Default::default(),
routing_hints: core::ptr::null_mut(),
payment_secret: core::ptr::null_mut(),
min_final_cltv_expiry_delta: Default::default(),
}
}
}
impl Default for wire_cst_ln_invoice {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_auth_error {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: LnUrlAuthErrorKind { nil__: () },
}
}
}
impl Default for wire_cst_ln_url_auth_error {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_auth_request_data {
fn new_with_null_ptr() -> Self {
Self {
k1: core::ptr::null_mut(),
action: core::ptr::null_mut(),
domain: core::ptr::null_mut(),
url: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_ln_url_auth_request_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_callback_status {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: LnUrlCallbackStatusKind { nil__: () },
}
}
}
impl Default for wire_cst_ln_url_callback_status {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_error_data {
fn new_with_null_ptr() -> Self {
Self {
reason: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_ln_url_error_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_pay_error {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: LnUrlPayErrorKind { nil__: () },
}
}
}
impl Default for wire_cst_ln_url_pay_error {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_pay_error_data {
fn new_with_null_ptr() -> Self {
Self {
payment_hash: core::ptr::null_mut(),
reason: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_ln_url_pay_error_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_pay_request {
fn new_with_null_ptr() -> Self {
Self {
data: Default::default(),
amount_msat: Default::default(),
comment: core::ptr::null_mut(),
payment_label: core::ptr::null_mut(),
validate_success_action_url: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_ln_url_pay_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_pay_request_data {
fn new_with_null_ptr() -> Self {
Self {
callback: core::ptr::null_mut(),
min_sendable: Default::default(),
max_sendable: Default::default(),
metadata_str: core::ptr::null_mut(),
comment_allowed: Default::default(),
domain: core::ptr::null_mut(),
allows_nostr: Default::default(),
nostr_pubkey: core::ptr::null_mut(),
ln_address: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_ln_url_pay_request_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_pay_result {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: LnUrlPayResultKind { nil__: () },
}
}
}
impl Default for wire_cst_ln_url_pay_result {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_pay_success_data {
fn new_with_null_ptr() -> Self {
Self {
payment: Default::default(),
success_action: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_ln_url_pay_success_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_withdraw_error {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: LnUrlWithdrawErrorKind { nil__: () },
}
}
}
impl Default for wire_cst_ln_url_withdraw_error {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_withdraw_request {
fn new_with_null_ptr() -> Self {
Self {
data: Default::default(),
amount_msat: Default::default(),
description: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_ln_url_withdraw_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_withdraw_request_data {
fn new_with_null_ptr() -> Self {
Self {
callback: core::ptr::null_mut(),
k1: core::ptr::null_mut(),
default_description: core::ptr::null_mut(),
min_withdrawable: Default::default(),
max_withdrawable: Default::default(),
}
}
}
impl Default for wire_cst_ln_url_withdraw_request_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_withdraw_result {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: LnUrlWithdrawResultKind { nil__: () },
}
}
}
impl Default for wire_cst_ln_url_withdraw_result {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_ln_url_withdraw_success_data {
fn new_with_null_ptr() -> Self {
Self {
invoice: Default::default(),
}
}
}
impl Default for wire_cst_ln_url_withdraw_success_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_locale_overrides {
fn new_with_null_ptr() -> Self {
Self {
locale: core::ptr::null_mut(),
spacing: core::ptr::null_mut(),
symbol: Default::default(),
}
}
}
impl Default for wire_cst_locale_overrides {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_localized_name {
fn new_with_null_ptr() -> Self {
Self {
locale: core::ptr::null_mut(),
name: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_localized_name {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_log_entry {
fn new_with_null_ptr() -> Self {
Self {
line: core::ptr::null_mut(),
level: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_log_entry {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_message_success_action_data {
fn new_with_null_ptr() -> Self {
Self {
message: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_message_success_action_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_onchain_payment_limits_response {
fn new_with_null_ptr() -> Self {
Self {
send: Default::default(),
receive: Default::default(),
}
}
}
impl Default for wire_cst_onchain_payment_limits_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_pay_onchain_request {
fn new_with_null_ptr() -> Self {
Self {
address: core::ptr::null_mut(),
prepare_res: Default::default(),
}
}
}
impl Default for wire_cst_pay_onchain_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_payment {
fn new_with_null_ptr() -> Self {
Self {
tx_id: core::ptr::null_mut(),
swap_id: core::ptr::null_mut(),
timestamp: Default::default(),
amount_sat: Default::default(),
fees_sat: Default::default(),
preimage: core::ptr::null_mut(),
bolt11: core::ptr::null_mut(),
description: core::ptr::null_mut(),
refund_tx_id: core::ptr::null_mut(),
refund_tx_amount_sat: core::ptr::null_mut(),
payment_type: Default::default(),
status: Default::default(),
}
}
}
impl Default for wire_cst_payment {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_payment_error {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: PaymentErrorKind { nil__: () },
}
}
}
impl Default for wire_cst_payment_error {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_buy_bitcoin_request {
fn new_with_null_ptr() -> Self {
Self {
provider: Default::default(),
amount_sat: Default::default(),
}
}
}
impl Default for wire_cst_prepare_buy_bitcoin_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_buy_bitcoin_response {
fn new_with_null_ptr() -> Self {
Self {
provider: Default::default(),
amount_sat: Default::default(),
fees_sat: Default::default(),
}
}
}
impl Default for wire_cst_prepare_buy_bitcoin_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_pay_onchain_request {
fn new_with_null_ptr() -> Self {
Self {
receiver_amount_sat: Default::default(),
sat_per_vbyte: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_prepare_pay_onchain_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_pay_onchain_response {
fn new_with_null_ptr() -> Self {
Self {
receiver_amount_sat: Default::default(),
claim_fees_sat: Default::default(),
total_fees_sat: Default::default(),
}
}
}
impl Default for wire_cst_prepare_pay_onchain_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_receive_onchain_request {
fn new_with_null_ptr() -> Self {
Self {
payer_amount_sat: Default::default(),
}
}
}
impl Default for wire_cst_prepare_receive_onchain_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_receive_onchain_response {
fn new_with_null_ptr() -> Self {
Self {
payer_amount_sat: Default::default(),
fees_sat: Default::default(),
}
}
}
impl Default for wire_cst_prepare_receive_onchain_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_receive_payment_request {
fn new_with_null_ptr() -> Self {
Self {
payer_amount_sat: Default::default(),
}
}
}
impl Default for wire_cst_prepare_receive_payment_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_receive_payment_response {
fn new_with_null_ptr() -> Self {
Self {
payer_amount_sat: Default::default(),
fees_sat: Default::default(),
}
}
}
impl Default for wire_cst_prepare_receive_payment_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_refund_request {
fn new_with_null_ptr() -> Self {
Self {
swap_address: core::ptr::null_mut(),
refund_address: core::ptr::null_mut(),
sat_per_vbyte: Default::default(),
}
}
}
impl Default for wire_cst_prepare_refund_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_refund_response {
fn new_with_null_ptr() -> Self {
Self {
tx_vsize: Default::default(),
tx_fee_sat: Default::default(),
refund_tx_id: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_prepare_refund_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_send_request {
fn new_with_null_ptr() -> Self {
Self {
invoice: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_prepare_send_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_prepare_send_response {
fn new_with_null_ptr() -> Self {
Self {
invoice: core::ptr::null_mut(),
fees_sat: Default::default(),
}
}
}
impl Default for wire_cst_prepare_send_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_rate {
fn new_with_null_ptr() -> Self {
Self {
coin: core::ptr::null_mut(),
value: Default::default(),
}
}
}
impl Default for wire_cst_rate {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_receive_onchain_response {
fn new_with_null_ptr() -> Self {
Self {
address: core::ptr::null_mut(),
bip21: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_receive_onchain_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_receive_payment_request {
fn new_with_null_ptr() -> Self {
Self {
prepare_res: Default::default(),
description: core::ptr::null_mut(),
use_description_hash: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_receive_payment_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_receive_payment_response {
fn new_with_null_ptr() -> Self {
Self {
id: core::ptr::null_mut(),
invoice: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_receive_payment_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_recommended_fees {
fn new_with_null_ptr() -> Self {
Self {
fastest_fee: Default::default(),
half_hour_fee: Default::default(),
hour_fee: Default::default(),
economy_fee: Default::default(),
minimum_fee: Default::default(),
}
}
}
impl Default for wire_cst_recommended_fees {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_refund_request {
fn new_with_null_ptr() -> Self {
Self {
swap_address: core::ptr::null_mut(),
refund_address: core::ptr::null_mut(),
sat_per_vbyte: Default::default(),
}
}
}
impl Default for wire_cst_refund_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_refund_response {
fn new_with_null_ptr() -> Self {
Self {
refund_tx_id: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_refund_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_refundable_swap {
fn new_with_null_ptr() -> Self {
Self {
swap_address: core::ptr::null_mut(),
timestamp: Default::default(),
amount_sat: Default::default(),
}
}
}
impl Default for wire_cst_refundable_swap {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_restore_request {
fn new_with_null_ptr() -> Self {
Self {
backup_path: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_restore_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_route_hint {
fn new_with_null_ptr() -> Self {
Self {
hops: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_route_hint {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_route_hint_hop {
fn new_with_null_ptr() -> Self {
Self {
src_node_id: core::ptr::null_mut(),
short_channel_id: Default::default(),
fees_base_msat: Default::default(),
fees_proportional_millionths: Default::default(),
cltv_expiry_delta: Default::default(),
htlc_minimum_msat: core::ptr::null_mut(),
htlc_maximum_msat: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_route_hint_hop {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_sdk_error {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: SdkErrorKind { nil__: () },
}
}
}
impl Default for wire_cst_sdk_error {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_sdk_event {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: SdkEventKind { nil__: () },
}
}
}
impl Default for wire_cst_sdk_event {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_send_payment_response {
fn new_with_null_ptr() -> Self {
Self {
payment: Default::default(),
}
}
}
impl Default for wire_cst_send_payment_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_sign_message_request {
fn new_with_null_ptr() -> Self {
Self {
message: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_sign_message_request {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_sign_message_response {
fn new_with_null_ptr() -> Self {
Self {
signature: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_sign_message_response {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_success_action_processed {
fn new_with_null_ptr() -> Self {
Self {
tag: -1,
kind: SuccessActionProcessedKind { nil__: () },
}
}
}
impl Default for wire_cst_success_action_processed {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_symbol {
fn new_with_null_ptr() -> Self {
Self {
grapheme: core::ptr::null_mut(),
template: core::ptr::null_mut(),
rtl: core::ptr::null_mut(),
position: core::ptr::null_mut(),
}
}
}
impl Default for wire_cst_symbol {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
impl NewWithNullPtr for wire_cst_url_success_action_data {
fn new_with_null_ptr() -> Self {
Self {
description: core::ptr::null_mut(),
url: core::ptr::null_mut(),
matches_callback_domain: Default::default(),
}
}
}
impl Default for wire_cst_url_success_action_data {
fn default() -> Self {
Self::new_with_null_ptr()
}
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_add_event_listener(
port_: i64,
that: usize,
listener: *mut wire_cst_list_prim_u_8_strict,
) {
wire__crate__bindings__BindingLiquidSdk_add_event_listener_impl(port_, that, listener)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_backup(
that: usize,
req: *mut wire_cst_backup_request,
) -> flutter_rust_bridge::for_generated::WireSyncRust2DartDco {
wire__crate__bindings__BindingLiquidSdk_backup_impl(that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_buy_bitcoin(
port_: i64,
that: usize,
req: *mut wire_cst_buy_bitcoin_request,
) {
wire__crate__bindings__BindingLiquidSdk_buy_bitcoin_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_check_message(
that: usize,
req: *mut wire_cst_check_message_request,
) -> flutter_rust_bridge::for_generated::WireSyncRust2DartDco {
wire__crate__bindings__BindingLiquidSdk_check_message_impl(that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_disconnect(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_disconnect_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_empty_wallet_cache(
that: usize,
) -> flutter_rust_bridge::for_generated::WireSyncRust2DartDco {
wire__crate__bindings__BindingLiquidSdk_empty_wallet_cache_impl(that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_fetch_fiat_rates(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_fetch_fiat_rates_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_fetch_lightning_limits(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_fetch_lightning_limits_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_fetch_onchain_limits(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_fetch_onchain_limits_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_get_info(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_get_info_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_list_fiat_currencies(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_list_fiat_currencies_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_list_payments(
port_: i64,
that: usize,
req: *mut wire_cst_list_payments_request,
) {
wire__crate__bindings__BindingLiquidSdk_list_payments_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_list_refundables(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_list_refundables_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_lnurl_auth(
port_: i64,
that: usize,
req_data: *mut wire_cst_ln_url_auth_request_data,
) {
wire__crate__bindings__BindingLiquidSdk_lnurl_auth_impl(port_, that, req_data)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_lnurl_pay(
port_: i64,
that: usize,
req: *mut wire_cst_ln_url_pay_request,
) {
wire__crate__bindings__BindingLiquidSdk_lnurl_pay_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_lnurl_withdraw(
port_: i64,
that: usize,
req: *mut wire_cst_ln_url_withdraw_request,
) {
wire__crate__bindings__BindingLiquidSdk_lnurl_withdraw_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_pay_onchain(
port_: i64,
that: usize,
req: *mut wire_cst_pay_onchain_request,
) {
wire__crate__bindings__BindingLiquidSdk_pay_onchain_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_prepare_buy_bitcoin(
port_: i64,
that: usize,
req: *mut wire_cst_prepare_buy_bitcoin_request,
) {
wire__crate__bindings__BindingLiquidSdk_prepare_buy_bitcoin_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_prepare_pay_onchain(
port_: i64,
that: usize,
req: *mut wire_cst_prepare_pay_onchain_request,
) {
wire__crate__bindings__BindingLiquidSdk_prepare_pay_onchain_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_prepare_receive_onchain(
port_: i64,
that: usize,
req: *mut wire_cst_prepare_receive_onchain_request,
) {
wire__crate__bindings__BindingLiquidSdk_prepare_receive_onchain_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_prepare_receive_payment(
port_: i64,
that: usize,
req: *mut wire_cst_prepare_receive_payment_request,
) {
wire__crate__bindings__BindingLiquidSdk_prepare_receive_payment_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_prepare_refund(
port_: i64,
that: usize,
req: *mut wire_cst_prepare_refund_request,
) {
wire__crate__bindings__BindingLiquidSdk_prepare_refund_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_prepare_send_payment(
port_: i64,
that: usize,
req: *mut wire_cst_prepare_send_request,
) {
wire__crate__bindings__BindingLiquidSdk_prepare_send_payment_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_receive_onchain(
port_: i64,
that: usize,
req: *mut wire_cst_prepare_receive_onchain_response,
) {
wire__crate__bindings__BindingLiquidSdk_receive_onchain_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_receive_payment(
port_: i64,
that: usize,
req: *mut wire_cst_receive_payment_request,
) {
wire__crate__bindings__BindingLiquidSdk_receive_payment_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_recommended_fees(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_recommended_fees_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_refund(
port_: i64,
that: usize,
req: *mut wire_cst_refund_request,
) {
wire__crate__bindings__BindingLiquidSdk_refund_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_register_webhook(
port_: i64,
that: usize,
webhook_url: *mut wire_cst_list_prim_u_8_strict,
) {
wire__crate__bindings__BindingLiquidSdk_register_webhook_impl(port_, that, webhook_url)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_rescan_onchain_swaps(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_rescan_onchain_swaps_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_restore(
that: usize,
req: *mut wire_cst_restore_request,
) -> flutter_rust_bridge::for_generated::WireSyncRust2DartDco {
wire__crate__bindings__BindingLiquidSdk_restore_impl(that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_send_payment(
port_: i64,
that: usize,
req: *mut wire_cst_prepare_send_response,
) {
wire__crate__bindings__BindingLiquidSdk_send_payment_impl(port_, that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_sign_message(
that: usize,
req: *mut wire_cst_sign_message_request,
) -> flutter_rust_bridge::for_generated::WireSyncRust2DartDco {
wire__crate__bindings__BindingLiquidSdk_sign_message_impl(that, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_sync(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_sync_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__BindingLiquidSdk_unregister_webhook(
port_: i64,
that: usize,
) {
wire__crate__bindings__BindingLiquidSdk_unregister_webhook_impl(port_, that)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__binding_event_listener_on_event(
port_: i64,
that: *mut wire_cst_binding_event_listener,
e: *mut wire_cst_sdk_event,
) {
wire__crate__bindings__binding_event_listener_on_event_impl(port_, that, e)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__breez_log_stream(
port_: i64,
s: *mut wire_cst_list_prim_u_8_strict,
) {
wire__crate__bindings__breez_log_stream_impl(port_, s)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__connect(
port_: i64,
req: *mut wire_cst_connect_request,
) {
wire__crate__bindings__connect_impl(port_, req)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__default_config(
network: i32,
) -> flutter_rust_bridge::for_generated::WireSyncRust2DartDco {
wire__crate__bindings__default_config_impl(network)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__parse(
port_: i64,
input: *mut wire_cst_list_prim_u_8_strict,
) {
wire__crate__bindings__parse_impl(port_, input)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_wire__crate__bindings__parse_invoice(
input: *mut wire_cst_list_prim_u_8_strict,
) -> flutter_rust_bridge::for_generated::WireSyncRust2DartDco {
wire__crate__bindings__parse_invoice_impl(input)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_rust_arc_increment_strong_count_RustOpaque_flutter_rust_bridgefor_generatedRustAutoOpaqueInnerBindingLiquidSdk(
ptr: *const std::ffi::c_void,
) {
unsafe {
StdArc::<flutter_rust_bridge::for_generated::RustAutoOpaqueInner<BindingLiquidSdk>>::increment_strong_count(ptr as _);
}
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_rust_arc_decrement_strong_count_RustOpaque_flutter_rust_bridgefor_generatedRustAutoOpaqueInnerBindingLiquidSdk(
ptr: *const std::ffi::c_void,
) {
unsafe {
StdArc::<flutter_rust_bridge::for_generated::RustAutoOpaqueInner<BindingLiquidSdk>>::decrement_strong_count(ptr as _);
}
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_aes_success_action_data_decrypted(
) -> *mut wire_cst_aes_success_action_data_decrypted {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_aes_success_action_data_decrypted::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_aes_success_action_data_result(
) -> *mut wire_cst_aes_success_action_data_result {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_aes_success_action_data_result::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_backup_request(
) -> *mut wire_cst_backup_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_backup_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_binding_event_listener(
) -> *mut wire_cst_binding_event_listener {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_binding_event_listener::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_bitcoin_address_data(
) -> *mut wire_cst_bitcoin_address_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_bitcoin_address_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_bool(value: bool) -> *mut bool {
flutter_rust_bridge::for_generated::new_leak_box_ptr(value)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_buy_bitcoin_request(
) -> *mut wire_cst_buy_bitcoin_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_buy_bitcoin_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_check_message_request(
) -> *mut wire_cst_check_message_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_check_message_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_connect_request(
) -> *mut wire_cst_connect_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_connect_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_i_64(value: i64) -> *mut i64 {
flutter_rust_bridge::for_generated::new_leak_box_ptr(value)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_list_payments_request(
) -> *mut wire_cst_list_payments_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_list_payments_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_invoice() -> *mut wire_cst_ln_invoice {
flutter_rust_bridge::for_generated::new_leak_box_ptr(wire_cst_ln_invoice::new_with_null_ptr())
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_url_auth_request_data(
) -> *mut wire_cst_ln_url_auth_request_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_ln_url_auth_request_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_url_error_data(
) -> *mut wire_cst_ln_url_error_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_ln_url_error_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_url_pay_error_data(
) -> *mut wire_cst_ln_url_pay_error_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_ln_url_pay_error_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_url_pay_request(
) -> *mut wire_cst_ln_url_pay_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_ln_url_pay_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_url_pay_request_data(
) -> *mut wire_cst_ln_url_pay_request_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_ln_url_pay_request_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_url_pay_success_data(
) -> *mut wire_cst_ln_url_pay_success_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_ln_url_pay_success_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_url_withdraw_request(
) -> *mut wire_cst_ln_url_withdraw_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_ln_url_withdraw_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_url_withdraw_request_data(
) -> *mut wire_cst_ln_url_withdraw_request_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_ln_url_withdraw_request_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_ln_url_withdraw_success_data(
) -> *mut wire_cst_ln_url_withdraw_success_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_ln_url_withdraw_success_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_message_success_action_data(
) -> *mut wire_cst_message_success_action_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_message_success_action_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_pay_onchain_request(
) -> *mut wire_cst_pay_onchain_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_pay_onchain_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_payment() -> *mut wire_cst_payment {
flutter_rust_bridge::for_generated::new_leak_box_ptr(wire_cst_payment::new_with_null_ptr())
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_prepare_buy_bitcoin_request(
) -> *mut wire_cst_prepare_buy_bitcoin_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_prepare_buy_bitcoin_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_prepare_pay_onchain_request(
) -> *mut wire_cst_prepare_pay_onchain_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_prepare_pay_onchain_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_onchain_request(
) -> *mut wire_cst_prepare_receive_onchain_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_prepare_receive_onchain_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_onchain_response(
) -> *mut wire_cst_prepare_receive_onchain_response {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_prepare_receive_onchain_response::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_payment_request(
) -> *mut wire_cst_prepare_receive_payment_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_prepare_receive_payment_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_prepare_refund_request(
) -> *mut wire_cst_prepare_refund_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_prepare_refund_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_request(
) -> *mut wire_cst_prepare_send_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_prepare_send_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_response(
) -> *mut wire_cst_prepare_send_response {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_prepare_send_response::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_receive_payment_request(
) -> *mut wire_cst_receive_payment_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_receive_payment_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_refund_request(
) -> *mut wire_cst_refund_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_refund_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_restore_request(
) -> *mut wire_cst_restore_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_restore_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_sdk_event() -> *mut wire_cst_sdk_event {
flutter_rust_bridge::for_generated::new_leak_box_ptr(wire_cst_sdk_event::new_with_null_ptr())
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_sign_message_request(
) -> *mut wire_cst_sign_message_request {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_sign_message_request::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_success_action_processed(
) -> *mut wire_cst_success_action_processed {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_success_action_processed::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_symbol() -> *mut wire_cst_symbol {
flutter_rust_bridge::for_generated::new_leak_box_ptr(wire_cst_symbol::new_with_null_ptr())
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_u_32(value: u32) -> *mut u32 {
flutter_rust_bridge::for_generated::new_leak_box_ptr(value)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_u_64(value: u64) -> *mut u64 {
flutter_rust_bridge::for_generated::new_leak_box_ptr(value)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_box_autoadd_url_success_action_data(
) -> *mut wire_cst_url_success_action_data {
flutter_rust_bridge::for_generated::new_leak_box_ptr(
wire_cst_url_success_action_data::new_with_null_ptr(),
)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_fiat_currency(
len: i32,
) -> *mut wire_cst_list_fiat_currency {
let wrap = wire_cst_list_fiat_currency {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(
<wire_cst_fiat_currency>::new_with_null_ptr(),
len,
),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(wrap)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_locale_overrides(
len: i32,
) -> *mut wire_cst_list_locale_overrides {
let wrap = wire_cst_list_locale_overrides {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(
<wire_cst_locale_overrides>::new_with_null_ptr(),
len,
),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(wrap)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_localized_name(
len: i32,
) -> *mut wire_cst_list_localized_name {
let wrap = wire_cst_list_localized_name {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(
<wire_cst_localized_name>::new_with_null_ptr(),
len,
),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(wrap)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_payment(len: i32) -> *mut wire_cst_list_payment {
let wrap = wire_cst_list_payment {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(
<wire_cst_payment>::new_with_null_ptr(),
len,
),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(wrap)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_payment_type(
len: i32,
) -> *mut wire_cst_list_payment_type {
let wrap = wire_cst_list_payment_type {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(Default::default(), len),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(wrap)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_prim_u_8_strict(
len: i32,
) -> *mut wire_cst_list_prim_u_8_strict {
let ans = wire_cst_list_prim_u_8_strict {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(Default::default(), len),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(ans)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_rate(len: i32) -> *mut wire_cst_list_rate {
let wrap = wire_cst_list_rate {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(
<wire_cst_rate>::new_with_null_ptr(),
len,
),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(wrap)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_refundable_swap(
len: i32,
) -> *mut wire_cst_list_refundable_swap {
let wrap = wire_cst_list_refundable_swap {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(
<wire_cst_refundable_swap>::new_with_null_ptr(),
len,
),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(wrap)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_route_hint(
len: i32,
) -> *mut wire_cst_list_route_hint {
let wrap = wire_cst_list_route_hint {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(
<wire_cst_route_hint>::new_with_null_ptr(),
len,
),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(wrap)
}
#[no_mangle]
pub extern "C" fn frbgen_breez_liquid_cst_new_list_route_hint_hop(
len: i32,
) -> *mut wire_cst_list_route_hint_hop {
let wrap = wire_cst_list_route_hint_hop {
ptr: flutter_rust_bridge::for_generated::new_leak_vec_ptr(
<wire_cst_route_hint_hop>::new_with_null_ptr(),
len,
),
len,
};
flutter_rust_bridge::for_generated::new_leak_box_ptr(wrap)
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_aes_success_action_data_decrypted {
description: *mut wire_cst_list_prim_u_8_strict,
plaintext: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_aes_success_action_data_result {
tag: i32,
kind: AesSuccessActionDataResultKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union AesSuccessActionDataResultKind {
Decrypted: wire_cst_AesSuccessActionDataResult_Decrypted,
ErrorStatus: wire_cst_AesSuccessActionDataResult_ErrorStatus,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_AesSuccessActionDataResult_Decrypted {
data: *mut wire_cst_aes_success_action_data_decrypted,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_AesSuccessActionDataResult_ErrorStatus {
reason: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_backup_request {
backup_path: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_binding_event_listener {
stream: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_bitcoin_address_data {
address: *mut wire_cst_list_prim_u_8_strict,
network: i32,
amount_sat: *mut u64,
label: *mut wire_cst_list_prim_u_8_strict,
message: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_buy_bitcoin_request {
prepare_res: wire_cst_prepare_buy_bitcoin_response,
redirect_url: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_check_message_request {
message: *mut wire_cst_list_prim_u_8_strict,
pubkey: *mut wire_cst_list_prim_u_8_strict,
signature: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_check_message_response {
is_valid: bool,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_config {
liquid_electrum_url: *mut wire_cst_list_prim_u_8_strict,
bitcoin_electrum_url: *mut wire_cst_list_prim_u_8_strict,
mempoolspace_url: *mut wire_cst_list_prim_u_8_strict,
working_dir: *mut wire_cst_list_prim_u_8_strict,
network: i32,
payment_timeout_sec: u64,
zero_conf_min_fee_rate_msat: u32,
zero_conf_max_amount_sat: *mut u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_connect_request {
mnemonic: *mut wire_cst_list_prim_u_8_strict,
config: wire_cst_config,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_currency_info {
name: *mut wire_cst_list_prim_u_8_strict,
fraction_size: u32,
spacing: *mut u32,
symbol: *mut wire_cst_symbol,
uniq_symbol: *mut wire_cst_symbol,
localized_name: *mut wire_cst_list_localized_name,
locale_overrides: *mut wire_cst_list_locale_overrides,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_fiat_currency {
id: *mut wire_cst_list_prim_u_8_strict,
info: wire_cst_currency_info,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_get_info_response {
balance_sat: u64,
pending_send_sat: u64,
pending_receive_sat: u64,
pubkey: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_input_type {
tag: i32,
kind: InputTypeKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union InputTypeKind {
BitcoinAddress: wire_cst_InputType_BitcoinAddress,
Bolt11: wire_cst_InputType_Bolt11,
NodeId: wire_cst_InputType_NodeId,
Url: wire_cst_InputType_Url,
LnUrlPay: wire_cst_InputType_LnUrlPay,
LnUrlWithdraw: wire_cst_InputType_LnUrlWithdraw,
LnUrlAuth: wire_cst_InputType_LnUrlAuth,
LnUrlError: wire_cst_InputType_LnUrlError,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_InputType_BitcoinAddress {
address: *mut wire_cst_bitcoin_address_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_InputType_Bolt11 {
invoice: *mut wire_cst_ln_invoice,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_InputType_NodeId {
node_id: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_InputType_Url {
url: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_InputType_LnUrlPay {
data: *mut wire_cst_ln_url_pay_request_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_InputType_LnUrlWithdraw {
data: *mut wire_cst_ln_url_withdraw_request_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_InputType_LnUrlAuth {
data: *mut wire_cst_ln_url_auth_request_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_InputType_LnUrlError {
data: *mut wire_cst_ln_url_error_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_lightning_payment_limits_response {
send: wire_cst_limits,
receive: wire_cst_limits,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_limits {
min_sat: u64,
max_sat: u64,
max_zero_conf_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_fiat_currency {
ptr: *mut wire_cst_fiat_currency,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_locale_overrides {
ptr: *mut wire_cst_locale_overrides,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_localized_name {
ptr: *mut wire_cst_localized_name,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_payment {
ptr: *mut wire_cst_payment,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_payment_type {
ptr: *mut i32,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_payments_request {
filters: *mut wire_cst_list_payment_type,
from_timestamp: *mut i64,
to_timestamp: *mut i64,
offset: *mut u32,
limit: *mut u32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_prim_u_8_strict {
ptr: *mut u8,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_rate {
ptr: *mut wire_cst_rate,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_refundable_swap {
ptr: *mut wire_cst_refundable_swap,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_route_hint {
ptr: *mut wire_cst_route_hint,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_list_route_hint_hop {
ptr: *mut wire_cst_route_hint_hop,
len: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_invoice {
bolt11: *mut wire_cst_list_prim_u_8_strict,
network: i32,
payee_pubkey: *mut wire_cst_list_prim_u_8_strict,
payment_hash: *mut wire_cst_list_prim_u_8_strict,
description: *mut wire_cst_list_prim_u_8_strict,
description_hash: *mut wire_cst_list_prim_u_8_strict,
amount_msat: *mut u64,
timestamp: u64,
expiry: u64,
routing_hints: *mut wire_cst_list_route_hint,
payment_secret: *mut wire_cst_list_prim_u_8_strict,
min_final_cltv_expiry_delta: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_auth_error {
tag: i32,
kind: LnUrlAuthErrorKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union LnUrlAuthErrorKind {
Generic: wire_cst_LnUrlAuthError_Generic,
InvalidUri: wire_cst_LnUrlAuthError_InvalidUri,
ServiceConnectivity: wire_cst_LnUrlAuthError_ServiceConnectivity,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlAuthError_Generic {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlAuthError_InvalidUri {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlAuthError_ServiceConnectivity {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_auth_request_data {
k1: *mut wire_cst_list_prim_u_8_strict,
action: *mut wire_cst_list_prim_u_8_strict,
domain: *mut wire_cst_list_prim_u_8_strict,
url: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_callback_status {
tag: i32,
kind: LnUrlCallbackStatusKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union LnUrlCallbackStatusKind {
ErrorStatus: wire_cst_LnUrlCallbackStatus_ErrorStatus,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlCallbackStatus_ErrorStatus {
data: *mut wire_cst_ln_url_error_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_error_data {
reason: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_pay_error {
tag: i32,
kind: LnUrlPayErrorKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union LnUrlPayErrorKind {
Generic: wire_cst_LnUrlPayError_Generic,
InvalidAmount: wire_cst_LnUrlPayError_InvalidAmount,
InvalidInvoice: wire_cst_LnUrlPayError_InvalidInvoice,
InvalidNetwork: wire_cst_LnUrlPayError_InvalidNetwork,
InvalidUri: wire_cst_LnUrlPayError_InvalidUri,
InvoiceExpired: wire_cst_LnUrlPayError_InvoiceExpired,
PaymentFailed: wire_cst_LnUrlPayError_PaymentFailed,
PaymentTimeout: wire_cst_LnUrlPayError_PaymentTimeout,
RouteNotFound: wire_cst_LnUrlPayError_RouteNotFound,
RouteTooExpensive: wire_cst_LnUrlPayError_RouteTooExpensive,
ServiceConnectivity: wire_cst_LnUrlPayError_ServiceConnectivity,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_Generic {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_InvalidAmount {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_InvalidInvoice {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_InvalidNetwork {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_InvalidUri {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_InvoiceExpired {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_PaymentFailed {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_PaymentTimeout {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_RouteNotFound {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_RouteTooExpensive {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayError_ServiceConnectivity {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_pay_error_data {
payment_hash: *mut wire_cst_list_prim_u_8_strict,
reason: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_pay_request {
data: wire_cst_ln_url_pay_request_data,
amount_msat: u64,
comment: *mut wire_cst_list_prim_u_8_strict,
payment_label: *mut wire_cst_list_prim_u_8_strict,
validate_success_action_url: *mut bool,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_pay_request_data {
callback: *mut wire_cst_list_prim_u_8_strict,
min_sendable: u64,
max_sendable: u64,
metadata_str: *mut wire_cst_list_prim_u_8_strict,
comment_allowed: u16,
domain: *mut wire_cst_list_prim_u_8_strict,
allows_nostr: bool,
nostr_pubkey: *mut wire_cst_list_prim_u_8_strict,
ln_address: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_pay_result {
tag: i32,
kind: LnUrlPayResultKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union LnUrlPayResultKind {
EndpointSuccess: wire_cst_LnUrlPayResult_EndpointSuccess,
EndpointError: wire_cst_LnUrlPayResult_EndpointError,
PayError: wire_cst_LnUrlPayResult_PayError,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayResult_EndpointSuccess {
data: *mut wire_cst_ln_url_pay_success_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayResult_EndpointError {
data: *mut wire_cst_ln_url_error_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlPayResult_PayError {
data: *mut wire_cst_ln_url_pay_error_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_pay_success_data {
payment: wire_cst_payment,
success_action: *mut wire_cst_success_action_processed,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_withdraw_error {
tag: i32,
kind: LnUrlWithdrawErrorKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union LnUrlWithdrawErrorKind {
Generic: wire_cst_LnUrlWithdrawError_Generic,
InvalidAmount: wire_cst_LnUrlWithdrawError_InvalidAmount,
InvalidInvoice: wire_cst_LnUrlWithdrawError_InvalidInvoice,
InvalidUri: wire_cst_LnUrlWithdrawError_InvalidUri,
InvoiceNoRoutingHints: wire_cst_LnUrlWithdrawError_InvoiceNoRoutingHints,
ServiceConnectivity: wire_cst_LnUrlWithdrawError_ServiceConnectivity,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlWithdrawError_Generic {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlWithdrawError_InvalidAmount {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlWithdrawError_InvalidInvoice {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlWithdrawError_InvalidUri {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlWithdrawError_InvoiceNoRoutingHints {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlWithdrawError_ServiceConnectivity {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_withdraw_request {
data: wire_cst_ln_url_withdraw_request_data,
amount_msat: u64,
description: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_withdraw_request_data {
callback: *mut wire_cst_list_prim_u_8_strict,
k1: *mut wire_cst_list_prim_u_8_strict,
default_description: *mut wire_cst_list_prim_u_8_strict,
min_withdrawable: u64,
max_withdrawable: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_withdraw_result {
tag: i32,
kind: LnUrlWithdrawResultKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union LnUrlWithdrawResultKind {
Ok: wire_cst_LnUrlWithdrawResult_Ok,
Timeout: wire_cst_LnUrlWithdrawResult_Timeout,
ErrorStatus: wire_cst_LnUrlWithdrawResult_ErrorStatus,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlWithdrawResult_Ok {
data: *mut wire_cst_ln_url_withdraw_success_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlWithdrawResult_Timeout {
data: *mut wire_cst_ln_url_withdraw_success_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_LnUrlWithdrawResult_ErrorStatus {
data: *mut wire_cst_ln_url_error_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_ln_url_withdraw_success_data {
invoice: wire_cst_ln_invoice,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_locale_overrides {
locale: *mut wire_cst_list_prim_u_8_strict,
spacing: *mut u32,
symbol: wire_cst_symbol,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_localized_name {
locale: *mut wire_cst_list_prim_u_8_strict,
name: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_log_entry {
line: *mut wire_cst_list_prim_u_8_strict,
level: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_message_success_action_data {
message: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_onchain_payment_limits_response {
send: wire_cst_limits,
receive: wire_cst_limits,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_pay_onchain_request {
address: *mut wire_cst_list_prim_u_8_strict,
prepare_res: wire_cst_prepare_pay_onchain_response,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_payment {
tx_id: *mut wire_cst_list_prim_u_8_strict,
swap_id: *mut wire_cst_list_prim_u_8_strict,
timestamp: u32,
amount_sat: u64,
fees_sat: u64,
preimage: *mut wire_cst_list_prim_u_8_strict,
bolt11: *mut wire_cst_list_prim_u_8_strict,
description: *mut wire_cst_list_prim_u_8_strict,
refund_tx_id: *mut wire_cst_list_prim_u_8_strict,
refund_tx_amount_sat: *mut u64,
payment_type: i32,
status: i32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_payment_error {
tag: i32,
kind: PaymentErrorKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union PaymentErrorKind {
Generic: wire_cst_PaymentError_Generic,
InvalidDescription: wire_cst_PaymentError_InvalidDescription,
InvalidInvoice: wire_cst_PaymentError_InvalidInvoice,
LwkError: wire_cst_PaymentError_LwkError,
ReceiveError: wire_cst_PaymentError_ReceiveError,
Refunded: wire_cst_PaymentError_Refunded,
SendError: wire_cst_PaymentError_SendError,
SignerError: wire_cst_PaymentError_SignerError,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_PaymentError_Generic {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_PaymentError_InvalidDescription {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_PaymentError_InvalidInvoice {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_PaymentError_LwkError {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_PaymentError_ReceiveError {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_PaymentError_Refunded {
err: *mut wire_cst_list_prim_u_8_strict,
refund_tx_id: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_PaymentError_SendError {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_PaymentError_SignerError {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_buy_bitcoin_request {
provider: i32,
amount_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_buy_bitcoin_response {
provider: i32,
amount_sat: u64,
fees_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_pay_onchain_request {
receiver_amount_sat: u64,
sat_per_vbyte: *mut u32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_pay_onchain_response {
receiver_amount_sat: u64,
claim_fees_sat: u64,
total_fees_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_receive_onchain_request {
payer_amount_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_receive_onchain_response {
payer_amount_sat: u64,
fees_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_receive_payment_request {
payer_amount_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_receive_payment_response {
payer_amount_sat: u64,
fees_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_refund_request {
swap_address: *mut wire_cst_list_prim_u_8_strict,
refund_address: *mut wire_cst_list_prim_u_8_strict,
sat_per_vbyte: u32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_refund_response {
tx_vsize: u32,
tx_fee_sat: u64,
refund_tx_id: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_send_request {
invoice: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_prepare_send_response {
invoice: *mut wire_cst_list_prim_u_8_strict,
fees_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_rate {
coin: *mut wire_cst_list_prim_u_8_strict,
value: f64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_receive_onchain_response {
address: *mut wire_cst_list_prim_u_8_strict,
bip21: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_receive_payment_request {
prepare_res: wire_cst_prepare_receive_payment_response,
description: *mut wire_cst_list_prim_u_8_strict,
use_description_hash: *mut bool,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_receive_payment_response {
id: *mut wire_cst_list_prim_u_8_strict,
invoice: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_recommended_fees {
fastest_fee: u64,
half_hour_fee: u64,
hour_fee: u64,
economy_fee: u64,
minimum_fee: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_refund_request {
swap_address: *mut wire_cst_list_prim_u_8_strict,
refund_address: *mut wire_cst_list_prim_u_8_strict,
sat_per_vbyte: u32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_refund_response {
refund_tx_id: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_refundable_swap {
swap_address: *mut wire_cst_list_prim_u_8_strict,
timestamp: u32,
amount_sat: u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_restore_request {
backup_path: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_route_hint {
hops: *mut wire_cst_list_route_hint_hop,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_route_hint_hop {
src_node_id: *mut wire_cst_list_prim_u_8_strict,
short_channel_id: u64,
fees_base_msat: u32,
fees_proportional_millionths: u32,
cltv_expiry_delta: u64,
htlc_minimum_msat: *mut u64,
htlc_maximum_msat: *mut u64,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_sdk_error {
tag: i32,
kind: SdkErrorKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union SdkErrorKind {
Generic: wire_cst_SdkError_Generic,
ServiceConnectivity: wire_cst_SdkError_ServiceConnectivity,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SdkError_Generic {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SdkError_ServiceConnectivity {
err: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_sdk_event {
tag: i32,
kind: SdkEventKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union SdkEventKind {
PaymentFailed: wire_cst_SdkEvent_PaymentFailed,
PaymentPending: wire_cst_SdkEvent_PaymentPending,
PaymentRefunded: wire_cst_SdkEvent_PaymentRefunded,
PaymentRefundPending: wire_cst_SdkEvent_PaymentRefundPending,
PaymentSucceeded: wire_cst_SdkEvent_PaymentSucceeded,
PaymentWaitingConfirmation: wire_cst_SdkEvent_PaymentWaitingConfirmation,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SdkEvent_PaymentFailed {
details: *mut wire_cst_payment,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SdkEvent_PaymentPending {
details: *mut wire_cst_payment,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SdkEvent_PaymentRefunded {
details: *mut wire_cst_payment,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SdkEvent_PaymentRefundPending {
details: *mut wire_cst_payment,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SdkEvent_PaymentSucceeded {
details: *mut wire_cst_payment,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SdkEvent_PaymentWaitingConfirmation {
details: *mut wire_cst_payment,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_send_payment_response {
payment: wire_cst_payment,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_sign_message_request {
message: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_sign_message_response {
signature: *mut wire_cst_list_prim_u_8_strict,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_success_action_processed {
tag: i32,
kind: SuccessActionProcessedKind,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub union SuccessActionProcessedKind {
Aes: wire_cst_SuccessActionProcessed_Aes,
Message: wire_cst_SuccessActionProcessed_Message,
Url: wire_cst_SuccessActionProcessed_Url,
nil__: (),
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SuccessActionProcessed_Aes {
result: *mut wire_cst_aes_success_action_data_result,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SuccessActionProcessed_Message {
data: *mut wire_cst_message_success_action_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_SuccessActionProcessed_Url {
data: *mut wire_cst_url_success_action_data,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_symbol {
grapheme: *mut wire_cst_list_prim_u_8_strict,
template: *mut wire_cst_list_prim_u_8_strict,
rtl: *mut bool,
position: *mut u32,
}
#[repr(C)]
#[derive(Clone, Copy)]
pub struct wire_cst_url_success_action_data {
description: *mut wire_cst_list_prim_u_8_strict,
url: *mut wire_cst_list_prim_u_8_strict,
matches_callback_domain: bool,
}