@breeztech/breez-sdk-spark-react-native 0.3.2 → 0.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cpp/generated/breez_sdk_spark.cpp +147 -0
- package/cpp/generated/breez_sdk_spark.hpp +18 -0
- package/lib/commonjs/generated/breez_sdk_common.js +64 -274
- package/lib/commonjs/generated/breez_sdk_common.js.map +1 -1
- package/lib/commonjs/generated/breez_sdk_spark-ffi.js.map +1 -1
- package/lib/commonjs/generated/breez_sdk_spark.js +589 -24
- package/lib/commonjs/generated/breez_sdk_spark.js.map +1 -1
- package/lib/module/generated/breez_sdk_common.js +63 -273
- package/lib/module/generated/breez_sdk_common.js.map +1 -1
- package/lib/module/generated/breez_sdk_spark-ffi.js.map +1 -1
- package/lib/module/generated/breez_sdk_spark.js +588 -23
- package/lib/module/generated/breez_sdk_spark.js.map +1 -1
- package/lib/typescript/commonjs/src/generated/breez_sdk_common.d.ts +79 -183
- package/lib/typescript/commonjs/src/generated/breez_sdk_common.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/generated/breez_sdk_spark-ffi.d.ts +6 -0
- package/lib/typescript/commonjs/src/generated/breez_sdk_spark-ffi.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/generated/breez_sdk_spark.d.ts +571 -19
- package/lib/typescript/commonjs/src/generated/breez_sdk_spark.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/breez_sdk_common.d.ts +79 -183
- package/lib/typescript/module/src/generated/breez_sdk_common.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/breez_sdk_spark-ffi.d.ts +6 -0
- package/lib/typescript/module/src/generated/breez_sdk_spark-ffi.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/breez_sdk_spark.d.ts +571 -19
- package/lib/typescript/module/src/generated/breez_sdk_spark.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/generated/breez_sdk_common.ts +118 -373
- package/src/generated/breez_sdk_spark-ffi.ts +15 -0
- package/src/generated/breez_sdk_spark.ts +1076 -41
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.default = exports.UrlSuccessActionData = exports.
|
|
6
|
+
exports.default = exports.UrlSuccessActionData = exports.Symbol = exports.SuccessAction_Tags = exports.SuccessActionProcessed_Tags = exports.SuccessActionProcessed = exports.SuccessAction = exports.SparkInvoiceDetails = exports.SparkAddressDetails = exports.SilentPaymentAddressDetails = exports.ServiceConnectivityError_Tags = exports.ServiceConnectivityError = exports.RestResponse = exports.RestClientImpl = exports.Rate = exports.PaymentRequestSource = exports.MessageSuccessActionData = exports.LocalizedName = exports.LocaleOverrides = exports.LnurlWithdrawRequestDetails = exports.LnurlPayRequestDetails = exports.LnurlErrorDetails = exports.LnurlCallbackStatus_Tags = exports.LnurlCallbackStatus = exports.LnurlAuthRequestDetails = exports.LightningAddressDetails = exports.InputType_Tags = exports.InputType = exports.FiatServiceImpl = exports.FiatCurrency = exports.ExternalInputParser = exports.CurrencyInfo = exports.Bolt12OfferDetails = exports.Bolt12OfferBlindedPath = exports.Bolt12Offer = exports.Bolt12InvoiceRequestDetails = exports.Bolt12InvoiceDetails = exports.Bolt12Invoice = exports.Bolt11RouteHintHop = exports.Bolt11RouteHint = exports.Bolt11InvoiceDetails = exports.Bolt11Invoice = exports.BitcoinNetwork = exports.BitcoinAddressDetails = exports.Bip21Extra = exports.Bip21Details = exports.Amount_Tags = exports.Amount = exports.AesSuccessActionDataResult_Tags = exports.AesSuccessActionDataResult = exports.AesSuccessActionDataDecrypted = exports.AesSuccessActionData = void 0;
|
|
7
7
|
var _breez_sdk_commonFfi = _interopRequireDefault(require("./breez_sdk_common-ffi.js"));
|
|
8
8
|
var _uniffiBindgenReactNative = require("uniffi-bindgen-react-native");
|
|
9
9
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
@@ -1403,47 +1403,6 @@ const FfiConverterTypeRestResponse = (() => {
|
|
|
1403
1403
|
}
|
|
1404
1404
|
return new FFIConverter();
|
|
1405
1405
|
})();
|
|
1406
|
-
/**
|
|
1407
|
-
* Generated factory for {@link SatsPaymentDetails} record objects.
|
|
1408
|
-
*/
|
|
1409
|
-
const SatsPaymentDetails = exports.SatsPaymentDetails = (() => {
|
|
1410
|
-
const defaults = () => ({});
|
|
1411
|
-
const create = (() => {
|
|
1412
|
-
return (0, _uniffiBindgenReactNative.uniffiCreateRecord)(defaults);
|
|
1413
|
-
})();
|
|
1414
|
-
return Object.freeze({
|
|
1415
|
-
/**
|
|
1416
|
-
* Create a frozen instance of {@link SatsPaymentDetails}, with defaults specified
|
|
1417
|
-
* in Rust, in the {@link breez_sdk_common} crate.
|
|
1418
|
-
*/
|
|
1419
|
-
create,
|
|
1420
|
-
/**
|
|
1421
|
-
* Create a frozen instance of {@link SatsPaymentDetails}, with defaults specified
|
|
1422
|
-
* in Rust, in the {@link breez_sdk_common} crate.
|
|
1423
|
-
*/
|
|
1424
|
-
new: create,
|
|
1425
|
-
/**
|
|
1426
|
-
* Defaults specified in the {@link breez_sdk_common} crate.
|
|
1427
|
-
*/
|
|
1428
|
-
defaults: () => Object.freeze(defaults())
|
|
1429
|
-
});
|
|
1430
|
-
})();
|
|
1431
|
-
const FfiConverterTypeSatsPaymentDetails = (() => {
|
|
1432
|
-
class FFIConverter extends _uniffiBindgenReactNative.AbstractFfiConverterByteArray {
|
|
1433
|
-
read(from) {
|
|
1434
|
-
return {
|
|
1435
|
-
amount: FfiConverterOptionalUInt64.read(from)
|
|
1436
|
-
};
|
|
1437
|
-
}
|
|
1438
|
-
write(value, into) {
|
|
1439
|
-
FfiConverterOptionalUInt64.write(value.amount, into);
|
|
1440
|
-
}
|
|
1441
|
-
allocationSize(value) {
|
|
1442
|
-
return FfiConverterOptionalUInt64.allocationSize(value.amount);
|
|
1443
|
-
}
|
|
1444
|
-
}
|
|
1445
|
-
return new FFIConverter();
|
|
1446
|
-
})();
|
|
1447
1406
|
/**
|
|
1448
1407
|
* Generated factory for {@link SilentPaymentAddressDetails} record objects.
|
|
1449
1408
|
*/
|
|
@@ -1489,53 +1448,6 @@ const FfiConverterTypeSilentPaymentAddressDetails = (() => {
|
|
|
1489
1448
|
}
|
|
1490
1449
|
return new FFIConverter();
|
|
1491
1450
|
})();
|
|
1492
|
-
/**
|
|
1493
|
-
* Generated factory for {@link SparkAddress} record objects.
|
|
1494
|
-
*/
|
|
1495
|
-
const SparkAddress = exports.SparkAddress = (() => {
|
|
1496
|
-
const defaults = () => ({});
|
|
1497
|
-
const create = (() => {
|
|
1498
|
-
return (0, _uniffiBindgenReactNative.uniffiCreateRecord)(defaults);
|
|
1499
|
-
})();
|
|
1500
|
-
return Object.freeze({
|
|
1501
|
-
/**
|
|
1502
|
-
* Create a frozen instance of {@link SparkAddress}, with defaults specified
|
|
1503
|
-
* in Rust, in the {@link breez_sdk_common} crate.
|
|
1504
|
-
*/
|
|
1505
|
-
create,
|
|
1506
|
-
/**
|
|
1507
|
-
* Create a frozen instance of {@link SparkAddress}, with defaults specified
|
|
1508
|
-
* in Rust, in the {@link breez_sdk_common} crate.
|
|
1509
|
-
*/
|
|
1510
|
-
new: create,
|
|
1511
|
-
/**
|
|
1512
|
-
* Defaults specified in the {@link breez_sdk_common} crate.
|
|
1513
|
-
*/
|
|
1514
|
-
defaults: () => Object.freeze(defaults())
|
|
1515
|
-
});
|
|
1516
|
-
})();
|
|
1517
|
-
const FfiConverterTypeSparkAddress = (() => {
|
|
1518
|
-
class FFIConverter extends _uniffiBindgenReactNative.AbstractFfiConverterByteArray {
|
|
1519
|
-
read(from) {
|
|
1520
|
-
return {
|
|
1521
|
-
identityPublicKey: FfiConverterString.read(from),
|
|
1522
|
-
network: FfiConverterTypeBitcoinNetwork.read(from),
|
|
1523
|
-
sparkInvoiceFields: FfiConverterOptionalTypeSparkInvoiceFields.read(from),
|
|
1524
|
-
signature: FfiConverterOptionalString.read(from)
|
|
1525
|
-
};
|
|
1526
|
-
}
|
|
1527
|
-
write(value, into) {
|
|
1528
|
-
FfiConverterString.write(value.identityPublicKey, into);
|
|
1529
|
-
FfiConverterTypeBitcoinNetwork.write(value.network, into);
|
|
1530
|
-
FfiConverterOptionalTypeSparkInvoiceFields.write(value.sparkInvoiceFields, into);
|
|
1531
|
-
FfiConverterOptionalString.write(value.signature, into);
|
|
1532
|
-
}
|
|
1533
|
-
allocationSize(value) {
|
|
1534
|
-
return FfiConverterString.allocationSize(value.identityPublicKey) + FfiConverterTypeBitcoinNetwork.allocationSize(value.network) + FfiConverterOptionalTypeSparkInvoiceFields.allocationSize(value.sparkInvoiceFields) + FfiConverterOptionalString.allocationSize(value.signature);
|
|
1535
|
-
}
|
|
1536
|
-
}
|
|
1537
|
-
return new FFIConverter();
|
|
1538
|
-
})();
|
|
1539
1451
|
/**
|
|
1540
1452
|
* Generated factory for {@link SparkAddressDetails} record objects.
|
|
1541
1453
|
*/
|
|
@@ -1566,37 +1478,39 @@ const FfiConverterTypeSparkAddressDetails = (() => {
|
|
|
1566
1478
|
read(from) {
|
|
1567
1479
|
return {
|
|
1568
1480
|
address: FfiConverterString.read(from),
|
|
1569
|
-
|
|
1481
|
+
identityPublicKey: FfiConverterString.read(from),
|
|
1482
|
+
network: FfiConverterTypeBitcoinNetwork.read(from),
|
|
1570
1483
|
source: FfiConverterTypePaymentRequestSource.read(from)
|
|
1571
1484
|
};
|
|
1572
1485
|
}
|
|
1573
1486
|
write(value, into) {
|
|
1574
1487
|
FfiConverterString.write(value.address, into);
|
|
1575
|
-
|
|
1488
|
+
FfiConverterString.write(value.identityPublicKey, into);
|
|
1489
|
+
FfiConverterTypeBitcoinNetwork.write(value.network, into);
|
|
1576
1490
|
FfiConverterTypePaymentRequestSource.write(value.source, into);
|
|
1577
1491
|
}
|
|
1578
1492
|
allocationSize(value) {
|
|
1579
|
-
return FfiConverterString.allocationSize(value.address) +
|
|
1493
|
+
return FfiConverterString.allocationSize(value.address) + FfiConverterString.allocationSize(value.identityPublicKey) + FfiConverterTypeBitcoinNetwork.allocationSize(value.network) + FfiConverterTypePaymentRequestSource.allocationSize(value.source);
|
|
1580
1494
|
}
|
|
1581
1495
|
}
|
|
1582
1496
|
return new FFIConverter();
|
|
1583
1497
|
})();
|
|
1584
1498
|
/**
|
|
1585
|
-
* Generated factory for {@link
|
|
1499
|
+
* Generated factory for {@link SparkInvoiceDetails} record objects.
|
|
1586
1500
|
*/
|
|
1587
|
-
const
|
|
1501
|
+
const SparkInvoiceDetails = exports.SparkInvoiceDetails = (() => {
|
|
1588
1502
|
const defaults = () => ({});
|
|
1589
1503
|
const create = (() => {
|
|
1590
1504
|
return (0, _uniffiBindgenReactNative.uniffiCreateRecord)(defaults);
|
|
1591
1505
|
})();
|
|
1592
1506
|
return Object.freeze({
|
|
1593
1507
|
/**
|
|
1594
|
-
* Create a frozen instance of {@link
|
|
1508
|
+
* Create a frozen instance of {@link SparkInvoiceDetails}, with defaults specified
|
|
1595
1509
|
* in Rust, in the {@link breez_sdk_common} crate.
|
|
1596
1510
|
*/
|
|
1597
1511
|
create,
|
|
1598
1512
|
/**
|
|
1599
|
-
* Create a frozen instance of {@link
|
|
1513
|
+
* Create a frozen instance of {@link SparkInvoiceDetails}, with defaults specified
|
|
1600
1514
|
* in Rust, in the {@link breez_sdk_common} crate.
|
|
1601
1515
|
*/
|
|
1602
1516
|
new: create,
|
|
@@ -1606,28 +1520,32 @@ const SparkInvoiceFields = exports.SparkInvoiceFields = (() => {
|
|
|
1606
1520
|
defaults: () => Object.freeze(defaults())
|
|
1607
1521
|
});
|
|
1608
1522
|
})();
|
|
1609
|
-
const
|
|
1523
|
+
const FfiConverterTypeSparkInvoiceDetails = (() => {
|
|
1610
1524
|
class FFIConverter extends _uniffiBindgenReactNative.AbstractFfiConverterByteArray {
|
|
1611
1525
|
read(from) {
|
|
1612
1526
|
return {
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1527
|
+
invoice: FfiConverterString.read(from),
|
|
1528
|
+
identityPublicKey: FfiConverterString.read(from),
|
|
1529
|
+
network: FfiConverterTypeBitcoinNetwork.read(from),
|
|
1530
|
+
amount: FfiConverterOptionalTypecommon_u128.read(from),
|
|
1531
|
+
tokenIdentifier: FfiConverterOptionalString.read(from),
|
|
1617
1532
|
expiryTime: FfiConverterOptionalUInt64.read(from),
|
|
1618
|
-
|
|
1533
|
+
description: FfiConverterOptionalString.read(from),
|
|
1534
|
+
senderPublicKey: FfiConverterOptionalString.read(from)
|
|
1619
1535
|
};
|
|
1620
1536
|
}
|
|
1621
1537
|
write(value, into) {
|
|
1622
|
-
FfiConverterString.write(value.
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1538
|
+
FfiConverterString.write(value.invoice, into);
|
|
1539
|
+
FfiConverterString.write(value.identityPublicKey, into);
|
|
1540
|
+
FfiConverterTypeBitcoinNetwork.write(value.network, into);
|
|
1541
|
+
FfiConverterOptionalTypecommon_u128.write(value.amount, into);
|
|
1542
|
+
FfiConverterOptionalString.write(value.tokenIdentifier, into);
|
|
1626
1543
|
FfiConverterOptionalUInt64.write(value.expiryTime, into);
|
|
1627
|
-
|
|
1544
|
+
FfiConverterOptionalString.write(value.description, into);
|
|
1545
|
+
FfiConverterOptionalString.write(value.senderPublicKey, into);
|
|
1628
1546
|
}
|
|
1629
1547
|
allocationSize(value) {
|
|
1630
|
-
return FfiConverterString.allocationSize(value.
|
|
1548
|
+
return FfiConverterString.allocationSize(value.invoice) + FfiConverterString.allocationSize(value.identityPublicKey) + FfiConverterTypeBitcoinNetwork.allocationSize(value.network) + FfiConverterOptionalTypecommon_u128.allocationSize(value.amount) + FfiConverterOptionalString.allocationSize(value.tokenIdentifier) + FfiConverterOptionalUInt64.allocationSize(value.expiryTime) + FfiConverterOptionalString.allocationSize(value.description) + FfiConverterOptionalString.allocationSize(value.senderPublicKey);
|
|
1631
1549
|
}
|
|
1632
1550
|
}
|
|
1633
1551
|
return new FFIConverter();
|
|
@@ -1684,49 +1602,6 @@ const FfiConverterTypeSymbol = (() => {
|
|
|
1684
1602
|
}
|
|
1685
1603
|
return new FFIConverter();
|
|
1686
1604
|
})();
|
|
1687
|
-
/**
|
|
1688
|
-
* Generated factory for {@link TokensPaymentDetails} record objects.
|
|
1689
|
-
*/
|
|
1690
|
-
const TokensPaymentDetails = exports.TokensPaymentDetails = (() => {
|
|
1691
|
-
const defaults = () => ({});
|
|
1692
|
-
const create = (() => {
|
|
1693
|
-
return (0, _uniffiBindgenReactNative.uniffiCreateRecord)(defaults);
|
|
1694
|
-
})();
|
|
1695
|
-
return Object.freeze({
|
|
1696
|
-
/**
|
|
1697
|
-
* Create a frozen instance of {@link TokensPaymentDetails}, with defaults specified
|
|
1698
|
-
* in Rust, in the {@link breez_sdk_common} crate.
|
|
1699
|
-
*/
|
|
1700
|
-
create,
|
|
1701
|
-
/**
|
|
1702
|
-
* Create a frozen instance of {@link TokensPaymentDetails}, with defaults specified
|
|
1703
|
-
* in Rust, in the {@link breez_sdk_common} crate.
|
|
1704
|
-
*/
|
|
1705
|
-
new: create,
|
|
1706
|
-
/**
|
|
1707
|
-
* Defaults specified in the {@link breez_sdk_common} crate.
|
|
1708
|
-
*/
|
|
1709
|
-
defaults: () => Object.freeze(defaults())
|
|
1710
|
-
});
|
|
1711
|
-
})();
|
|
1712
|
-
const FfiConverterTypeTokensPaymentDetails = (() => {
|
|
1713
|
-
class FFIConverter extends _uniffiBindgenReactNative.AbstractFfiConverterByteArray {
|
|
1714
|
-
read(from) {
|
|
1715
|
-
return {
|
|
1716
|
-
tokenIdentifier: FfiConverterOptionalString.read(from),
|
|
1717
|
-
amount: FfiConverterOptionalTypecommon_u128.read(from)
|
|
1718
|
-
};
|
|
1719
|
-
}
|
|
1720
|
-
write(value, into) {
|
|
1721
|
-
FfiConverterOptionalString.write(value.tokenIdentifier, into);
|
|
1722
|
-
FfiConverterOptionalTypecommon_u128.write(value.amount, into);
|
|
1723
|
-
}
|
|
1724
|
-
allocationSize(value) {
|
|
1725
|
-
return FfiConverterOptionalString.allocationSize(value.tokenIdentifier) + FfiConverterOptionalTypecommon_u128.allocationSize(value.amount);
|
|
1726
|
-
}
|
|
1727
|
-
}
|
|
1728
|
-
return new FFIConverter();
|
|
1729
|
-
})();
|
|
1730
1605
|
/**
|
|
1731
1606
|
* Generated factory for {@link UrlSuccessActionData} record objects.
|
|
1732
1607
|
*/
|
|
@@ -2121,6 +1996,7 @@ let InputType_Tags = exports.InputType_Tags = /*#__PURE__*/function (InputType_T
|
|
|
2121
1996
|
InputType_Tags["Bolt12InvoiceRequest"] = "Bolt12InvoiceRequest";
|
|
2122
1997
|
InputType_Tags["LnurlWithdraw"] = "LnurlWithdraw";
|
|
2123
1998
|
InputType_Tags["SparkAddress"] = "SparkAddress";
|
|
1999
|
+
InputType_Tags["SparkInvoice"] = "SparkInvoice";
|
|
2124
2000
|
return InputType_Tags;
|
|
2125
2001
|
}({});
|
|
2126
2002
|
const InputType = exports.InputType = (() => {
|
|
@@ -2358,6 +2234,24 @@ const InputType = exports.InputType = (() => {
|
|
|
2358
2234
|
return obj.tag === InputType_Tags.SparkAddress;
|
|
2359
2235
|
}
|
|
2360
2236
|
}
|
|
2237
|
+
class SparkInvoice_ extends _uniffiBindgenReactNative.UniffiEnum {
|
|
2238
|
+
/**
|
|
2239
|
+
* @private
|
|
2240
|
+
* This field is private and should not be used, use `tag` instead.
|
|
2241
|
+
*/
|
|
2242
|
+
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = 'InputType';
|
|
2243
|
+
tag = InputType_Tags.SparkInvoice;
|
|
2244
|
+
constructor(v0) {
|
|
2245
|
+
super('InputType', 'SparkInvoice');
|
|
2246
|
+
this.inner = Object.freeze([v0]);
|
|
2247
|
+
}
|
|
2248
|
+
static new(v0) {
|
|
2249
|
+
return new SparkInvoice_(v0);
|
|
2250
|
+
}
|
|
2251
|
+
static instanceOf(obj) {
|
|
2252
|
+
return obj.tag === InputType_Tags.SparkInvoice;
|
|
2253
|
+
}
|
|
2254
|
+
}
|
|
2361
2255
|
function instanceOf(obj) {
|
|
2362
2256
|
return obj[_uniffiBindgenReactNative.uniffiTypeNameSymbol] === 'InputType';
|
|
2363
2257
|
}
|
|
@@ -2375,7 +2269,8 @@ const InputType = exports.InputType = (() => {
|
|
|
2375
2269
|
Bip21: Bip21_,
|
|
2376
2270
|
Bolt12InvoiceRequest: Bolt12InvoiceRequest_,
|
|
2377
2271
|
LnurlWithdraw: LnurlWithdraw_,
|
|
2378
|
-
SparkAddress: SparkAddress_
|
|
2272
|
+
SparkAddress: SparkAddress_,
|
|
2273
|
+
SparkInvoice: SparkInvoice_
|
|
2379
2274
|
});
|
|
2380
2275
|
})();
|
|
2381
2276
|
// FfiConverter for enum InputType
|
|
@@ -2410,6 +2305,8 @@ const FfiConverterTypeInputType = (() => {
|
|
|
2410
2305
|
return new InputType.LnurlWithdraw(FfiConverterTypeLnurlWithdrawRequestDetails.read(from));
|
|
2411
2306
|
case 13:
|
|
2412
2307
|
return new InputType.SparkAddress(FfiConverterTypeSparkAddressDetails.read(from));
|
|
2308
|
+
case 14:
|
|
2309
|
+
return new InputType.SparkInvoice(FfiConverterTypeSparkInvoiceDetails.read(from));
|
|
2413
2310
|
default:
|
|
2414
2311
|
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedEnumCase();
|
|
2415
2312
|
}
|
|
@@ -2507,6 +2404,13 @@ const FfiConverterTypeInputType = (() => {
|
|
|
2507
2404
|
FfiConverterTypeSparkAddressDetails.write(inner[0], into);
|
|
2508
2405
|
return;
|
|
2509
2406
|
}
|
|
2407
|
+
case InputType_Tags.SparkInvoice:
|
|
2408
|
+
{
|
|
2409
|
+
ordinalConverter.write(14, into);
|
|
2410
|
+
const inner = value.inner;
|
|
2411
|
+
FfiConverterTypeSparkInvoiceDetails.write(inner[0], into);
|
|
2412
|
+
return;
|
|
2413
|
+
}
|
|
2510
2414
|
default:
|
|
2511
2415
|
// Throwing from here means that InputType_Tags hasn't matched an ordinal.
|
|
2512
2416
|
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedEnumCase();
|
|
@@ -2605,6 +2509,13 @@ const FfiConverterTypeInputType = (() => {
|
|
|
2605
2509
|
size += FfiConverterTypeSparkAddressDetails.allocationSize(inner[0]);
|
|
2606
2510
|
return size;
|
|
2607
2511
|
}
|
|
2512
|
+
case InputType_Tags.SparkInvoice:
|
|
2513
|
+
{
|
|
2514
|
+
const inner = value.inner;
|
|
2515
|
+
let size = ordinalConverter.allocationSize(14);
|
|
2516
|
+
size += FfiConverterTypeSparkInvoiceDetails.allocationSize(inner[0]);
|
|
2517
|
+
return size;
|
|
2518
|
+
}
|
|
2608
2519
|
default:
|
|
2609
2520
|
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedEnumCase();
|
|
2610
2521
|
}
|
|
@@ -3216,117 +3127,6 @@ const FfiConverterTypeServiceConnectivityError = (() => {
|
|
|
3216
3127
|
return new FFIConverter();
|
|
3217
3128
|
})();
|
|
3218
3129
|
|
|
3219
|
-
// Enum: SparkAddressPaymentType
|
|
3220
|
-
let SparkAddressPaymentType_Tags = exports.SparkAddressPaymentType_Tags = /*#__PURE__*/function (SparkAddressPaymentType_Tags) {
|
|
3221
|
-
SparkAddressPaymentType_Tags["TokensPayment"] = "TokensPayment";
|
|
3222
|
-
SparkAddressPaymentType_Tags["SatsPayment"] = "SatsPayment";
|
|
3223
|
-
return SparkAddressPaymentType_Tags;
|
|
3224
|
-
}({});
|
|
3225
|
-
const SparkAddressPaymentType = exports.SparkAddressPaymentType = (() => {
|
|
3226
|
-
class TokensPayment_ extends _uniffiBindgenReactNative.UniffiEnum {
|
|
3227
|
-
/**
|
|
3228
|
-
* @private
|
|
3229
|
-
* This field is private and should not be used, use `tag` instead.
|
|
3230
|
-
*/
|
|
3231
|
-
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = 'SparkAddressPaymentType';
|
|
3232
|
-
tag = SparkAddressPaymentType_Tags.TokensPayment;
|
|
3233
|
-
constructor(v0) {
|
|
3234
|
-
super('SparkAddressPaymentType', 'TokensPayment');
|
|
3235
|
-
this.inner = Object.freeze([v0]);
|
|
3236
|
-
}
|
|
3237
|
-
static new(v0) {
|
|
3238
|
-
return new TokensPayment_(v0);
|
|
3239
|
-
}
|
|
3240
|
-
static instanceOf(obj) {
|
|
3241
|
-
return obj.tag === SparkAddressPaymentType_Tags.TokensPayment;
|
|
3242
|
-
}
|
|
3243
|
-
}
|
|
3244
|
-
class SatsPayment_ extends _uniffiBindgenReactNative.UniffiEnum {
|
|
3245
|
-
/**
|
|
3246
|
-
* @private
|
|
3247
|
-
* This field is private and should not be used, use `tag` instead.
|
|
3248
|
-
*/
|
|
3249
|
-
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = 'SparkAddressPaymentType';
|
|
3250
|
-
tag = SparkAddressPaymentType_Tags.SatsPayment;
|
|
3251
|
-
constructor(v0) {
|
|
3252
|
-
super('SparkAddressPaymentType', 'SatsPayment');
|
|
3253
|
-
this.inner = Object.freeze([v0]);
|
|
3254
|
-
}
|
|
3255
|
-
static new(v0) {
|
|
3256
|
-
return new SatsPayment_(v0);
|
|
3257
|
-
}
|
|
3258
|
-
static instanceOf(obj) {
|
|
3259
|
-
return obj.tag === SparkAddressPaymentType_Tags.SatsPayment;
|
|
3260
|
-
}
|
|
3261
|
-
}
|
|
3262
|
-
function instanceOf(obj) {
|
|
3263
|
-
return obj[_uniffiBindgenReactNative.uniffiTypeNameSymbol] === 'SparkAddressPaymentType';
|
|
3264
|
-
}
|
|
3265
|
-
return Object.freeze({
|
|
3266
|
-
instanceOf,
|
|
3267
|
-
TokensPayment: TokensPayment_,
|
|
3268
|
-
SatsPayment: SatsPayment_
|
|
3269
|
-
});
|
|
3270
|
-
})();
|
|
3271
|
-
// FfiConverter for enum SparkAddressPaymentType
|
|
3272
|
-
const FfiConverterTypeSparkAddressPaymentType = (() => {
|
|
3273
|
-
const ordinalConverter = _uniffiBindgenReactNative.FfiConverterInt32;
|
|
3274
|
-
class FFIConverter extends _uniffiBindgenReactNative.AbstractFfiConverterByteArray {
|
|
3275
|
-
read(from) {
|
|
3276
|
-
switch (ordinalConverter.read(from)) {
|
|
3277
|
-
case 1:
|
|
3278
|
-
return new SparkAddressPaymentType.TokensPayment(FfiConverterTypeTokensPaymentDetails.read(from));
|
|
3279
|
-
case 2:
|
|
3280
|
-
return new SparkAddressPaymentType.SatsPayment(FfiConverterTypeSatsPaymentDetails.read(from));
|
|
3281
|
-
default:
|
|
3282
|
-
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedEnumCase();
|
|
3283
|
-
}
|
|
3284
|
-
}
|
|
3285
|
-
write(value, into) {
|
|
3286
|
-
switch (value.tag) {
|
|
3287
|
-
case SparkAddressPaymentType_Tags.TokensPayment:
|
|
3288
|
-
{
|
|
3289
|
-
ordinalConverter.write(1, into);
|
|
3290
|
-
const inner = value.inner;
|
|
3291
|
-
FfiConverterTypeTokensPaymentDetails.write(inner[0], into);
|
|
3292
|
-
return;
|
|
3293
|
-
}
|
|
3294
|
-
case SparkAddressPaymentType_Tags.SatsPayment:
|
|
3295
|
-
{
|
|
3296
|
-
ordinalConverter.write(2, into);
|
|
3297
|
-
const inner = value.inner;
|
|
3298
|
-
FfiConverterTypeSatsPaymentDetails.write(inner[0], into);
|
|
3299
|
-
return;
|
|
3300
|
-
}
|
|
3301
|
-
default:
|
|
3302
|
-
// Throwing from here means that SparkAddressPaymentType_Tags hasn't matched an ordinal.
|
|
3303
|
-
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedEnumCase();
|
|
3304
|
-
}
|
|
3305
|
-
}
|
|
3306
|
-
allocationSize(value) {
|
|
3307
|
-
switch (value.tag) {
|
|
3308
|
-
case SparkAddressPaymentType_Tags.TokensPayment:
|
|
3309
|
-
{
|
|
3310
|
-
const inner = value.inner;
|
|
3311
|
-
let size = ordinalConverter.allocationSize(1);
|
|
3312
|
-
size += FfiConverterTypeTokensPaymentDetails.allocationSize(inner[0]);
|
|
3313
|
-
return size;
|
|
3314
|
-
}
|
|
3315
|
-
case SparkAddressPaymentType_Tags.SatsPayment:
|
|
3316
|
-
{
|
|
3317
|
-
const inner = value.inner;
|
|
3318
|
-
let size = ordinalConverter.allocationSize(2);
|
|
3319
|
-
size += FfiConverterTypeSatsPaymentDetails.allocationSize(inner[0]);
|
|
3320
|
-
return size;
|
|
3321
|
-
}
|
|
3322
|
-
default:
|
|
3323
|
-
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedEnumCase();
|
|
3324
|
-
}
|
|
3325
|
-
}
|
|
3326
|
-
}
|
|
3327
|
-
return new FFIConverter();
|
|
3328
|
-
})();
|
|
3329
|
-
|
|
3330
3130
|
// Enum: SuccessAction
|
|
3331
3131
|
let SuccessAction_Tags = exports.SuccessAction_Tags = /*#__PURE__*/function (SuccessAction_Tags) {
|
|
3332
3132
|
SuccessAction_Tags["Aes"] = "Aes";
|
|
@@ -4071,9 +3871,6 @@ const uniffiCallbackInterfaceRestClient = {
|
|
|
4071
3871
|
// FfiConverter for boolean | undefined
|
|
4072
3872
|
const FfiConverterOptionalBool = new _uniffiBindgenReactNative.FfiConverterOptional(_uniffiBindgenReactNative.FfiConverterBool);
|
|
4073
3873
|
|
|
4074
|
-
// FfiConverter for SparkInvoiceFields | undefined
|
|
4075
|
-
const FfiConverterOptionalTypeSparkInvoiceFields = new _uniffiBindgenReactNative.FfiConverterOptional(FfiConverterTypeSparkInvoiceFields);
|
|
4076
|
-
|
|
4077
3874
|
// FfiConverter for Symbol | undefined
|
|
4078
3875
|
const FfiConverterOptionalTypeSymbol = new _uniffiBindgenReactNative.FfiConverterOptional(FfiConverterTypeSymbol);
|
|
4079
3876
|
|
|
@@ -4119,9 +3916,6 @@ const FfiConverterOptionalTypecommon_u128 = new _uniffiBindgenReactNative.FfiCon
|
|
|
4119
3916
|
// FfiConverter for Amount | undefined
|
|
4120
3917
|
const FfiConverterOptionalTypeAmount = new _uniffiBindgenReactNative.FfiConverterOptional(FfiConverterTypeAmount);
|
|
4121
3918
|
|
|
4122
|
-
// FfiConverter for SparkAddressPaymentType | undefined
|
|
4123
|
-
const FfiConverterOptionalTypeSparkAddressPaymentType = new _uniffiBindgenReactNative.FfiConverterOptional(FfiConverterTypeSparkAddressPaymentType);
|
|
4124
|
-
|
|
4125
3919
|
// FfiConverter for Map<string, string> | undefined
|
|
4126
3920
|
const FfiConverterOptionalMapStringString = new _uniffiBindgenReactNative.FfiConverterOptional(FfiConverterMapStringString);
|
|
4127
3921
|
|
|
@@ -4203,16 +3997,12 @@ var _default = exports.default = Object.freeze({
|
|
|
4203
3997
|
FfiConverterTypeRate,
|
|
4204
3998
|
FfiConverterTypeRestClient,
|
|
4205
3999
|
FfiConverterTypeRestResponse,
|
|
4206
|
-
FfiConverterTypeSatsPaymentDetails,
|
|
4207
4000
|
FfiConverterTypeSilentPaymentAddressDetails,
|
|
4208
|
-
FfiConverterTypeSparkAddress,
|
|
4209
4001
|
FfiConverterTypeSparkAddressDetails,
|
|
4210
|
-
|
|
4211
|
-
FfiConverterTypeSparkInvoiceFields,
|
|
4002
|
+
FfiConverterTypeSparkInvoiceDetails,
|
|
4212
4003
|
FfiConverterTypeSuccessAction,
|
|
4213
4004
|
FfiConverterTypeSuccessActionProcessed,
|
|
4214
4005
|
FfiConverterTypeSymbol,
|
|
4215
|
-
FfiConverterTypeTokensPaymentDetails,
|
|
4216
4006
|
FfiConverterTypeUrlSuccessActionData,
|
|
4217
4007
|
FfiConverterTypecommon_u128
|
|
4218
4008
|
}
|