Move dart & flutter packages to packages folder on root
1
lib/bindings/bindings-flutter/.flutter-version
Normal file
@@ -0,0 +1 @@
|
|||||||
|
stable
|
||||||
@@ -1,200 +0,0 @@
|
|||||||
#include <stdbool.h>
|
|
||||||
#include <stdint.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
// EXTRA BEGIN
|
|
||||||
typedef struct DartCObject *WireSyncRust2DartDco;
|
|
||||||
typedef struct WireSyncRust2DartSse {
|
|
||||||
uint8_t *ptr;
|
|
||||||
int32_t len;
|
|
||||||
} WireSyncRust2DartSse;
|
|
||||||
|
|
||||||
typedef int64_t DartPort;
|
|
||||||
typedef bool (*DartPostCObjectFnType)(DartPort port_id, void *message);
|
|
||||||
void store_dart_post_cobject(DartPostCObjectFnType ptr);
|
|
||||||
// EXTRA END
|
|
||||||
typedef struct _Dart_Handle* Dart_Handle;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Claim tx feerate for Receive, in sats per vbyte.
|
|
||||||
* Since the Liquid blocks are consistently empty for now, we hardcode the minimum feerate.
|
|
||||||
*/
|
|
||||||
#define LIQUID_CLAIM_TX_FEERATE 0.1
|
|
||||||
|
|
||||||
typedef struct wire_cst_list_prim_u_8_strict {
|
|
||||||
uint8_t *ptr;
|
|
||||||
int32_t len;
|
|
||||||
} wire_cst_list_prim_u_8_strict;
|
|
||||||
|
|
||||||
typedef struct wire_cst_connect_request {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *mnemonic;
|
|
||||||
struct wire_cst_list_prim_u_8_strict *data_dir;
|
|
||||||
int32_t network;
|
|
||||||
} wire_cst_connect_request;
|
|
||||||
|
|
||||||
typedef struct wire_cst_get_info_request {
|
|
||||||
bool with_scan;
|
|
||||||
} wire_cst_get_info_request;
|
|
||||||
|
|
||||||
typedef struct wire_cst_prepare_receive_request {
|
|
||||||
uint64_t payer_amount_sat;
|
|
||||||
} wire_cst_prepare_receive_request;
|
|
||||||
|
|
||||||
typedef struct wire_cst_prepare_send_request {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *invoice;
|
|
||||||
} wire_cst_prepare_send_request;
|
|
||||||
|
|
||||||
typedef struct wire_cst_prepare_receive_response {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *pair_hash;
|
|
||||||
uint64_t payer_amount_sat;
|
|
||||||
uint64_t fees_sat;
|
|
||||||
} wire_cst_prepare_receive_response;
|
|
||||||
|
|
||||||
typedef struct wire_cst_restore_request {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *backup_path;
|
|
||||||
} wire_cst_restore_request;
|
|
||||||
|
|
||||||
typedef struct wire_cst_prepare_send_response {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *id;
|
|
||||||
uint64_t payer_amount_sat;
|
|
||||||
uint64_t receiver_amount_sat;
|
|
||||||
uint64_t total_fees;
|
|
||||||
struct wire_cst_list_prim_u_8_strict *funding_address;
|
|
||||||
struct wire_cst_list_prim_u_8_strict *invoice;
|
|
||||||
} wire_cst_prepare_send_response;
|
|
||||||
|
|
||||||
typedef struct wire_cst_payment {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *id;
|
|
||||||
uint32_t *timestamp;
|
|
||||||
uint64_t amount_sat;
|
|
||||||
uint64_t *fees_sat;
|
|
||||||
int32_t payment_type;
|
|
||||||
struct wire_cst_list_prim_u_8_strict *invoice;
|
|
||||||
} wire_cst_payment;
|
|
||||||
|
|
||||||
typedef struct wire_cst_list_payment {
|
|
||||||
struct wire_cst_payment *ptr;
|
|
||||||
int32_t len;
|
|
||||||
} wire_cst_list_payment;
|
|
||||||
|
|
||||||
typedef struct wire_cst_get_info_response {
|
|
||||||
uint64_t balance_sat;
|
|
||||||
struct wire_cst_list_prim_u_8_strict *pubkey;
|
|
||||||
} wire_cst_get_info_response;
|
|
||||||
|
|
||||||
typedef struct wire_cst_PaymentError_Generic {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *err;
|
|
||||||
} wire_cst_PaymentError_Generic;
|
|
||||||
|
|
||||||
typedef struct wire_cst_PaymentError_LwkError {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *err;
|
|
||||||
} wire_cst_PaymentError_LwkError;
|
|
||||||
|
|
||||||
typedef struct wire_cst_PaymentError_SendError {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *err;
|
|
||||||
} wire_cst_PaymentError_SendError;
|
|
||||||
|
|
||||||
typedef struct wire_cst_PaymentError_SignerError {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *err;
|
|
||||||
} wire_cst_PaymentError_SignerError;
|
|
||||||
|
|
||||||
typedef union PaymentErrorKind {
|
|
||||||
struct wire_cst_PaymentError_Generic Generic;
|
|
||||||
struct wire_cst_PaymentError_LwkError LwkError;
|
|
||||||
struct wire_cst_PaymentError_SendError SendError;
|
|
||||||
struct wire_cst_PaymentError_SignerError SignerError;
|
|
||||||
} PaymentErrorKind;
|
|
||||||
|
|
||||||
typedef struct wire_cst_payment_error {
|
|
||||||
int32_t tag;
|
|
||||||
union PaymentErrorKind kind;
|
|
||||||
} wire_cst_payment_error;
|
|
||||||
|
|
||||||
typedef struct wire_cst_receive_payment_response {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *id;
|
|
||||||
struct wire_cst_list_prim_u_8_strict *invoice;
|
|
||||||
} wire_cst_receive_payment_response;
|
|
||||||
|
|
||||||
typedef struct wire_cst_send_payment_response {
|
|
||||||
struct wire_cst_list_prim_u_8_strict *txid;
|
|
||||||
} wire_cst_send_payment_response;
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_backup(int64_t port_);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_connect(int64_t port_, struct wire_cst_connect_request *req);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_empty_wallet_cache(int64_t port_);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_get_info(int64_t port_, struct wire_cst_get_info_request *req);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_list_payments(int64_t port_, bool with_scan, bool include_pending);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_prepare_receive_payment(int64_t port_,
|
|
||||||
struct wire_cst_prepare_receive_request *req);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_prepare_send_payment(int64_t port_,
|
|
||||||
struct wire_cst_prepare_send_request *req);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_receive_payment(int64_t port_,
|
|
||||||
struct wire_cst_prepare_receive_response *req);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_recover_funds(int64_t port_, uintptr_t recovery);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_restore(int64_t port_, struct wire_cst_restore_request *req);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_send_payment(int64_t port_,
|
|
||||||
struct wire_cst_prepare_send_response *req);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_rust_arc_increment_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery(const void *ptr);
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_rust_arc_decrement_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery(const void *ptr);
|
|
||||||
|
|
||||||
struct wire_cst_connect_request *frbgen_breez_liquid_cst_new_box_autoadd_connect_request(void);
|
|
||||||
|
|
||||||
struct wire_cst_get_info_request *frbgen_breez_liquid_cst_new_box_autoadd_get_info_request(void);
|
|
||||||
|
|
||||||
struct wire_cst_prepare_receive_request *frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_request(void);
|
|
||||||
|
|
||||||
struct wire_cst_prepare_receive_response *frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_response(void);
|
|
||||||
|
|
||||||
struct wire_cst_prepare_send_request *frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_request(void);
|
|
||||||
|
|
||||||
struct wire_cst_prepare_send_response *frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_response(void);
|
|
||||||
|
|
||||||
struct wire_cst_restore_request *frbgen_breez_liquid_cst_new_box_autoadd_restore_request(void);
|
|
||||||
|
|
||||||
uint32_t *frbgen_breez_liquid_cst_new_box_autoadd_u_32(uint32_t value);
|
|
||||||
|
|
||||||
uint64_t *frbgen_breez_liquid_cst_new_box_autoadd_u_64(uint64_t value);
|
|
||||||
|
|
||||||
struct wire_cst_list_payment *frbgen_breez_liquid_cst_new_list_payment(int32_t len);
|
|
||||||
|
|
||||||
struct wire_cst_list_prim_u_8_strict *frbgen_breez_liquid_cst_new_list_prim_u_8_strict(int32_t len);
|
|
||||||
static int64_t dummy_method_to_enforce_bundling(void) {
|
|
||||||
int64_t dummy_var = 0;
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_box_autoadd_connect_request);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_box_autoadd_get_info_request);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_request);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_response);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_request);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_response);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_box_autoadd_restore_request);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_box_autoadd_u_32);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_box_autoadd_u_64);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_list_payment);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_cst_new_list_prim_u_8_strict);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_rust_arc_decrement_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_rust_arc_increment_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_backup);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_connect);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_empty_wallet_cache);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_get_info);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_list_payments);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_prepare_receive_payment);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_prepare_send_payment);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_receive_payment);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_recover_funds);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_restore);
|
|
||||||
dummy_var ^= ((int64_t) (void*) frbgen_breez_liquid_wire_send_payment);
|
|
||||||
dummy_var ^= ((int64_t) (void*) store_dart_post_cobject);
|
|
||||||
return dummy_var;
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
rust_input: ../../core/src/bindings.rs
|
rust_input: ../../core/src/bindings.rs
|
||||||
dart_output: packages/breez_liquid/lib/src
|
dart_output: ../../../packages/dart/lib/src
|
||||||
rust_output: ../../core/src/frb/bridge.rs
|
rust_output: ../../core/src/frb/bridge.rs
|
||||||
c_output: breez_liquid_sdk/include/breez_liquid_sdk.h
|
c_output: breez_liquid_sdk/include/breez_liquid_sdk.h
|
||||||
duplicated_c_output: [packages/flutter_breez_liquid/macos/Classes/breez_liquid_sdk.h, packages/flutter_breez_liquid/ios/Classes/breez_liquid_sdk.h]
|
duplicated_c_output: [../../../packages/flutter/macos/Classes/breez_liquid_sdk.h, ../../../packages/flutter/ios/Classes/breez_liquid_sdk.h]
|
||||||
web: false
|
web: false
|
||||||
full_dep: true
|
full_dep: true
|
||||||
add_mod_to_lib: false
|
add_mod_to_lib: false
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
curr_version := "breez_liquid-v" + `awk '/^version: /{print $2}' packages/breez_liquid/pubspec.yaml`
|
curr_version := "breez_liquid-v" + `awk '/^version: /{print $2}' ../../../packages/dart/pubspec.yaml`
|
||||||
frb_bin := "flutter_rust_bridge_codegen generate"
|
frb_bin := "flutter_rust_bridge_codegen generate"
|
||||||
|
|
||||||
export CARGO_TERM_COLOR := "always"
|
export CARGO_TERM_COLOR := "always"
|
||||||
@@ -10,11 +10,11 @@ codegen:
|
|||||||
{{frb_bin}}
|
{{frb_bin}}
|
||||||
|
|
||||||
ffigen:
|
ffigen:
|
||||||
cd packages/flutter_breez_liquid/ && flutter pub run ffigen --config ffigen.yaml && cd ..
|
cd ../../../packages/flutter/ && flutter pub run ffigen --config ffigen.yaml && cd ..
|
||||||
|
|
||||||
# builds the local library for testing
|
# builds the local library for testing
|
||||||
build *args:
|
build *args:
|
||||||
cargo build --package breez-liquid-sdk --manifest-path ../core/Cargo.toml --features frb {{args}}
|
cargo build --package breez-liquid-sdk --manifest-path ../../core/Cargo.toml --features frb {{args}}
|
||||||
|
|
||||||
build-apple *args:
|
build-apple *args:
|
||||||
dart scripts/build_apple.dart {{args}}
|
dart scripts/build_apple.dart {{args}}
|
||||||
@@ -34,13 +34,13 @@ test-dart: build
|
|||||||
|
|
||||||
# softlinks library archives from platform-build to their expected locations
|
# softlinks library archives from platform-build to their expected locations
|
||||||
link:
|
link:
|
||||||
-ln -sf $(pwd)/platform-build/breez_liquid_sdk.xcframework.zip packages/flutter_breez_liquid/macos/Frameworks/{{curr_version}}.zip
|
-ln -sf $(pwd)/platform-build/breez_liquid_sdk.xcframework.zip ../../../packages/flutter/macos/Frameworks/{{curr_version}}.zip
|
||||||
-ln -sf $(pwd)/platform-build/breez_liquid_sdk.xcframework.zip packages/flutter_breez_liquid/ios/Frameworks/{{curr_version}}.zip
|
-ln -sf $(pwd)/platform-build/breez_liquid_sdk.xcframework.zip ../../../packages/flutter/ios/Frameworks/{{curr_version}}.zip
|
||||||
-ln -sf $(pwd)/platform-build/other.tar.gz packages/flutter_breez_liquid/linux/{{curr_version}}.tar.gz
|
-ln -sf $(pwd)/platform-build/other.tar.gz ../../../packages/flutter/linux/{{curr_version}}.tar.gz
|
||||||
-ln -sf $(pwd)/platform-build/other.tar.gz packages/flutter_breez_liquid/windows/{{curr_version}}.tar.gz
|
-ln -sf $(pwd)/platform-build/other.tar.gz ../../../packages/flutter/windows/{{curr_version}}.tar.gz
|
||||||
-ln -sf $(pwd)/platform-build/android.tar.gz packages/flutter_breez_liquid/android/{{curr_version}}.tar.gz
|
-ln -sf $(pwd)/platform-build/android.tar.gz ../../../packages/flutter/android/{{curr_version}}.tar.gz
|
||||||
-ln -sf $(pwd)/breez_liquid_sdk/include/breez_liquid_sdk.h packages/flutter_breez_liquid/ios/Classes/breez_liquid_sdk.h
|
-ln -sf $(pwd)/breez_liquid_sdk/include/breez_liquid_sdk.h ../../../packages/flutter/ios/Classes/breez_liquid_sdk.h
|
||||||
-ln -sf $(pwd)/breez_liquid_sdk/include/breez_liquid_sdk.h packages/flutter_breez_liquid/macos/Classes/breez_liquid_sdk.h
|
-ln -sf $(pwd)/breez_liquid_sdk/include/breez_liquid_sdk.h ../../../packages/flutter/macos/Classes/breez_liquid_sdk.h
|
||||||
|
|
||||||
# (melos)
|
# (melos)
|
||||||
test-flutter: build-apple build-android build-other
|
test-flutter: build-apple build-android build-other
|
||||||
@@ -63,4 +63,4 @@ check:
|
|||||||
|
|
||||||
# Open melos.yaml
|
# Open melos.yaml
|
||||||
melos:
|
melos:
|
||||||
@$EDITOR melos.yaml
|
@$EDITOR melos.yaml
|
||||||
@@ -1,16 +1,19 @@
|
|||||||
name: breez_liquid_sdk
|
name: breez_liquid_sdk
|
||||||
repository: https://github.com/breez/breez-liquid-sdk
|
repository: https://github.com/breez/breez-liquid-sdk
|
||||||
packages:
|
packages:
|
||||||
- packages/**
|
- ../../../packages/**
|
||||||
- scripts
|
- scripts
|
||||||
|
ignore:
|
||||||
|
# e.g. ignore example apps
|
||||||
|
- ../../../packages/**/example/**
|
||||||
|
|
||||||
commands:
|
commands:
|
||||||
bootstrap:
|
bootstrap:
|
||||||
hooks:
|
hooks:
|
||||||
post: cargo check --manifest-path ../core/Cargo.toml --features frb
|
post: cargo check --manifest-path ../../core/Cargo.toml --features frb
|
||||||
clean:
|
clean:
|
||||||
hooks:
|
hooks:
|
||||||
pre: cargo clean --manifest-path ../core/Cargo.toml --features frb
|
pre: cargo clean --manifest-path ../../core/Cargo.toml --features frb
|
||||||
version:
|
version:
|
||||||
hooks:
|
hooks:
|
||||||
preCommit: bash scripts/version.sh
|
preCommit: bash scripts/version.sh
|
||||||
|
|||||||
@@ -1,602 +0,0 @@
|
|||||||
// ignore_for_file: always_specify_types
|
|
||||||
// ignore_for_file: camel_case_types
|
|
||||||
// ignore_for_file: non_constant_identifier_names
|
|
||||||
|
|
||||||
// AUTO GENERATED FILE, DO NOT EDIT.
|
|
||||||
//
|
|
||||||
// Generated by `package:ffigen`.
|
|
||||||
// ignore_for_file: type=lint
|
|
||||||
import 'dart:ffi' as ffi;
|
|
||||||
|
|
||||||
/// Bindings for `src/flutter_breez_liquid.h`.
|
|
||||||
///
|
|
||||||
/// Regenerate bindings with `flutter pub run ffigen --config ffigen.yaml`.
|
|
||||||
///
|
|
||||||
class FlutterBreezLiquidBindings {
|
|
||||||
/// Holds the symbol lookup function.
|
|
||||||
final ffi.Pointer<T> Function<T extends ffi.NativeType>(String symbolName)
|
|
||||||
_lookup;
|
|
||||||
|
|
||||||
/// The symbols are looked up in [dynamicLibrary].
|
|
||||||
FlutterBreezLiquidBindings(ffi.DynamicLibrary dynamicLibrary)
|
|
||||||
: _lookup = dynamicLibrary.lookup;
|
|
||||||
|
|
||||||
/// The symbols are looked up with [lookup].
|
|
||||||
FlutterBreezLiquidBindings.fromLookup(
|
|
||||||
ffi.Pointer<T> Function<T extends ffi.NativeType>(String symbolName)
|
|
||||||
lookup)
|
|
||||||
: _lookup = lookup;
|
|
||||||
|
|
||||||
void store_dart_post_cobject(
|
|
||||||
DartPostCObjectFnType ptr,
|
|
||||||
) {
|
|
||||||
return _store_dart_post_cobject(
|
|
||||||
ptr,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _store_dart_post_cobjectPtr =
|
|
||||||
_lookup<ffi.NativeFunction<ffi.Void Function(DartPostCObjectFnType)>>(
|
|
||||||
'store_dart_post_cobject');
|
|
||||||
late final _store_dart_post_cobject = _store_dart_post_cobjectPtr
|
|
||||||
.asFunction<void Function(DartPostCObjectFnType)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_backup(
|
|
||||||
int port_,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_backup(
|
|
||||||
port_,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_backupPtr =
|
|
||||||
_lookup<ffi.NativeFunction<ffi.Void Function(ffi.Int64)>>(
|
|
||||||
'frbgen_breez_liquid_wire_backup');
|
|
||||||
late final _frbgen_breez_liquid_wire_backup =
|
|
||||||
_frbgen_breez_liquid_wire_backupPtr.asFunction<void Function(int)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_connect(
|
|
||||||
int port_,
|
|
||||||
ffi.Pointer<wire_cst_connect_request> req,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_connect(
|
|
||||||
port_,
|
|
||||||
req,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_connectPtr = _lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Void Function(
|
|
||||||
ffi.Int64, ffi.Pointer<wire_cst_connect_request>)>>(
|
|
||||||
'frbgen_breez_liquid_wire_connect');
|
|
||||||
late final _frbgen_breez_liquid_wire_connect =
|
|
||||||
_frbgen_breez_liquid_wire_connectPtr.asFunction<
|
|
||||||
void Function(int, ffi.Pointer<wire_cst_connect_request>)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_empty_wallet_cache(
|
|
||||||
int port_,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_empty_wallet_cache(
|
|
||||||
port_,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_empty_wallet_cachePtr =
|
|
||||||
_lookup<ffi.NativeFunction<ffi.Void Function(ffi.Int64)>>(
|
|
||||||
'frbgen_breez_liquid_wire_empty_wallet_cache');
|
|
||||||
late final _frbgen_breez_liquid_wire_empty_wallet_cache =
|
|
||||||
_frbgen_breez_liquid_wire_empty_wallet_cachePtr
|
|
||||||
.asFunction<void Function(int)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_get_info(
|
|
||||||
int port_,
|
|
||||||
ffi.Pointer<wire_cst_get_info_request> req,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_get_info(
|
|
||||||
port_,
|
|
||||||
req,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_get_infoPtr = _lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Void Function(
|
|
||||||
ffi.Int64, ffi.Pointer<wire_cst_get_info_request>)>>(
|
|
||||||
'frbgen_breez_liquid_wire_get_info');
|
|
||||||
late final _frbgen_breez_liquid_wire_get_info =
|
|
||||||
_frbgen_breez_liquid_wire_get_infoPtr.asFunction<
|
|
||||||
void Function(int, ffi.Pointer<wire_cst_get_info_request>)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_list_payments(
|
|
||||||
int port_,
|
|
||||||
bool with_scan,
|
|
||||||
bool include_pending,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_list_payments(
|
|
||||||
port_,
|
|
||||||
with_scan,
|
|
||||||
include_pending,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_list_paymentsPtr = _lookup<
|
|
||||||
ffi.NativeFunction<ffi.Void Function(ffi.Int64, ffi.Bool, ffi.Bool)>>(
|
|
||||||
'frbgen_breez_liquid_wire_list_payments');
|
|
||||||
late final _frbgen_breez_liquid_wire_list_payments =
|
|
||||||
_frbgen_breez_liquid_wire_list_paymentsPtr
|
|
||||||
.asFunction<void Function(int, bool, bool)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_prepare_receive_payment(
|
|
||||||
int port_,
|
|
||||||
ffi.Pointer<wire_cst_prepare_receive_request> req,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_prepare_receive_payment(
|
|
||||||
port_,
|
|
||||||
req,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_prepare_receive_paymentPtr = _lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Void Function(
|
|
||||||
ffi.Int64, ffi.Pointer<wire_cst_prepare_receive_request>)>>(
|
|
||||||
'frbgen_breez_liquid_wire_prepare_receive_payment');
|
|
||||||
late final _frbgen_breez_liquid_wire_prepare_receive_payment =
|
|
||||||
_frbgen_breez_liquid_wire_prepare_receive_paymentPtr.asFunction<
|
|
||||||
void Function(int, ffi.Pointer<wire_cst_prepare_receive_request>)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_prepare_send_payment(
|
|
||||||
int port_,
|
|
||||||
ffi.Pointer<wire_cst_prepare_send_request> req,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_prepare_send_payment(
|
|
||||||
port_,
|
|
||||||
req,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_prepare_send_paymentPtr = _lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Void Function(
|
|
||||||
ffi.Int64, ffi.Pointer<wire_cst_prepare_send_request>)>>(
|
|
||||||
'frbgen_breez_liquid_wire_prepare_send_payment');
|
|
||||||
late final _frbgen_breez_liquid_wire_prepare_send_payment =
|
|
||||||
_frbgen_breez_liquid_wire_prepare_send_paymentPtr.asFunction<
|
|
||||||
void Function(int, ffi.Pointer<wire_cst_prepare_send_request>)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_receive_payment(
|
|
||||||
int port_,
|
|
||||||
ffi.Pointer<wire_cst_prepare_receive_response> req,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_receive_payment(
|
|
||||||
port_,
|
|
||||||
req,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_receive_paymentPtr = _lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Void Function(
|
|
||||||
ffi.Int64, ffi.Pointer<wire_cst_prepare_receive_response>)>>(
|
|
||||||
'frbgen_breez_liquid_wire_receive_payment');
|
|
||||||
late final _frbgen_breez_liquid_wire_receive_payment =
|
|
||||||
_frbgen_breez_liquid_wire_receive_paymentPtr.asFunction<
|
|
||||||
void Function(int, ffi.Pointer<wire_cst_prepare_receive_response>)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_recover_funds(
|
|
||||||
int port_,
|
|
||||||
int recovery,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_recover_funds(
|
|
||||||
port_,
|
|
||||||
recovery,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_recover_fundsPtr =
|
|
||||||
_lookup<ffi.NativeFunction<ffi.Void Function(ffi.Int64, ffi.UintPtr)>>(
|
|
||||||
'frbgen_breez_liquid_wire_recover_funds');
|
|
||||||
late final _frbgen_breez_liquid_wire_recover_funds =
|
|
||||||
_frbgen_breez_liquid_wire_recover_fundsPtr
|
|
||||||
.asFunction<void Function(int, int)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_restore(
|
|
||||||
int port_,
|
|
||||||
ffi.Pointer<wire_cst_restore_request> req,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_restore(
|
|
||||||
port_,
|
|
||||||
req,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_restorePtr = _lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Void Function(
|
|
||||||
ffi.Int64, ffi.Pointer<wire_cst_restore_request>)>>(
|
|
||||||
'frbgen_breez_liquid_wire_restore');
|
|
||||||
late final _frbgen_breez_liquid_wire_restore =
|
|
||||||
_frbgen_breez_liquid_wire_restorePtr.asFunction<
|
|
||||||
void Function(int, ffi.Pointer<wire_cst_restore_request>)>();
|
|
||||||
|
|
||||||
void frbgen_breez_liquid_wire_send_payment(
|
|
||||||
int port_,
|
|
||||||
ffi.Pointer<wire_cst_prepare_send_response> req,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_wire_send_payment(
|
|
||||||
port_,
|
|
||||||
req,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_wire_send_paymentPtr = _lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Void Function(
|
|
||||||
ffi.Int64, ffi.Pointer<wire_cst_prepare_send_response>)>>(
|
|
||||||
'frbgen_breez_liquid_wire_send_payment');
|
|
||||||
late final _frbgen_breez_liquid_wire_send_payment =
|
|
||||||
_frbgen_breez_liquid_wire_send_paymentPtr.asFunction<
|
|
||||||
void Function(int, ffi.Pointer<wire_cst_prepare_send_response>)>();
|
|
||||||
|
|
||||||
void
|
|
||||||
frbgen_breez_liquid_rust_arc_increment_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery(
|
|
||||||
ffi.Pointer<ffi.Void> ptr,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_rust_arc_increment_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery(
|
|
||||||
ptr,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_rust_arc_increment_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecoveryPtr =
|
|
||||||
_lookup<ffi.NativeFunction<ffi.Void Function(ffi.Pointer<ffi.Void>)>>(
|
|
||||||
'frbgen_breez_liquid_rust_arc_increment_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery');
|
|
||||||
late final _frbgen_breez_liquid_rust_arc_increment_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery =
|
|
||||||
_frbgen_breez_liquid_rust_arc_increment_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecoveryPtr
|
|
||||||
.asFunction<void Function(ffi.Pointer<ffi.Void>)>();
|
|
||||||
|
|
||||||
void
|
|
||||||
frbgen_breez_liquid_rust_arc_decrement_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery(
|
|
||||||
ffi.Pointer<ffi.Void> ptr,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_rust_arc_decrement_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery(
|
|
||||||
ptr,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_rust_arc_decrement_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecoveryPtr =
|
|
||||||
_lookup<ffi.NativeFunction<ffi.Void Function(ffi.Pointer<ffi.Void>)>>(
|
|
||||||
'frbgen_breez_liquid_rust_arc_decrement_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery');
|
|
||||||
late final _frbgen_breez_liquid_rust_arc_decrement_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecovery =
|
|
||||||
_frbgen_breez_liquid_rust_arc_decrement_strong_count_RustOpaque_flutter_rust_bridgefor_generatedrust_asyncRwLockLBtcReverseRecoveryPtr
|
|
||||||
.asFunction<void Function(ffi.Pointer<ffi.Void>)>();
|
|
||||||
|
|
||||||
ffi.Pointer<wire_cst_connect_request>
|
|
||||||
frbgen_breez_liquid_cst_new_box_autoadd_connect_request() {
|
|
||||||
return _frbgen_breez_liquid_cst_new_box_autoadd_connect_request();
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_connect_requestPtr =
|
|
||||||
_lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Pointer<wire_cst_connect_request> Function()>>(
|
|
||||||
'frbgen_breez_liquid_cst_new_box_autoadd_connect_request');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_connect_request =
|
|
||||||
_frbgen_breez_liquid_cst_new_box_autoadd_connect_requestPtr
|
|
||||||
.asFunction<ffi.Pointer<wire_cst_connect_request> Function()>();
|
|
||||||
|
|
||||||
ffi.Pointer<wire_cst_get_info_request>
|
|
||||||
frbgen_breez_liquid_cst_new_box_autoadd_get_info_request() {
|
|
||||||
return _frbgen_breez_liquid_cst_new_box_autoadd_get_info_request();
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_get_info_requestPtr =
|
|
||||||
_lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Pointer<wire_cst_get_info_request> Function()>>(
|
|
||||||
'frbgen_breez_liquid_cst_new_box_autoadd_get_info_request');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_get_info_request =
|
|
||||||
_frbgen_breez_liquid_cst_new_box_autoadd_get_info_requestPtr
|
|
||||||
.asFunction<ffi.Pointer<wire_cst_get_info_request> Function()>();
|
|
||||||
|
|
||||||
ffi.Pointer<wire_cst_prepare_receive_request>
|
|
||||||
frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_request() {
|
|
||||||
return _frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_request();
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_requestPtr =
|
|
||||||
_lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Pointer<wire_cst_prepare_receive_request> Function()>>(
|
|
||||||
'frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_request');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_request =
|
|
||||||
_frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_requestPtr
|
|
||||||
.asFunction<
|
|
||||||
ffi.Pointer<wire_cst_prepare_receive_request> Function()>();
|
|
||||||
|
|
||||||
ffi.Pointer<wire_cst_prepare_receive_response>
|
|
||||||
frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_response() {
|
|
||||||
return _frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_response();
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_responsePtr =
|
|
||||||
_lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Pointer<wire_cst_prepare_receive_response> Function()>>(
|
|
||||||
'frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_response');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_response =
|
|
||||||
_frbgen_breez_liquid_cst_new_box_autoadd_prepare_receive_responsePtr
|
|
||||||
.asFunction<
|
|
||||||
ffi.Pointer<wire_cst_prepare_receive_response> Function()>();
|
|
||||||
|
|
||||||
ffi.Pointer<wire_cst_prepare_send_request>
|
|
||||||
frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_request() {
|
|
||||||
return _frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_request();
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_requestPtr =
|
|
||||||
_lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Pointer<wire_cst_prepare_send_request> Function()>>(
|
|
||||||
'frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_request');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_request =
|
|
||||||
_frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_requestPtr
|
|
||||||
.asFunction<ffi.Pointer<wire_cst_prepare_send_request> Function()>();
|
|
||||||
|
|
||||||
ffi.Pointer<wire_cst_prepare_send_response>
|
|
||||||
frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_response() {
|
|
||||||
return _frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_response();
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_responsePtr =
|
|
||||||
_lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Pointer<wire_cst_prepare_send_response> Function()>>(
|
|
||||||
'frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_response');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_response =
|
|
||||||
_frbgen_breez_liquid_cst_new_box_autoadd_prepare_send_responsePtr
|
|
||||||
.asFunction<ffi.Pointer<wire_cst_prepare_send_response> Function()>();
|
|
||||||
|
|
||||||
ffi.Pointer<wire_cst_restore_request>
|
|
||||||
frbgen_breez_liquid_cst_new_box_autoadd_restore_request() {
|
|
||||||
return _frbgen_breez_liquid_cst_new_box_autoadd_restore_request();
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_restore_requestPtr =
|
|
||||||
_lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Pointer<wire_cst_restore_request> Function()>>(
|
|
||||||
'frbgen_breez_liquid_cst_new_box_autoadd_restore_request');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_restore_request =
|
|
||||||
_frbgen_breez_liquid_cst_new_box_autoadd_restore_requestPtr
|
|
||||||
.asFunction<ffi.Pointer<wire_cst_restore_request> Function()>();
|
|
||||||
|
|
||||||
ffi.Pointer<ffi.Uint32> frbgen_breez_liquid_cst_new_box_autoadd_u_32(
|
|
||||||
int value,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_cst_new_box_autoadd_u_32(
|
|
||||||
value,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_u_32Ptr =
|
|
||||||
_lookup<ffi.NativeFunction<ffi.Pointer<ffi.Uint32> Function(ffi.Uint32)>>(
|
|
||||||
'frbgen_breez_liquid_cst_new_box_autoadd_u_32');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_u_32 =
|
|
||||||
_frbgen_breez_liquid_cst_new_box_autoadd_u_32Ptr
|
|
||||||
.asFunction<ffi.Pointer<ffi.Uint32> Function(int)>();
|
|
||||||
|
|
||||||
ffi.Pointer<ffi.Uint64> frbgen_breez_liquid_cst_new_box_autoadd_u_64(
|
|
||||||
int value,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_cst_new_box_autoadd_u_64(
|
|
||||||
value,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_u_64Ptr =
|
|
||||||
_lookup<ffi.NativeFunction<ffi.Pointer<ffi.Uint64> Function(ffi.Uint64)>>(
|
|
||||||
'frbgen_breez_liquid_cst_new_box_autoadd_u_64');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_box_autoadd_u_64 =
|
|
||||||
_frbgen_breez_liquid_cst_new_box_autoadd_u_64Ptr
|
|
||||||
.asFunction<ffi.Pointer<ffi.Uint64> Function(int)>();
|
|
||||||
|
|
||||||
ffi.Pointer<wire_cst_list_payment> frbgen_breez_liquid_cst_new_list_payment(
|
|
||||||
int len,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_cst_new_list_payment(
|
|
||||||
len,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_list_paymentPtr = _lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Pointer<wire_cst_list_payment> Function(
|
|
||||||
ffi.Int32)>>('frbgen_breez_liquid_cst_new_list_payment');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_list_payment =
|
|
||||||
_frbgen_breez_liquid_cst_new_list_paymentPtr
|
|
||||||
.asFunction<ffi.Pointer<wire_cst_list_payment> Function(int)>();
|
|
||||||
|
|
||||||
ffi.Pointer<wire_cst_list_prim_u_8_strict>
|
|
||||||
frbgen_breez_liquid_cst_new_list_prim_u_8_strict(
|
|
||||||
int len,
|
|
||||||
) {
|
|
||||||
return _frbgen_breez_liquid_cst_new_list_prim_u_8_strict(
|
|
||||||
len,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _frbgen_breez_liquid_cst_new_list_prim_u_8_strictPtr = _lookup<
|
|
||||||
ffi.NativeFunction<
|
|
||||||
ffi.Pointer<wire_cst_list_prim_u_8_strict> Function(
|
|
||||||
ffi.Int32)>>('frbgen_breez_liquid_cst_new_list_prim_u_8_strict');
|
|
||||||
late final _frbgen_breez_liquid_cst_new_list_prim_u_8_strict =
|
|
||||||
_frbgen_breez_liquid_cst_new_list_prim_u_8_strictPtr.asFunction<
|
|
||||||
ffi.Pointer<wire_cst_list_prim_u_8_strict> Function(int)>();
|
|
||||||
|
|
||||||
int dummy_method_to_enforce_bundling() {
|
|
||||||
return _dummy_method_to_enforce_bundling();
|
|
||||||
}
|
|
||||||
|
|
||||||
late final _dummy_method_to_enforce_bundlingPtr =
|
|
||||||
_lookup<ffi.NativeFunction<ffi.Int64 Function()>>(
|
|
||||||
'dummy_method_to_enforce_bundling');
|
|
||||||
late final _dummy_method_to_enforce_bundling =
|
|
||||||
_dummy_method_to_enforce_bundlingPtr.asFunction<int Function()>();
|
|
||||||
}
|
|
||||||
|
|
||||||
final class DartCObject extends ffi.Opaque {}
|
|
||||||
|
|
||||||
final class WireSyncRust2DartSse extends ffi.Struct {
|
|
||||||
external ffi.Pointer<ffi.Uint8> ptr;
|
|
||||||
|
|
||||||
@ffi.Int32()
|
|
||||||
external int len;
|
|
||||||
}
|
|
||||||
|
|
||||||
typedef DartPostCObjectFnType
|
|
||||||
= ffi.Pointer<ffi.NativeFunction<DartPostCObjectFnTypeFunction>>;
|
|
||||||
typedef DartPostCObjectFnTypeFunction = ffi.Bool Function(
|
|
||||||
DartPort port_id, ffi.Pointer<ffi.Void> message);
|
|
||||||
typedef DartDartPostCObjectFnTypeFunction = bool Function(
|
|
||||||
DartDartPort port_id, ffi.Pointer<ffi.Void> message);
|
|
||||||
typedef DartPort = ffi.Int64;
|
|
||||||
typedef DartDartPort = int;
|
|
||||||
|
|
||||||
final class _Dart_Handle extends ffi.Opaque {}
|
|
||||||
|
|
||||||
final class wire_cst_list_prim_u_8_strict extends ffi.Struct {
|
|
||||||
external ffi.Pointer<ffi.Uint8> ptr;
|
|
||||||
|
|
||||||
@ffi.Int32()
|
|
||||||
external int len;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_connect_request extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> mnemonic;
|
|
||||||
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> data_dir;
|
|
||||||
|
|
||||||
@ffi.Int32()
|
|
||||||
external int network;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_get_info_request extends ffi.Struct {
|
|
||||||
@ffi.Bool()
|
|
||||||
external bool with_scan;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_prepare_receive_request extends ffi.Struct {
|
|
||||||
@ffi.Uint64()
|
|
||||||
external int payer_amount_sat;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_prepare_send_request extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> invoice;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_prepare_receive_response extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> pair_hash;
|
|
||||||
|
|
||||||
@ffi.Uint64()
|
|
||||||
external int payer_amount_sat;
|
|
||||||
|
|
||||||
@ffi.Uint64()
|
|
||||||
external int fees_sat;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_restore_request extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> backup_path;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_prepare_send_response extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> id;
|
|
||||||
|
|
||||||
@ffi.Uint64()
|
|
||||||
external int payer_amount_sat;
|
|
||||||
|
|
||||||
@ffi.Uint64()
|
|
||||||
external int receiver_amount_sat;
|
|
||||||
|
|
||||||
@ffi.Uint64()
|
|
||||||
external int total_fees;
|
|
||||||
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> funding_address;
|
|
||||||
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> invoice;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_payment extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> id;
|
|
||||||
|
|
||||||
external ffi.Pointer<ffi.Uint32> timestamp;
|
|
||||||
|
|
||||||
@ffi.Uint64()
|
|
||||||
external int amount_sat;
|
|
||||||
|
|
||||||
external ffi.Pointer<ffi.Uint64> fees_sat;
|
|
||||||
|
|
||||||
@ffi.Int32()
|
|
||||||
external int payment_type;
|
|
||||||
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> invoice;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_list_payment extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_payment> ptr;
|
|
||||||
|
|
||||||
@ffi.Int32()
|
|
||||||
external int len;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_get_info_response extends ffi.Struct {
|
|
||||||
@ffi.Uint64()
|
|
||||||
external int balance_sat;
|
|
||||||
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> pubkey;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_PaymentError_Generic extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> err;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_PaymentError_LwkError extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> err;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_PaymentError_SendError extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> err;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_PaymentError_SignerError extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> err;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class PaymentErrorKind extends ffi.Union {
|
|
||||||
external wire_cst_PaymentError_Generic Generic;
|
|
||||||
|
|
||||||
external wire_cst_PaymentError_LwkError LwkError;
|
|
||||||
|
|
||||||
external wire_cst_PaymentError_SendError SendError;
|
|
||||||
|
|
||||||
external wire_cst_PaymentError_SignerError SignerError;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_payment_error extends ffi.Struct {
|
|
||||||
@ffi.Int32()
|
|
||||||
external int tag;
|
|
||||||
|
|
||||||
external PaymentErrorKind kind;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_receive_payment_response extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> id;
|
|
||||||
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> invoice;
|
|
||||||
}
|
|
||||||
|
|
||||||
final class wire_cst_send_payment_response extends ffi.Struct {
|
|
||||||
external ffi.Pointer<wire_cst_list_prim_u_8_strict> txid;
|
|
||||||
}
|
|
||||||
|
|
||||||
const double LIQUID_CLAIM_TX_FEERATE = 0.1;
|
|
||||||
@@ -1,19 +1,19 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
CURR_VERSION=breez_liquid-v`awk '/^version: /{print $2}' packages/breez_liquid/pubspec.yaml`
|
CURR_VERSION=breez_liquid-v`awk '/^version: /{print $2}' ../../../packages/dart/pubspec.yaml`
|
||||||
|
|
||||||
# iOS & macOS
|
# iOS & macOS
|
||||||
APPLE_HEADER="release_tag_name = '$CURR_VERSION' # generated; do not edit"
|
APPLE_HEADER="release_tag_name = '$CURR_VERSION' # generated; do not edit"
|
||||||
sed -i.bak "1 s/.*/$APPLE_HEADER/" packages/flutter_breez_liquid/ios/flutter_breez_liquid.podspec
|
sed -i.bak "1 s/.*/$APPLE_HEADER/" ../../../packages/flutter/ios/flutter_breez_liquid.podspec
|
||||||
sed -i.bak "1 s/.*/$APPLE_HEADER/" packages/flutter_breez_liquid/macos/flutter_breez_liquid.podspec
|
sed -i.bak "1 s/.*/$APPLE_HEADER/" ../../../packages/flutter/macos/flutter_breez_liquid.podspec
|
||||||
rm packages/flutter_breez_liquid/macos/*.bak packages/flutter_breez_liquid/ios/*.bak
|
rm ../../../packages/flutter/macos/*.bak ../../../packages/flutter/ios/*.bak
|
||||||
|
|
||||||
# CMake platforms (Linux, Windows, and Android)
|
# CMake platforms (Linux, Windows, and Android)
|
||||||
CMAKE_HEADER="set(LibraryVersion \"$CURR_VERSION\") # generated; do not edit"
|
CMAKE_HEADER="set(LibraryVersion \"$CURR_VERSION\") # generated; do not edit"
|
||||||
for CMAKE_PLATFORM in android linux windows
|
for CMAKE_PLATFORM in android linux windows
|
||||||
do
|
do
|
||||||
sed -i.bak "1 s/.*/$CMAKE_HEADER/" packages/flutter_breez_liquid/$CMAKE_PLATFORM/CMakeLists.txt
|
sed -i.bak "1 s/.*/$CMAKE_HEADER/" ../../../packages/flutter/$CMAKE_PLATFORM/CMakeLists.txt
|
||||||
rm packages/flutter_breez_liquid/$CMAKE_PLATFORM/*.bak
|
rm ../../../packages/flutter/$CMAKE_PLATFORM/*.bak
|
||||||
done
|
done
|
||||||
|
|
||||||
git add packages/flutter_breez_liquid/
|
git add ../../../packages/flutter/
|
||||||
@@ -61,7 +61,7 @@ class RustLib extends BaseEntrypoint<RustLibApi, RustLibApiImpl, RustLibWire> {
|
|||||||
static const kDefaultExternalLibraryLoaderConfig =
|
static const kDefaultExternalLibraryLoaderConfig =
|
||||||
ExternalLibraryLoaderConfig(
|
ExternalLibraryLoaderConfig(
|
||||||
stem: 'breez_liquid_sdk',
|
stem: 'breez_liquid_sdk',
|
||||||
ioDirectory: '../../../../core/target/release/',
|
ioDirectory: '../../lib/core/target/release/',
|
||||||
webPrefix: 'pkg/',
|
webPrefix: 'pkg/',
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
name: breez_liquid
|
name: breez_liquid
|
||||||
description: Dart bindings to the Breez Liquid SDK
|
description: Dart bindings for the Breez Liquid SDK
|
||||||
version: 0.1.0
|
version: 0.1.0
|
||||||
homepage: https://breez.technology
|
homepage: https://breez.technology
|
||||||
repository: https://github.com/breez/breez-liquid-sdk
|
repository: https://github.com/breez/breez-liquid-sdk
|
||||||
|
Before Width: | Height: | Size: 544 B After Width: | Height: | Size: 544 B |
|
Before Width: | Height: | Size: 442 B After Width: | Height: | Size: 442 B |
|
Before Width: | Height: | Size: 721 B After Width: | Height: | Size: 721 B |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 11 KiB |
|
Before Width: | Height: | Size: 564 B After Width: | Height: | Size: 564 B |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
|
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 3.7 KiB After Width: | Height: | Size: 3.7 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 3.2 KiB After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 3.5 KiB After Width: | Height: | Size: 3.5 KiB |
|
Before Width: | Height: | Size: 68 B After Width: | Height: | Size: 68 B |
|
Before Width: | Height: | Size: 68 B After Width: | Height: | Size: 68 B |
|
Before Width: | Height: | Size: 68 B After Width: | Height: | Size: 68 B |