react-native-candle 0.1.51 → 19.0.6-beta
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/README.md +23 -178
- package/ReactNativeCandle.podspec +2 -2
- package/android/CMakeLists.txt +11 -0
- package/android/build.gradle +136 -0
- package/android/gradle.properties +2 -0
- package/android/src/main/AndroidManifest.xml +1 -0
- package/android/src/main/cpp/cpp-adapter.cpp +9 -0
- package/android/src/main/java/com/margelo/nitro/rncandle/BridgeTypes.kt +814 -0
- package/android/src/main/java/com/margelo/nitro/rncandle/HybridRNCandle.kt +251 -0
- package/android/src/main/java/com/margelo/nitro/rncandle/ReactNativeCandlePackage.kt +22 -0
- package/ios/Sources/RNCandle.swift +18 -4
- package/ios/Sources/Types.swift +280 -175
- package/lib/typescript/commonjs/src/context.d.ts +4 -7
- package/lib/typescript/commonjs/src/index.d.ts +4 -4
- package/lib/typescript/commonjs/src/provider.d.ts +1 -1
- package/lib/typescript/commonjs/src/specs/RNCandle.nitro.d.ts +134 -72
- package/lib/typescript/commonjs/src/types.d.ts +70 -68
- package/lib/typescript/module/src/context.d.ts +4 -7
- package/lib/typescript/module/src/index.d.ts +4 -4
- package/lib/typescript/module/src/provider.d.ts +1 -1
- package/lib/typescript/module/src/specs/RNCandle.nitro.d.ts +134 -72
- package/lib/typescript/module/src/types.d.ts +70 -68
- package/nitrogen/generated/android/ReactNativeCandle+autolinking.cmake +81 -0
- package/nitrogen/generated/android/ReactNativeCandle+autolinking.gradle +27 -0
- package/nitrogen/generated/android/ReactNativeCandleOnLoad.cpp +58 -0
- package/nitrogen/generated/android/ReactNativeCandleOnLoad.hpp +34 -0
- package/nitrogen/generated/android/c++/JACHAccountKind.hpp +58 -0
- package/nitrogen/generated/android/c++/JACHDetails.hpp +67 -0
- package/nitrogen/generated/android/c++/JActiveLinkedAccountDetails.hpp +74 -0
- package/nitrogen/generated/android/c++/JAddress.hpp +57 -0
- package/nitrogen/generated/android/c++/JAssetAccount.hpp +90 -0
- package/nitrogen/generated/android/c++/JAssetAccountKind.hpp +64 -0
- package/nitrogen/generated/android/c++/JAssetAccountRef.hpp +67 -0
- package/nitrogen/generated/android/c++/JAssetAccountsQuery.hpp +64 -0
- package/nitrogen/generated/android/c++/JAssetAccountsResponse.hpp +125 -0
- package/nitrogen/generated/android/c++/JCoordinates.hpp +61 -0
- package/nitrogen/generated/android/c++/JCounterparty.hpp +76 -0
- package/nitrogen/generated/android/c++/JCounterpartyKind.hpp +61 -0
- package/nitrogen/generated/android/c++/JCounterpartyQuoteRequest.hpp +74 -0
- package/nitrogen/generated/android/c++/JCryptoAccount.hpp +81 -0
- package/nitrogen/generated/android/c++/JCryptoAsset.hpp +99 -0
- package/nitrogen/generated/android/c++/JCryptoAssetQuoteRequest.hpp +74 -0
- package/nitrogen/generated/android/c++/JCryptoAssetRef.hpp +65 -0
- package/nitrogen/generated/android/c++/JEventAsset.hpp +107 -0
- package/nitrogen/generated/android/c++/JEventAssetQuoteRequest.hpp +70 -0
- package/nitrogen/generated/android/c++/JEventAssetRef.hpp +65 -0
- package/nitrogen/generated/android/c++/JFiatAccount.hpp +104 -0
- package/nitrogen/generated/android/c++/JFiatAsset.hpp +84 -0
- package/nitrogen/generated/android/c++/JFiatAssetQuoteRequest.hpp +70 -0
- package/nitrogen/generated/android/c++/JFiatAssetRef.hpp +66 -0
- package/nitrogen/generated/android/c++/JFinancialAccountKind.hpp +67 -0
- package/nitrogen/generated/android/c++/JFunc_void_LinkedAccount.hpp +89 -0
- package/nitrogen/generated/android/c++/JFunc_void_TradeExecutionResult.hpp +115 -0
- package/nitrogen/generated/android/c++/JHybridRNCandleSpec.cpp +559 -0
- package/nitrogen/generated/android/c++/JHybridRNCandleSpec.hpp +77 -0
- package/nitrogen/generated/android/c++/JInactiveLinkedAccountDetails.hpp +57 -0
- package/nitrogen/generated/android/c++/JLinkedAccount.hpp +80 -0
- package/nitrogen/generated/android/c++/JLinkedAccountDetails.hpp +72 -0
- package/nitrogen/generated/android/c++/JLinkedAccountRef.hpp +57 -0
- package/nitrogen/generated/android/c++/JLinkedAccountState.hpp +61 -0
- package/nitrogen/generated/android/c++/JLinkedAccountStatusRef.hpp +73 -0
- package/nitrogen/generated/android/c++/JMerchantCounterparty.hpp +72 -0
- package/nitrogen/generated/android/c++/JMerchantCounterpartyQuoteRequest.hpp +68 -0
- package/nitrogen/generated/android/c++/JMerchantLocation.hpp +65 -0
- package/nitrogen/generated/android/c++/JNothingAsset.hpp +57 -0
- package/nitrogen/generated/android/c++/JNothingAssetQuoteRequest.hpp +57 -0
- package/nitrogen/generated/android/c++/JNothingAssetRef.hpp +57 -0
- package/nitrogen/generated/android/c++/JOtherAsset.hpp +57 -0
- package/nitrogen/generated/android/c++/JOtherAssetQuoteRequest.hpp +57 -0
- package/nitrogen/generated/android/c++/JOtherAssetRef.hpp +57 -0
- package/nitrogen/generated/android/c++/JPresentationBackground.hpp +58 -0
- package/nitrogen/generated/android/c++/JPresentationStyle.hpp +58 -0
- package/nitrogen/generated/android/c++/JService.hpp +292 -0
- package/nitrogen/generated/android/c++/JServiceCounterparty.hpp +63 -0
- package/nitrogen/generated/android/c++/JServiceCounterpartyQuoteRequest.hpp +57 -0
- package/nitrogen/generated/android/c++/JStockAccount.hpp +81 -0
- package/nitrogen/generated/android/c++/JStockAsset.hpp +99 -0
- package/nitrogen/generated/android/c++/JStockAssetQuoteRequest.hpp +74 -0
- package/nitrogen/generated/android/c++/JStockAssetRef.hpp +65 -0
- package/nitrogen/generated/android/c++/JTrade.hpp +108 -0
- package/nitrogen/generated/android/c++/JTradeAsset.hpp +102 -0
- package/nitrogen/generated/android/c++/JTradeAssetKind.hpp +73 -0
- package/nitrogen/generated/android/c++/JTradeAssetQuoteRequest.hpp +100 -0
- package/nitrogen/generated/android/c++/JTradeAssetRef.hpp +96 -0
- package/nitrogen/generated/android/c++/JTradeExecutionResult.hpp +98 -0
- package/nitrogen/generated/android/c++/JTradeQuote.hpp +106 -0
- package/nitrogen/generated/android/c++/JTradeQuotesRequest.hpp +100 -0
- package/nitrogen/generated/android/c++/JTradeQuotesResponse.hpp +137 -0
- package/nitrogen/generated/android/c++/JTradeRef.hpp +78 -0
- package/nitrogen/generated/android/c++/JTradeState.hpp +61 -0
- package/nitrogen/generated/android/c++/JTradesQuery.hpp +78 -0
- package/nitrogen/generated/android/c++/JTradesResponse.hpp +139 -0
- package/nitrogen/generated/android/c++/JTransportAccount.hpp +81 -0
- package/nitrogen/generated/android/c++/JTransportAccountKind.hpp +61 -0
- package/nitrogen/generated/android/c++/JTransportAsset.hpp +123 -0
- package/nitrogen/generated/android/c++/JTransportAssetQuoteRequest.hpp +90 -0
- package/nitrogen/generated/android/c++/JTransportAssetRef.hpp +65 -0
- package/nitrogen/generated/android/c++/JUnavailableLinkedAccountDetails.hpp +57 -0
- package/nitrogen/generated/android/c++/JUserCounterparty.hpp +69 -0
- package/nitrogen/generated/android/c++/JUserCounterpartyQuoteRequest.hpp +66 -0
- package/nitrogen/generated/android/c++/JWireDetails.hpp +61 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/ACHAccountKind.kt +23 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/ACHDetails.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/ActiveLinkedAccountDetails.kt +50 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/Address.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/AssetAccount.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/AssetAccountKind.kt +25 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/AssetAccountRef.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/AssetAccountsQuery.kt +41 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/AssetAccountsResponse.kt +41 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/Coordinates.kt +41 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/Counterparty.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/CounterpartyKind.kt +24 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/CounterpartyQuoteRequest.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/CryptoAccount.kt +53 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/CryptoAsset.kt +68 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/CryptoAssetQuoteRequest.kt +50 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/CryptoAssetRef.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/EventAsset.kt +71 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/EventAssetQuoteRequest.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/EventAssetRef.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/FiatAccount.kt +65 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/FiatAsset.kt +56 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/FiatAssetQuoteRequest.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/FiatAssetRef.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/FinancialAccountKind.kt +26 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/Func_void_LinkedAccount.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/Func_void_TradeExecutionResult.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/HybridRNCandleSpec.kt +121 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/InactiveLinkedAccountDetails.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/LinkedAccount.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/LinkedAccountDetails.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/LinkedAccountRef.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/LinkedAccountState.kt +24 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/LinkedAccountStatusRef.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/MerchantCounterparty.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/MerchantCounterpartyQuoteRequest.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/MerchantLocation.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/NothingAsset.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/NothingAssetQuoteRequest.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/NothingAssetRef.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/OtherAsset.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/OtherAssetQuoteRequest.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/OtherAssetRef.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/PresentationBackground.kt +23 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/PresentationStyle.kt +23 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/ReactNativeCandleOnLoad.kt +35 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/Service.kt +101 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/ServiceCounterparty.kt +41 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/ServiceCounterpartyQuoteRequest.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/StockAccount.kt +53 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/StockAsset.kt +68 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/StockAssetQuoteRequest.kt +50 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/StockAssetRef.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/Trade.kt +50 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeAsset.kt +56 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeAssetKind.kt +28 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeAssetQuoteRequest.kt +56 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeAssetRef.kt +56 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeExecutionResult.kt +41 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeQuote.kt +50 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeQuotesRequest.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeQuotesResponse.kt +41 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeRef.kt +41 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradeState.kt +24 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradesQuery.kt +50 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TradesResponse.kt +41 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TransportAccount.kt +53 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TransportAccountKind.kt +24 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TransportAsset.kt +83 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TransportAssetQuoteRequest.kt +59 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/TransportAssetRef.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/UnavailableLinkedAccountDetails.kt +38 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/UserCounterparty.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/UserCounterpartyQuoteRequest.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rncandle/WireDetails.kt +41 -0
- package/nitrogen/generated/ios/ReactNativeCandle+autolinking.rb +2 -2
- package/nitrogen/generated/ios/ReactNativeCandle-Swift-Cxx-Bridge.cpp +14 -13
- package/nitrogen/generated/ios/ReactNativeCandle-Swift-Cxx-Bridge.hpp +222 -99
- package/nitrogen/generated/ios/ReactNativeCandle-Swift-Cxx-Umbrella.hpp +37 -19
- package/nitrogen/generated/ios/ReactNativeCandleAutolinking.mm +1 -1
- package/nitrogen/generated/ios/ReactNativeCandleAutolinking.swift +9 -8
- package/nitrogen/generated/ios/c++/HybridRNCandleSpecSwift.cpp +1 -1
- package/nitrogen/generated/ios/c++/HybridRNCandleSpecSwift.hpp +63 -28
- package/nitrogen/generated/ios/swift/ACHAccountKind.swift +17 -15
- package/nitrogen/generated/ios/swift/ACHDetails.swift +17 -33
- package/nitrogen/generated/ios/swift/ActiveLinkedAccountDetails.swift +65 -118
- package/nitrogen/generated/ios/swift/Address.swift +9 -13
- package/nitrogen/generated/ios/swift/AssetAccount.swift +47 -96
- package/nitrogen/generated/ios/swift/AssetAccountKind.swift +25 -23
- package/nitrogen/generated/ios/swift/AssetAccountRef.swift +17 -33
- package/nitrogen/generated/ios/swift/AssetAccountsQuery.swift +33 -57
- package/nitrogen/generated/ios/swift/AssetAccountsResponse.swift +26 -50
- package/nitrogen/generated/ios/swift/Coordinates.swift +13 -23
- package/nitrogen/generated/ios/swift/Counterparty.swift +36 -99
- package/nitrogen/generated/ios/swift/CounterpartyKind.swift +21 -19
- package/nitrogen/generated/ios/swift/CounterpartyQuoteRequest.swift +36 -110
- package/nitrogen/generated/ios/swift/CryptoAccount.swift +54 -0
- package/nitrogen/generated/ios/swift/CryptoAsset.swift +79 -0
- package/nitrogen/generated/ios/swift/CryptoAssetQuoteRequest.swift +101 -0
- package/nitrogen/generated/ios/swift/CryptoAssetRef.swift +39 -0
- package/nitrogen/generated/ios/swift/EventAsset.swift +84 -0
- package/nitrogen/generated/ios/swift/EventAssetQuoteRequest.swift +83 -0
- package/nitrogen/generated/ios/swift/EventAssetRef.swift +39 -0
- package/nitrogen/generated/ios/swift/FiatAccount.swift +71 -163
- package/nitrogen/generated/ios/swift/FiatAsset.swift +47 -99
- package/nitrogen/generated/ios/swift/FiatAssetQuoteRequest.swift +61 -99
- package/nitrogen/generated/ios/swift/FiatAssetRef.swift +31 -55
- package/nitrogen/generated/ios/swift/FinancialAccountKind.swift +52 -0
- package/nitrogen/generated/ios/swift/Func_void.swift +6 -4
- package/nitrogen/generated/ios/swift/Func_void_AssetAccount.swift +6 -4
- package/nitrogen/generated/ios/swift/Func_void_AssetAccountsResponse.swift +7 -7
- package/nitrogen/generated/ios/swift/Func_void_LinkedAccount.swift +6 -4
- package/nitrogen/generated/ios/swift/Func_void_Trade.swift +6 -4
- package/nitrogen/generated/ios/swift/Func_void_TradeExecutionResult.swift +7 -7
- package/nitrogen/generated/ios/swift/Func_void_TradeQuotesResponse.swift +7 -6
- package/nitrogen/generated/ios/swift/Func_void_TradesResponse.swift +6 -4
- package/nitrogen/generated/ios/swift/Func_void_std__exception_ptr.swift +7 -6
- package/nitrogen/generated/ios/swift/Func_void_std__vector_LinkedAccount_.swift +7 -7
- package/nitrogen/generated/ios/swift/HybridRNCandleSpec.swift +29 -27
- package/nitrogen/generated/ios/swift/HybridRNCandleSpec_cxx.swift +117 -124
- package/nitrogen/generated/ios/swift/InactiveLinkedAccountDetails.swift +9 -13
- package/nitrogen/generated/ios/swift/LinkedAccount.swift +21 -45
- package/nitrogen/generated/ios/swift/LinkedAccountDetails.swift +36 -110
- package/nitrogen/generated/ios/swift/LinkedAccountRef.swift +9 -13
- package/nitrogen/generated/ios/swift/LinkedAccountState.swift +21 -19
- package/nitrogen/generated/ios/swift/LinkedAccountStatusRef.swift +21 -45
- package/nitrogen/generated/ios/swift/MerchantCounterparty.swift +28 -65
- package/nitrogen/generated/ios/swift/MerchantCounterpartyQuoteRequest.swift +39 -47
- package/nitrogen/generated/ios/swift/MerchantLocation.swift +17 -33
- package/nitrogen/generated/ios/swift/NothingAsset.swift +9 -13
- package/nitrogen/generated/ios/swift/NothingAssetQuoteRequest.swift +9 -13
- package/nitrogen/generated/ios/swift/NothingAssetRef.swift +9 -13
- package/nitrogen/generated/ios/swift/OtherAsset.swift +9 -13
- package/nitrogen/generated/ios/swift/OtherAssetQuoteRequest.swift +9 -13
- package/nitrogen/generated/ios/swift/OtherAssetRef.swift +9 -13
- package/nitrogen/generated/ios/swift/PresentationBackground.swift +17 -15
- package/nitrogen/generated/ios/swift/PresentationStyle.swift +17 -15
- package/nitrogen/generated/ios/swift/Service.swift +329 -327
- package/nitrogen/generated/ios/swift/ServiceCounterparty.swift +13 -23
- package/nitrogen/generated/ios/swift/ServiceCounterpartyQuoteRequest.swift +10 -15
- package/nitrogen/generated/ios/swift/StockAccount.swift +54 -0
- package/nitrogen/generated/ios/swift/StockAsset.swift +79 -0
- package/nitrogen/generated/ios/swift/StockAssetQuoteRequest.swift +101 -0
- package/nitrogen/generated/ios/swift/StockAssetRef.swift +39 -0
- package/nitrogen/generated/ios/swift/Trade.swift +25 -56
- package/nitrogen/generated/ios/swift/TradeAsset.swift +78 -157
- package/nitrogen/generated/ios/swift/TradeAssetKind.swift +37 -31
- package/nitrogen/generated/ios/swift/TradeAssetQuoteRequest.swift +78 -169
- package/nitrogen/generated/ios/swift/TradeAssetRef.swift +78 -159
- package/nitrogen/generated/ios/swift/TradeExecutionResult.swift +33 -64
- package/nitrogen/generated/ios/swift/TradeQuote.swift +25 -56
- package/nitrogen/generated/ios/swift/TradeQuotesRequest.swift +41 -87
- package/nitrogen/generated/ios/swift/TradeQuotesResponse.swift +26 -50
- package/nitrogen/generated/ios/swift/TradeRef.swift +13 -23
- package/nitrogen/generated/ios/swift/TradeState.swift +21 -19
- package/nitrogen/generated/ios/swift/TradesQuery.swift +70 -136
- package/nitrogen/generated/ios/swift/TradesResponse.swift +26 -50
- package/nitrogen/generated/ios/swift/TransportAccount.swift +30 -69
- package/nitrogen/generated/ios/swift/TransportAccountKind.swift +21 -19
- package/nitrogen/generated/ios/swift/TransportAsset.swift +87 -192
- package/nitrogen/generated/ios/swift/TransportAssetQuoteRequest.swift +101 -222
- package/nitrogen/generated/ios/swift/TransportAssetRef.swift +17 -33
- package/nitrogen/generated/ios/swift/UnavailableLinkedAccountDetails.swift +10 -15
- package/nitrogen/generated/ios/swift/UserCounterparty.swift +21 -43
- package/nitrogen/generated/ios/swift/UserCounterpartyQuoteRequest.swift +44 -75
- package/nitrogen/generated/ios/swift/WireDetails.swift +13 -23
- package/nitrogen/generated/shared/c++/ACHAccountKind.hpp +1 -1
- package/nitrogen/generated/shared/c++/ACHDetails.hpp +27 -11
- package/nitrogen/generated/shared/c++/ActiveLinkedAccountDetails.hpp +33 -17
- package/nitrogen/generated/shared/c++/Address.hpp +21 -5
- package/nitrogen/generated/shared/c++/AssetAccount.hpp +39 -16
- package/nitrogen/generated/shared/c++/AssetAccountKind.hpp +7 -7
- package/nitrogen/generated/shared/c++/AssetAccountRef.hpp +27 -11
- package/nitrogen/generated/shared/c++/AssetAccountsQuery.hpp +24 -8
- package/nitrogen/generated/shared/c++/AssetAccountsResponse.hpp +24 -8
- package/nitrogen/generated/shared/c++/Coordinates.hpp +24 -8
- package/nitrogen/generated/shared/c++/Counterparty.hpp +27 -11
- package/nitrogen/generated/shared/c++/CounterpartyKind.hpp +1 -1
- package/nitrogen/generated/shared/c++/CounterpartyQuoteRequest.hpp +27 -11
- package/nitrogen/generated/shared/c++/CryptoAccount.hpp +108 -0
- package/nitrogen/generated/shared/c++/CryptoAsset.hpp +125 -0
- package/nitrogen/generated/shared/c++/CryptoAssetQuoteRequest.hpp +100 -0
- package/nitrogen/generated/shared/c++/CryptoAssetRef.hpp +91 -0
- package/nitrogen/generated/shared/c++/EventAsset.hpp +135 -0
- package/nitrogen/generated/shared/c++/EventAssetQuoteRequest.hpp +96 -0
- package/nitrogen/generated/shared/c++/EventAssetRef.hpp +91 -0
- package/nitrogen/generated/shared/c++/FiatAccount.hpp +53 -37
- package/nitrogen/generated/shared/c++/FiatAsset.hpp +39 -23
- package/nitrogen/generated/shared/c++/FiatAssetQuoteRequest.hpp +30 -14
- package/nitrogen/generated/shared/c++/FiatAssetRef.hpp +27 -11
- package/nitrogen/generated/shared/c++/{FiatMarketAccountKind.hpp → FinancialAccountKind.hpp} +20 -20
- package/nitrogen/generated/shared/c++/HybridRNCandleSpec.cpp +2 -1
- package/nitrogen/generated/shared/c++/HybridRNCandleSpec.hpp +2 -1
- package/nitrogen/generated/shared/c++/InactiveLinkedAccountDetails.hpp +21 -5
- package/nitrogen/generated/shared/c++/LinkedAccount.hpp +30 -14
- package/nitrogen/generated/shared/c++/LinkedAccountDetails.hpp +27 -11
- package/nitrogen/generated/shared/c++/LinkedAccountRef.hpp +21 -5
- package/nitrogen/generated/shared/c++/LinkedAccountState.hpp +1 -1
- package/nitrogen/generated/shared/c++/LinkedAccountStatusRef.hpp +30 -14
- package/nitrogen/generated/shared/c++/MerchantCounterparty.hpp +30 -14
- package/nitrogen/generated/shared/c++/MerchantCounterpartyQuoteRequest.hpp +32 -10
- package/nitrogen/generated/shared/c++/MerchantLocation.hpp +27 -11
- package/nitrogen/generated/shared/c++/NothingAsset.hpp +21 -5
- package/nitrogen/generated/shared/c++/NothingAssetQuoteRequest.hpp +21 -5
- package/nitrogen/generated/shared/c++/NothingAssetRef.hpp +21 -5
- package/nitrogen/generated/shared/c++/OtherAsset.hpp +21 -5
- package/nitrogen/generated/shared/c++/OtherAssetQuoteRequest.hpp +21 -5
- package/nitrogen/generated/shared/c++/OtherAssetRef.hpp +21 -5
- package/nitrogen/generated/shared/c++/PresentationBackground.hpp +1 -1
- package/nitrogen/generated/shared/c++/PresentationStyle.hpp +1 -1
- package/nitrogen/generated/shared/c++/Service.hpp +1 -1
- package/nitrogen/generated/shared/c++/ServiceCounterparty.hpp +24 -8
- package/nitrogen/generated/shared/c++/ServiceCounterpartyQuoteRequest.hpp +21 -5
- package/nitrogen/generated/shared/c++/StockAccount.hpp +108 -0
- package/nitrogen/generated/shared/c++/StockAsset.hpp +125 -0
- package/nitrogen/generated/shared/c++/StockAssetQuoteRequest.hpp +100 -0
- package/nitrogen/generated/shared/c++/StockAssetRef.hpp +91 -0
- package/nitrogen/generated/shared/c++/Trade.hpp +33 -17
- package/nitrogen/generated/shared/c++/TradeAsset.hpp +52 -22
- package/nitrogen/generated/shared/c++/TradeAssetKind.hpp +13 -9
- package/nitrogen/generated/shared/c++/TradeAssetQuoteRequest.hpp +52 -22
- package/nitrogen/generated/shared/c++/TradeAssetRef.hpp +52 -22
- package/nitrogen/generated/shared/c++/TradeExecutionResult.hpp +24 -8
- package/nitrogen/generated/shared/c++/TradeQuote.hpp +33 -17
- package/nitrogen/generated/shared/c++/TradeQuotesRequest.hpp +30 -14
- package/nitrogen/generated/shared/c++/TradeQuotesResponse.hpp +24 -8
- package/nitrogen/generated/shared/c++/TradeRef.hpp +24 -8
- package/nitrogen/generated/shared/c++/TradeState.hpp +1 -1
- package/nitrogen/generated/shared/c++/TradesQuery.hpp +33 -17
- package/nitrogen/generated/shared/c++/TradesResponse.hpp +24 -8
- package/nitrogen/generated/shared/c++/TransportAccount.hpp +36 -20
- package/nitrogen/generated/shared/c++/TransportAccountKind.hpp +1 -1
- package/nitrogen/generated/shared/c++/TransportAsset.hpp +66 -50
- package/nitrogen/generated/shared/c++/TransportAssetQuoteRequest.hpp +42 -26
- package/nitrogen/generated/shared/c++/TransportAssetRef.hpp +27 -11
- package/nitrogen/generated/shared/c++/UnavailableLinkedAccountDetails.hpp +21 -5
- package/nitrogen/generated/shared/c++/UserCounterparty.hpp +30 -14
- package/nitrogen/generated/shared/c++/UserCounterpartyQuoteRequest.hpp +27 -11
- package/nitrogen/generated/shared/c++/WireDetails.hpp +24 -8
- package/package.json +26 -70
- package/react-native.config.js +10 -0
- package/src/context.ts +47 -46
- package/src/index.ts +4 -4
- package/src/provider.tsx +68 -79
- package/src/specs/RNCandle.nitro.ts +463 -399
- package/src/types.ts +317 -342
- package/app.plugin.js +0 -1
- package/lib/commonjs/context.js +0 -17
- package/lib/commonjs/context.js.map +0 -1
- package/lib/commonjs/index.js +0 -26
- package/lib/commonjs/index.js.map +0 -1
- package/lib/commonjs/package.json +0 -1
- package/lib/commonjs/provider.js +0 -122
- package/lib/commonjs/provider.js.map +0 -1
- package/lib/commonjs/specs/RNCandle.nitro.js +0 -6
- package/lib/commonjs/specs/RNCandle.nitro.js.map +0 -1
- package/lib/commonjs/types.js +0 -312
- package/lib/commonjs/types.js.map +0 -1
- package/lib/module/context.js +0 -12
- package/lib/module/context.js.map +0 -1
- package/lib/module/index.js +0 -5
- package/lib/module/index.js.map +0 -1
- package/lib/module/package.json +0 -1
- package/lib/module/provider.js +0 -116
- package/lib/module/provider.js.map +0 -1
- package/lib/module/specs/RNCandle.nitro.js +0 -4
- package/lib/module/specs/RNCandle.nitro.js.map +0 -1
- package/lib/module/types.js +0 -295
- package/lib/module/types.js.map +0 -1
- package/lib/typescript/commonjs/package.json +0 -1
- package/lib/typescript/commonjs/src/context.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/index.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/provider.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/specs/RNCandle.nitro.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types.d.ts.map +0 -1
- package/lib/typescript/module/package.json +0 -1
- package/lib/typescript/module/src/context.d.ts.map +0 -1
- package/lib/typescript/module/src/index.d.ts.map +0 -1
- package/lib/typescript/module/src/provider.d.ts.map +0 -1
- package/lib/typescript/module/src/specs/RNCandle.nitro.d.ts.map +0 -1
- package/lib/typescript/module/src/types.d.ts.map +0 -1
- package/nitrogen/generated/ios/swift/FiatMarketAccountKind.swift +0 -50
- package/nitrogen/generated/ios/swift/MarketAccount.swift +0 -93
- package/nitrogen/generated/ios/swift/MarketAssetKind.swift +0 -38
- package/nitrogen/generated/ios/swift/MarketAssetQuoteRequest.swift +0 -154
- package/nitrogen/generated/ios/swift/MarketTradeAsset.swift +0 -150
- package/nitrogen/generated/ios/swift/MarketTradeAssetRef.swift +0 -55
- package/nitrogen/generated/shared/c++/MarketAccount.hpp +0 -95
- package/nitrogen/generated/shared/c++/MarketAssetKind.hpp +0 -76
- package/nitrogen/generated/shared/c++/MarketAssetQuoteRequest.hpp +0 -86
- package/nitrogen/generated/shared/c++/MarketTradeAsset.hpp +0 -112
- package/nitrogen/generated/shared/c++/MarketTradeAssetRef.hpp +0 -77
- package/plugin/withIosDeploymentTarget.js +0 -71
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// CryptoAsset.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#if __has_include(<NitroModules/JSIConverter.hpp>)
|
|
11
|
+
#include <NitroModules/JSIConverter.hpp>
|
|
12
|
+
#else
|
|
13
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
14
|
+
#endif
|
|
15
|
+
#if __has_include(<NitroModules/NitroDefines.hpp>)
|
|
16
|
+
#include <NitroModules/NitroDefines.hpp>
|
|
17
|
+
#else
|
|
18
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
19
|
+
#endif
|
|
20
|
+
#if __has_include(<NitroModules/JSIHelpers.hpp>)
|
|
21
|
+
#include <NitroModules/JSIHelpers.hpp>
|
|
22
|
+
#else
|
|
23
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
24
|
+
#endif
|
|
25
|
+
#if __has_include(<NitroModules/PropNameIDCache.hpp>)
|
|
26
|
+
#include <NitroModules/PropNameIDCache.hpp>
|
|
27
|
+
#else
|
|
28
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
29
|
+
#endif
|
|
30
|
+
|
|
31
|
+
// Forward declaration of `Service` to properly resolve imports.
|
|
32
|
+
namespace margelo::nitro::rncandle { enum class Service; }
|
|
33
|
+
|
|
34
|
+
#include <string>
|
|
35
|
+
#include "Service.hpp"
|
|
36
|
+
|
|
37
|
+
namespace margelo::nitro::rncandle {
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* A struct which can be represented as a JavaScript object (CryptoAsset).
|
|
41
|
+
*/
|
|
42
|
+
struct CryptoAsset final {
|
|
43
|
+
public:
|
|
44
|
+
std::string assetKind SWIFT_PRIVATE;
|
|
45
|
+
std::string serviceAccountID SWIFT_PRIVATE;
|
|
46
|
+
std::string serviceAssetID SWIFT_PRIVATE;
|
|
47
|
+
std::string symbol SWIFT_PRIVATE;
|
|
48
|
+
double amount SWIFT_PRIVATE;
|
|
49
|
+
std::string serviceTradeID SWIFT_PRIVATE;
|
|
50
|
+
std::string linkedAccountID SWIFT_PRIVATE;
|
|
51
|
+
std::string name SWIFT_PRIVATE;
|
|
52
|
+
std::string color SWIFT_PRIVATE;
|
|
53
|
+
std::string logoURL SWIFT_PRIVATE;
|
|
54
|
+
Service service SWIFT_PRIVATE;
|
|
55
|
+
|
|
56
|
+
public:
|
|
57
|
+
CryptoAsset() = default;
|
|
58
|
+
explicit CryptoAsset(std::string assetKind, std::string serviceAccountID, std::string serviceAssetID, std::string symbol, double amount, std::string serviceTradeID, std::string linkedAccountID, std::string name, std::string color, std::string logoURL, Service service): assetKind(assetKind), serviceAccountID(serviceAccountID), serviceAssetID(serviceAssetID), symbol(symbol), amount(amount), serviceTradeID(serviceTradeID), linkedAccountID(linkedAccountID), name(name), color(color), logoURL(logoURL), service(service) {}
|
|
59
|
+
|
|
60
|
+
public:
|
|
61
|
+
friend bool operator==(const CryptoAsset& lhs, const CryptoAsset& rhs) = default;
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
} // namespace margelo::nitro::rncandle
|
|
65
|
+
|
|
66
|
+
namespace margelo::nitro {
|
|
67
|
+
|
|
68
|
+
// C++ CryptoAsset <> JS CryptoAsset (object)
|
|
69
|
+
template <>
|
|
70
|
+
struct JSIConverter<margelo::nitro::rncandle::CryptoAsset> final {
|
|
71
|
+
static inline margelo::nitro::rncandle::CryptoAsset fromJSI(jsi::Runtime& runtime, const jsi::Value& arg) {
|
|
72
|
+
jsi::Object obj = arg.asObject(runtime);
|
|
73
|
+
return margelo::nitro::rncandle::CryptoAsset(
|
|
74
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind"))),
|
|
75
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAccountID"))),
|
|
76
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID"))),
|
|
77
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "symbol"))),
|
|
78
|
+
JSIConverter<double>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "amount"))),
|
|
79
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID"))),
|
|
80
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID"))),
|
|
81
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "name"))),
|
|
82
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "color"))),
|
|
83
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "logoURL"))),
|
|
84
|
+
JSIConverter<margelo::nitro::rncandle::Service>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "service")))
|
|
85
|
+
);
|
|
86
|
+
}
|
|
87
|
+
static inline jsi::Value toJSI(jsi::Runtime& runtime, const margelo::nitro::rncandle::CryptoAsset& arg) {
|
|
88
|
+
jsi::Object obj(runtime);
|
|
89
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "assetKind"), JSIConverter<std::string>::toJSI(runtime, arg.assetKind));
|
|
90
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceAccountID"), JSIConverter<std::string>::toJSI(runtime, arg.serviceAccountID));
|
|
91
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID"), JSIConverter<std::string>::toJSI(runtime, arg.serviceAssetID));
|
|
92
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "symbol"), JSIConverter<std::string>::toJSI(runtime, arg.symbol));
|
|
93
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "amount"), JSIConverter<double>::toJSI(runtime, arg.amount));
|
|
94
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID"), JSIConverter<std::string>::toJSI(runtime, arg.serviceTradeID));
|
|
95
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID"), JSIConverter<std::string>::toJSI(runtime, arg.linkedAccountID));
|
|
96
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "name"), JSIConverter<std::string>::toJSI(runtime, arg.name));
|
|
97
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "color"), JSIConverter<std::string>::toJSI(runtime, arg.color));
|
|
98
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "logoURL"), JSIConverter<std::string>::toJSI(runtime, arg.logoURL));
|
|
99
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "service"), JSIConverter<margelo::nitro::rncandle::Service>::toJSI(runtime, arg.service));
|
|
100
|
+
return obj;
|
|
101
|
+
}
|
|
102
|
+
static inline bool canConvert(jsi::Runtime& runtime, const jsi::Value& value) {
|
|
103
|
+
if (!value.isObject()) {
|
|
104
|
+
return false;
|
|
105
|
+
}
|
|
106
|
+
jsi::Object obj = value.getObject(runtime);
|
|
107
|
+
if (!nitro::isPlainObject(runtime, obj)) {
|
|
108
|
+
return false;
|
|
109
|
+
}
|
|
110
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind")))) return false;
|
|
111
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAccountID")))) return false;
|
|
112
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID")))) return false;
|
|
113
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "symbol")))) return false;
|
|
114
|
+
if (!JSIConverter<double>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "amount")))) return false;
|
|
115
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID")))) return false;
|
|
116
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID")))) return false;
|
|
117
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "name")))) return false;
|
|
118
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "color")))) return false;
|
|
119
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "logoURL")))) return false;
|
|
120
|
+
if (!JSIConverter<margelo::nitro::rncandle::Service>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "service")))) return false;
|
|
121
|
+
return true;
|
|
122
|
+
}
|
|
123
|
+
};
|
|
124
|
+
|
|
125
|
+
} // namespace margelo::nitro
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// CryptoAssetQuoteRequest.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#if __has_include(<NitroModules/JSIConverter.hpp>)
|
|
11
|
+
#include <NitroModules/JSIConverter.hpp>
|
|
12
|
+
#else
|
|
13
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
14
|
+
#endif
|
|
15
|
+
#if __has_include(<NitroModules/NitroDefines.hpp>)
|
|
16
|
+
#include <NitroModules/NitroDefines.hpp>
|
|
17
|
+
#else
|
|
18
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
19
|
+
#endif
|
|
20
|
+
#if __has_include(<NitroModules/JSIHelpers.hpp>)
|
|
21
|
+
#include <NitroModules/JSIHelpers.hpp>
|
|
22
|
+
#else
|
|
23
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
24
|
+
#endif
|
|
25
|
+
#if __has_include(<NitroModules/PropNameIDCache.hpp>)
|
|
26
|
+
#include <NitroModules/PropNameIDCache.hpp>
|
|
27
|
+
#else
|
|
28
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
29
|
+
#endif
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
#include <string>
|
|
34
|
+
#include <optional>
|
|
35
|
+
|
|
36
|
+
namespace margelo::nitro::rncandle {
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* A struct which can be represented as a JavaScript object (CryptoAssetQuoteRequest).
|
|
40
|
+
*/
|
|
41
|
+
struct CryptoAssetQuoteRequest final {
|
|
42
|
+
public:
|
|
43
|
+
std::string assetKind SWIFT_PRIVATE;
|
|
44
|
+
std::optional<std::string> serviceAccountID SWIFT_PRIVATE;
|
|
45
|
+
std::optional<std::string> serviceAssetID SWIFT_PRIVATE;
|
|
46
|
+
std::optional<std::string> symbol SWIFT_PRIVATE;
|
|
47
|
+
std::optional<double> amount SWIFT_PRIVATE;
|
|
48
|
+
|
|
49
|
+
public:
|
|
50
|
+
CryptoAssetQuoteRequest() = default;
|
|
51
|
+
explicit CryptoAssetQuoteRequest(std::string assetKind, std::optional<std::string> serviceAccountID, std::optional<std::string> serviceAssetID, std::optional<std::string> symbol, std::optional<double> amount): assetKind(assetKind), serviceAccountID(serviceAccountID), serviceAssetID(serviceAssetID), symbol(symbol), amount(amount) {}
|
|
52
|
+
|
|
53
|
+
public:
|
|
54
|
+
friend bool operator==(const CryptoAssetQuoteRequest& lhs, const CryptoAssetQuoteRequest& rhs) = default;
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
} // namespace margelo::nitro::rncandle
|
|
58
|
+
|
|
59
|
+
namespace margelo::nitro {
|
|
60
|
+
|
|
61
|
+
// C++ CryptoAssetQuoteRequest <> JS CryptoAssetQuoteRequest (object)
|
|
62
|
+
template <>
|
|
63
|
+
struct JSIConverter<margelo::nitro::rncandle::CryptoAssetQuoteRequest> final {
|
|
64
|
+
static inline margelo::nitro::rncandle::CryptoAssetQuoteRequest fromJSI(jsi::Runtime& runtime, const jsi::Value& arg) {
|
|
65
|
+
jsi::Object obj = arg.asObject(runtime);
|
|
66
|
+
return margelo::nitro::rncandle::CryptoAssetQuoteRequest(
|
|
67
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind"))),
|
|
68
|
+
JSIConverter<std::optional<std::string>>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAccountID"))),
|
|
69
|
+
JSIConverter<std::optional<std::string>>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID"))),
|
|
70
|
+
JSIConverter<std::optional<std::string>>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "symbol"))),
|
|
71
|
+
JSIConverter<std::optional<double>>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "amount")))
|
|
72
|
+
);
|
|
73
|
+
}
|
|
74
|
+
static inline jsi::Value toJSI(jsi::Runtime& runtime, const margelo::nitro::rncandle::CryptoAssetQuoteRequest& arg) {
|
|
75
|
+
jsi::Object obj(runtime);
|
|
76
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "assetKind"), JSIConverter<std::string>::toJSI(runtime, arg.assetKind));
|
|
77
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceAccountID"), JSIConverter<std::optional<std::string>>::toJSI(runtime, arg.serviceAccountID));
|
|
78
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID"), JSIConverter<std::optional<std::string>>::toJSI(runtime, arg.serviceAssetID));
|
|
79
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "symbol"), JSIConverter<std::optional<std::string>>::toJSI(runtime, arg.symbol));
|
|
80
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "amount"), JSIConverter<std::optional<double>>::toJSI(runtime, arg.amount));
|
|
81
|
+
return obj;
|
|
82
|
+
}
|
|
83
|
+
static inline bool canConvert(jsi::Runtime& runtime, const jsi::Value& value) {
|
|
84
|
+
if (!value.isObject()) {
|
|
85
|
+
return false;
|
|
86
|
+
}
|
|
87
|
+
jsi::Object obj = value.getObject(runtime);
|
|
88
|
+
if (!nitro::isPlainObject(runtime, obj)) {
|
|
89
|
+
return false;
|
|
90
|
+
}
|
|
91
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind")))) return false;
|
|
92
|
+
if (!JSIConverter<std::optional<std::string>>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAccountID")))) return false;
|
|
93
|
+
if (!JSIConverter<std::optional<std::string>>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID")))) return false;
|
|
94
|
+
if (!JSIConverter<std::optional<std::string>>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "symbol")))) return false;
|
|
95
|
+
if (!JSIConverter<std::optional<double>>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "amount")))) return false;
|
|
96
|
+
return true;
|
|
97
|
+
}
|
|
98
|
+
};
|
|
99
|
+
|
|
100
|
+
} // namespace margelo::nitro
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// CryptoAssetRef.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#if __has_include(<NitroModules/JSIConverter.hpp>)
|
|
11
|
+
#include <NitroModules/JSIConverter.hpp>
|
|
12
|
+
#else
|
|
13
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
14
|
+
#endif
|
|
15
|
+
#if __has_include(<NitroModules/NitroDefines.hpp>)
|
|
16
|
+
#include <NitroModules/NitroDefines.hpp>
|
|
17
|
+
#else
|
|
18
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
19
|
+
#endif
|
|
20
|
+
#if __has_include(<NitroModules/JSIHelpers.hpp>)
|
|
21
|
+
#include <NitroModules/JSIHelpers.hpp>
|
|
22
|
+
#else
|
|
23
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
24
|
+
#endif
|
|
25
|
+
#if __has_include(<NitroModules/PropNameIDCache.hpp>)
|
|
26
|
+
#include <NitroModules/PropNameIDCache.hpp>
|
|
27
|
+
#else
|
|
28
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
29
|
+
#endif
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
#include <string>
|
|
34
|
+
|
|
35
|
+
namespace margelo::nitro::rncandle {
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* A struct which can be represented as a JavaScript object (CryptoAssetRef).
|
|
39
|
+
*/
|
|
40
|
+
struct CryptoAssetRef final {
|
|
41
|
+
public:
|
|
42
|
+
std::string assetKind SWIFT_PRIVATE;
|
|
43
|
+
std::string serviceTradeID SWIFT_PRIVATE;
|
|
44
|
+
std::string linkedAccountID SWIFT_PRIVATE;
|
|
45
|
+
|
|
46
|
+
public:
|
|
47
|
+
CryptoAssetRef() = default;
|
|
48
|
+
explicit CryptoAssetRef(std::string assetKind, std::string serviceTradeID, std::string linkedAccountID): assetKind(assetKind), serviceTradeID(serviceTradeID), linkedAccountID(linkedAccountID) {}
|
|
49
|
+
|
|
50
|
+
public:
|
|
51
|
+
friend bool operator==(const CryptoAssetRef& lhs, const CryptoAssetRef& rhs) = default;
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
} // namespace margelo::nitro::rncandle
|
|
55
|
+
|
|
56
|
+
namespace margelo::nitro {
|
|
57
|
+
|
|
58
|
+
// C++ CryptoAssetRef <> JS CryptoAssetRef (object)
|
|
59
|
+
template <>
|
|
60
|
+
struct JSIConverter<margelo::nitro::rncandle::CryptoAssetRef> final {
|
|
61
|
+
static inline margelo::nitro::rncandle::CryptoAssetRef fromJSI(jsi::Runtime& runtime, const jsi::Value& arg) {
|
|
62
|
+
jsi::Object obj = arg.asObject(runtime);
|
|
63
|
+
return margelo::nitro::rncandle::CryptoAssetRef(
|
|
64
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind"))),
|
|
65
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID"))),
|
|
66
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID")))
|
|
67
|
+
);
|
|
68
|
+
}
|
|
69
|
+
static inline jsi::Value toJSI(jsi::Runtime& runtime, const margelo::nitro::rncandle::CryptoAssetRef& arg) {
|
|
70
|
+
jsi::Object obj(runtime);
|
|
71
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "assetKind"), JSIConverter<std::string>::toJSI(runtime, arg.assetKind));
|
|
72
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID"), JSIConverter<std::string>::toJSI(runtime, arg.serviceTradeID));
|
|
73
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID"), JSIConverter<std::string>::toJSI(runtime, arg.linkedAccountID));
|
|
74
|
+
return obj;
|
|
75
|
+
}
|
|
76
|
+
static inline bool canConvert(jsi::Runtime& runtime, const jsi::Value& value) {
|
|
77
|
+
if (!value.isObject()) {
|
|
78
|
+
return false;
|
|
79
|
+
}
|
|
80
|
+
jsi::Object obj = value.getObject(runtime);
|
|
81
|
+
if (!nitro::isPlainObject(runtime, obj)) {
|
|
82
|
+
return false;
|
|
83
|
+
}
|
|
84
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind")))) return false;
|
|
85
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID")))) return false;
|
|
86
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID")))) return false;
|
|
87
|
+
return true;
|
|
88
|
+
}
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
} // namespace margelo::nitro
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// EventAsset.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#if __has_include(<NitroModules/JSIConverter.hpp>)
|
|
11
|
+
#include <NitroModules/JSIConverter.hpp>
|
|
12
|
+
#else
|
|
13
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
14
|
+
#endif
|
|
15
|
+
#if __has_include(<NitroModules/NitroDefines.hpp>)
|
|
16
|
+
#include <NitroModules/NitroDefines.hpp>
|
|
17
|
+
#else
|
|
18
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
19
|
+
#endif
|
|
20
|
+
#if __has_include(<NitroModules/JSIHelpers.hpp>)
|
|
21
|
+
#include <NitroModules/JSIHelpers.hpp>
|
|
22
|
+
#else
|
|
23
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
24
|
+
#endif
|
|
25
|
+
#if __has_include(<NitroModules/PropNameIDCache.hpp>)
|
|
26
|
+
#include <NitroModules/PropNameIDCache.hpp>
|
|
27
|
+
#else
|
|
28
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
29
|
+
#endif
|
|
30
|
+
|
|
31
|
+
// Forward declaration of `Coordinates` to properly resolve imports.
|
|
32
|
+
namespace margelo::nitro::rncandle { struct Coordinates; }
|
|
33
|
+
// Forward declaration of `Address` to properly resolve imports.
|
|
34
|
+
namespace margelo::nitro::rncandle { struct Address; }
|
|
35
|
+
// Forward declaration of `Service` to properly resolve imports.
|
|
36
|
+
namespace margelo::nitro::rncandle { enum class Service; }
|
|
37
|
+
|
|
38
|
+
#include <string>
|
|
39
|
+
#include "Coordinates.hpp"
|
|
40
|
+
#include "Address.hpp"
|
|
41
|
+
#include "Service.hpp"
|
|
42
|
+
|
|
43
|
+
namespace margelo::nitro::rncandle {
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* A struct which can be represented as a JavaScript object (EventAsset).
|
|
47
|
+
*/
|
|
48
|
+
struct EventAsset final {
|
|
49
|
+
public:
|
|
50
|
+
std::string assetKind SWIFT_PRIVATE;
|
|
51
|
+
std::string serviceTradeID SWIFT_PRIVATE;
|
|
52
|
+
std::string serviceAssetID SWIFT_PRIVATE;
|
|
53
|
+
std::string name SWIFT_PRIVATE;
|
|
54
|
+
std::string description SWIFT_PRIVATE;
|
|
55
|
+
std::string imageURL SWIFT_PRIVATE;
|
|
56
|
+
Coordinates locationCoordinates SWIFT_PRIVATE;
|
|
57
|
+
Address locationAddress SWIFT_PRIVATE;
|
|
58
|
+
double partySize SWIFT_PRIVATE;
|
|
59
|
+
std::string dateTime SWIFT_PRIVATE;
|
|
60
|
+
std::string linkedAccountID SWIFT_PRIVATE;
|
|
61
|
+
Service service SWIFT_PRIVATE;
|
|
62
|
+
|
|
63
|
+
public:
|
|
64
|
+
EventAsset() = default;
|
|
65
|
+
explicit EventAsset(std::string assetKind, std::string serviceTradeID, std::string serviceAssetID, std::string name, std::string description, std::string imageURL, Coordinates locationCoordinates, Address locationAddress, double partySize, std::string dateTime, std::string linkedAccountID, Service service): assetKind(assetKind), serviceTradeID(serviceTradeID), serviceAssetID(serviceAssetID), name(name), description(description), imageURL(imageURL), locationCoordinates(locationCoordinates), locationAddress(locationAddress), partySize(partySize), dateTime(dateTime), linkedAccountID(linkedAccountID), service(service) {}
|
|
66
|
+
|
|
67
|
+
public:
|
|
68
|
+
friend bool operator==(const EventAsset& lhs, const EventAsset& rhs) = default;
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
} // namespace margelo::nitro::rncandle
|
|
72
|
+
|
|
73
|
+
namespace margelo::nitro {
|
|
74
|
+
|
|
75
|
+
// C++ EventAsset <> JS EventAsset (object)
|
|
76
|
+
template <>
|
|
77
|
+
struct JSIConverter<margelo::nitro::rncandle::EventAsset> final {
|
|
78
|
+
static inline margelo::nitro::rncandle::EventAsset fromJSI(jsi::Runtime& runtime, const jsi::Value& arg) {
|
|
79
|
+
jsi::Object obj = arg.asObject(runtime);
|
|
80
|
+
return margelo::nitro::rncandle::EventAsset(
|
|
81
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind"))),
|
|
82
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID"))),
|
|
83
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID"))),
|
|
84
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "name"))),
|
|
85
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "description"))),
|
|
86
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "imageURL"))),
|
|
87
|
+
JSIConverter<margelo::nitro::rncandle::Coordinates>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "locationCoordinates"))),
|
|
88
|
+
JSIConverter<margelo::nitro::rncandle::Address>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "locationAddress"))),
|
|
89
|
+
JSIConverter<double>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "partySize"))),
|
|
90
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "dateTime"))),
|
|
91
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID"))),
|
|
92
|
+
JSIConverter<margelo::nitro::rncandle::Service>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "service")))
|
|
93
|
+
);
|
|
94
|
+
}
|
|
95
|
+
static inline jsi::Value toJSI(jsi::Runtime& runtime, const margelo::nitro::rncandle::EventAsset& arg) {
|
|
96
|
+
jsi::Object obj(runtime);
|
|
97
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "assetKind"), JSIConverter<std::string>::toJSI(runtime, arg.assetKind));
|
|
98
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID"), JSIConverter<std::string>::toJSI(runtime, arg.serviceTradeID));
|
|
99
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID"), JSIConverter<std::string>::toJSI(runtime, arg.serviceAssetID));
|
|
100
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "name"), JSIConverter<std::string>::toJSI(runtime, arg.name));
|
|
101
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "description"), JSIConverter<std::string>::toJSI(runtime, arg.description));
|
|
102
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "imageURL"), JSIConverter<std::string>::toJSI(runtime, arg.imageURL));
|
|
103
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "locationCoordinates"), JSIConverter<margelo::nitro::rncandle::Coordinates>::toJSI(runtime, arg.locationCoordinates));
|
|
104
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "locationAddress"), JSIConverter<margelo::nitro::rncandle::Address>::toJSI(runtime, arg.locationAddress));
|
|
105
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "partySize"), JSIConverter<double>::toJSI(runtime, arg.partySize));
|
|
106
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "dateTime"), JSIConverter<std::string>::toJSI(runtime, arg.dateTime));
|
|
107
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID"), JSIConverter<std::string>::toJSI(runtime, arg.linkedAccountID));
|
|
108
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "service"), JSIConverter<margelo::nitro::rncandle::Service>::toJSI(runtime, arg.service));
|
|
109
|
+
return obj;
|
|
110
|
+
}
|
|
111
|
+
static inline bool canConvert(jsi::Runtime& runtime, const jsi::Value& value) {
|
|
112
|
+
if (!value.isObject()) {
|
|
113
|
+
return false;
|
|
114
|
+
}
|
|
115
|
+
jsi::Object obj = value.getObject(runtime);
|
|
116
|
+
if (!nitro::isPlainObject(runtime, obj)) {
|
|
117
|
+
return false;
|
|
118
|
+
}
|
|
119
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind")))) return false;
|
|
120
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID")))) return false;
|
|
121
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID")))) return false;
|
|
122
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "name")))) return false;
|
|
123
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "description")))) return false;
|
|
124
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "imageURL")))) return false;
|
|
125
|
+
if (!JSIConverter<margelo::nitro::rncandle::Coordinates>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "locationCoordinates")))) return false;
|
|
126
|
+
if (!JSIConverter<margelo::nitro::rncandle::Address>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "locationAddress")))) return false;
|
|
127
|
+
if (!JSIConverter<double>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "partySize")))) return false;
|
|
128
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "dateTime")))) return false;
|
|
129
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID")))) return false;
|
|
130
|
+
if (!JSIConverter<margelo::nitro::rncandle::Service>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "service")))) return false;
|
|
131
|
+
return true;
|
|
132
|
+
}
|
|
133
|
+
};
|
|
134
|
+
|
|
135
|
+
} // namespace margelo::nitro
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// EventAssetQuoteRequest.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#if __has_include(<NitroModules/JSIConverter.hpp>)
|
|
11
|
+
#include <NitroModules/JSIConverter.hpp>
|
|
12
|
+
#else
|
|
13
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
14
|
+
#endif
|
|
15
|
+
#if __has_include(<NitroModules/NitroDefines.hpp>)
|
|
16
|
+
#include <NitroModules/NitroDefines.hpp>
|
|
17
|
+
#else
|
|
18
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
19
|
+
#endif
|
|
20
|
+
#if __has_include(<NitroModules/JSIHelpers.hpp>)
|
|
21
|
+
#include <NitroModules/JSIHelpers.hpp>
|
|
22
|
+
#else
|
|
23
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
24
|
+
#endif
|
|
25
|
+
#if __has_include(<NitroModules/PropNameIDCache.hpp>)
|
|
26
|
+
#include <NitroModules/PropNameIDCache.hpp>
|
|
27
|
+
#else
|
|
28
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
29
|
+
#endif
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
#include <string>
|
|
34
|
+
#include <optional>
|
|
35
|
+
|
|
36
|
+
namespace margelo::nitro::rncandle {
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* A struct which can be represented as a JavaScript object (EventAssetQuoteRequest).
|
|
40
|
+
*/
|
|
41
|
+
struct EventAssetQuoteRequest final {
|
|
42
|
+
public:
|
|
43
|
+
std::string assetKind SWIFT_PRIVATE;
|
|
44
|
+
std::optional<std::string> serviceAssetID SWIFT_PRIVATE;
|
|
45
|
+
std::optional<double> partySize SWIFT_PRIVATE;
|
|
46
|
+
std::optional<std::string> dateTime SWIFT_PRIVATE;
|
|
47
|
+
|
|
48
|
+
public:
|
|
49
|
+
EventAssetQuoteRequest() = default;
|
|
50
|
+
explicit EventAssetQuoteRequest(std::string assetKind, std::optional<std::string> serviceAssetID, std::optional<double> partySize, std::optional<std::string> dateTime): assetKind(assetKind), serviceAssetID(serviceAssetID), partySize(partySize), dateTime(dateTime) {}
|
|
51
|
+
|
|
52
|
+
public:
|
|
53
|
+
friend bool operator==(const EventAssetQuoteRequest& lhs, const EventAssetQuoteRequest& rhs) = default;
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
} // namespace margelo::nitro::rncandle
|
|
57
|
+
|
|
58
|
+
namespace margelo::nitro {
|
|
59
|
+
|
|
60
|
+
// C++ EventAssetQuoteRequest <> JS EventAssetQuoteRequest (object)
|
|
61
|
+
template <>
|
|
62
|
+
struct JSIConverter<margelo::nitro::rncandle::EventAssetQuoteRequest> final {
|
|
63
|
+
static inline margelo::nitro::rncandle::EventAssetQuoteRequest fromJSI(jsi::Runtime& runtime, const jsi::Value& arg) {
|
|
64
|
+
jsi::Object obj = arg.asObject(runtime);
|
|
65
|
+
return margelo::nitro::rncandle::EventAssetQuoteRequest(
|
|
66
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind"))),
|
|
67
|
+
JSIConverter<std::optional<std::string>>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID"))),
|
|
68
|
+
JSIConverter<std::optional<double>>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "partySize"))),
|
|
69
|
+
JSIConverter<std::optional<std::string>>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "dateTime")))
|
|
70
|
+
);
|
|
71
|
+
}
|
|
72
|
+
static inline jsi::Value toJSI(jsi::Runtime& runtime, const margelo::nitro::rncandle::EventAssetQuoteRequest& arg) {
|
|
73
|
+
jsi::Object obj(runtime);
|
|
74
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "assetKind"), JSIConverter<std::string>::toJSI(runtime, arg.assetKind));
|
|
75
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID"), JSIConverter<std::optional<std::string>>::toJSI(runtime, arg.serviceAssetID));
|
|
76
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "partySize"), JSIConverter<std::optional<double>>::toJSI(runtime, arg.partySize));
|
|
77
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "dateTime"), JSIConverter<std::optional<std::string>>::toJSI(runtime, arg.dateTime));
|
|
78
|
+
return obj;
|
|
79
|
+
}
|
|
80
|
+
static inline bool canConvert(jsi::Runtime& runtime, const jsi::Value& value) {
|
|
81
|
+
if (!value.isObject()) {
|
|
82
|
+
return false;
|
|
83
|
+
}
|
|
84
|
+
jsi::Object obj = value.getObject(runtime);
|
|
85
|
+
if (!nitro::isPlainObject(runtime, obj)) {
|
|
86
|
+
return false;
|
|
87
|
+
}
|
|
88
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind")))) return false;
|
|
89
|
+
if (!JSIConverter<std::optional<std::string>>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceAssetID")))) return false;
|
|
90
|
+
if (!JSIConverter<std::optional<double>>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "partySize")))) return false;
|
|
91
|
+
if (!JSIConverter<std::optional<std::string>>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "dateTime")))) return false;
|
|
92
|
+
return true;
|
|
93
|
+
}
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
} // namespace margelo::nitro
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// EventAssetRef.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#if __has_include(<NitroModules/JSIConverter.hpp>)
|
|
11
|
+
#include <NitroModules/JSIConverter.hpp>
|
|
12
|
+
#else
|
|
13
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
14
|
+
#endif
|
|
15
|
+
#if __has_include(<NitroModules/NitroDefines.hpp>)
|
|
16
|
+
#include <NitroModules/NitroDefines.hpp>
|
|
17
|
+
#else
|
|
18
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
19
|
+
#endif
|
|
20
|
+
#if __has_include(<NitroModules/JSIHelpers.hpp>)
|
|
21
|
+
#include <NitroModules/JSIHelpers.hpp>
|
|
22
|
+
#else
|
|
23
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
24
|
+
#endif
|
|
25
|
+
#if __has_include(<NitroModules/PropNameIDCache.hpp>)
|
|
26
|
+
#include <NitroModules/PropNameIDCache.hpp>
|
|
27
|
+
#else
|
|
28
|
+
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
|
|
29
|
+
#endif
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
#include <string>
|
|
34
|
+
|
|
35
|
+
namespace margelo::nitro::rncandle {
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* A struct which can be represented as a JavaScript object (EventAssetRef).
|
|
39
|
+
*/
|
|
40
|
+
struct EventAssetRef final {
|
|
41
|
+
public:
|
|
42
|
+
std::string assetKind SWIFT_PRIVATE;
|
|
43
|
+
std::string serviceTradeID SWIFT_PRIVATE;
|
|
44
|
+
std::string linkedAccountID SWIFT_PRIVATE;
|
|
45
|
+
|
|
46
|
+
public:
|
|
47
|
+
EventAssetRef() = default;
|
|
48
|
+
explicit EventAssetRef(std::string assetKind, std::string serviceTradeID, std::string linkedAccountID): assetKind(assetKind), serviceTradeID(serviceTradeID), linkedAccountID(linkedAccountID) {}
|
|
49
|
+
|
|
50
|
+
public:
|
|
51
|
+
friend bool operator==(const EventAssetRef& lhs, const EventAssetRef& rhs) = default;
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
} // namespace margelo::nitro::rncandle
|
|
55
|
+
|
|
56
|
+
namespace margelo::nitro {
|
|
57
|
+
|
|
58
|
+
// C++ EventAssetRef <> JS EventAssetRef (object)
|
|
59
|
+
template <>
|
|
60
|
+
struct JSIConverter<margelo::nitro::rncandle::EventAssetRef> final {
|
|
61
|
+
static inline margelo::nitro::rncandle::EventAssetRef fromJSI(jsi::Runtime& runtime, const jsi::Value& arg) {
|
|
62
|
+
jsi::Object obj = arg.asObject(runtime);
|
|
63
|
+
return margelo::nitro::rncandle::EventAssetRef(
|
|
64
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind"))),
|
|
65
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID"))),
|
|
66
|
+
JSIConverter<std::string>::fromJSI(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID")))
|
|
67
|
+
);
|
|
68
|
+
}
|
|
69
|
+
static inline jsi::Value toJSI(jsi::Runtime& runtime, const margelo::nitro::rncandle::EventAssetRef& arg) {
|
|
70
|
+
jsi::Object obj(runtime);
|
|
71
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "assetKind"), JSIConverter<std::string>::toJSI(runtime, arg.assetKind));
|
|
72
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID"), JSIConverter<std::string>::toJSI(runtime, arg.serviceTradeID));
|
|
73
|
+
obj.setProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID"), JSIConverter<std::string>::toJSI(runtime, arg.linkedAccountID));
|
|
74
|
+
return obj;
|
|
75
|
+
}
|
|
76
|
+
static inline bool canConvert(jsi::Runtime& runtime, const jsi::Value& value) {
|
|
77
|
+
if (!value.isObject()) {
|
|
78
|
+
return false;
|
|
79
|
+
}
|
|
80
|
+
jsi::Object obj = value.getObject(runtime);
|
|
81
|
+
if (!nitro::isPlainObject(runtime, obj)) {
|
|
82
|
+
return false;
|
|
83
|
+
}
|
|
84
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "assetKind")))) return false;
|
|
85
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "serviceTradeID")))) return false;
|
|
86
|
+
if (!JSIConverter<std::string>::canConvert(runtime, obj.getProperty(runtime, PropNameIDCache::get(runtime, "linkedAccountID")))) return false;
|
|
87
|
+
return true;
|
|
88
|
+
}
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
} // namespace margelo::nitro
|