mobilyflow-react-native-sdk 0.7.0-alpha.2 → 0.7.0-alpha.5

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.
Files changed (40) hide show
  1. package/android/build.gradle +10 -14
  2. package/android/generated/jni/CMakeLists.txt +1 -9
  3. package/android/generated/jni/react/renderer/components/RNMobilyflowReactNativeSdkSpec/RNMobilyflowReactNativeSdkSpecJSI.h +178 -218
  4. package/ios/MobilyflowReactNativeSdk.h +2 -4
  5. package/ios/MobilyflowReactNativeSdk.mm +4 -0
  6. package/ios/Utils/ParserMobilyPurchaseSDKOptions.h +1 -1
  7. package/ios/generated/ReactCodegen/RNMobilyflowReactNativeSdkSpecJSI.h +328 -0
  8. package/lib/commonjs/MobilyPurchaseSDK.js +5 -1
  9. package/lib/commonjs/MobilyPurchaseSDK.js.map +1 -1
  10. package/lib/commonjs/package.json +1 -0
  11. package/lib/commonjs/version.js +8 -0
  12. package/lib/commonjs/version.js.map +1 -0
  13. package/lib/module/MobilyPurchaseSDK.js +5 -1
  14. package/lib/module/MobilyPurchaseSDK.js.map +1 -1
  15. package/lib/module/package.json +1 -0
  16. package/lib/module/version.js +4 -0
  17. package/lib/module/version.js.map +1 -0
  18. package/lib/typescript/commonjs/src/MobilyPurchaseSDK.d.ts +2 -1
  19. package/lib/typescript/commonjs/src/MobilyPurchaseSDK.d.ts.map +1 -1
  20. package/lib/typescript/commonjs/src/utils/object-transformer.d.ts +1 -1
  21. package/lib/typescript/commonjs/src/utils/object-transformer.d.ts.map +1 -1
  22. package/lib/typescript/commonjs/src/version.d.ts +2 -0
  23. package/lib/typescript/commonjs/src/version.d.ts.map +1 -0
  24. package/lib/typescript/module/src/MobilyPurchaseSDK.d.ts +2 -1
  25. package/lib/typescript/module/src/MobilyPurchaseSDK.d.ts.map +1 -1
  26. package/lib/typescript/module/src/utils/object-transformer.d.ts +1 -1
  27. package/lib/typescript/module/src/utils/object-transformer.d.ts.map +1 -1
  28. package/lib/typescript/module/src/version.d.ts +2 -0
  29. package/lib/typescript/module/src/version.d.ts.map +1 -0
  30. package/package.json +8 -19
  31. package/src/MobilyPurchaseSDK.tsx +6 -1
  32. package/src/version.ts +1 -0
  33. package/LICENSE +0 -20
  34. package/README.md +0 -33
  35. package/android/generated/jni/react/renderer/components/RNMobilyflowReactNativeSdkSpec/RNMobilyflowReactNativeSdkSpecJSI-generated.cpp +0 -172
  36. package/android/gradle.properties +0 -5
  37. package/ios/generated/RNMobilyflowReactNativeSdkSpecJSI-generated.cpp +0 -172
  38. package/ios/generated/RNMobilyflowReactNativeSdkSpecJSI.h +0 -368
  39. /package/ios/generated/{RNMobilyflowReactNativeSdkSpec → ReactCodegen/RNMobilyflowReactNativeSdkSpec}/RNMobilyflowReactNativeSdkSpec-generated.mm +0 -0
  40. /package/ios/generated/{RNMobilyflowReactNativeSdkSpec → ReactCodegen/RNMobilyflowReactNativeSdkSpec}/RNMobilyflowReactNativeSdkSpec.h +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mobilyflow-react-native-sdk",
3
- "version": "0.7.0-alpha.2",
3
+ "version": "0.7.0-alpha.5",
4
4
  "description": "MobilyFlow React Native SDK",
5
5
  "source": "./src/index.tsx",
6
6
  "main": "./lib/commonjs/index.js",
@@ -41,13 +41,12 @@
41
41
  "!**/.*"
42
42
  ],
43
43
  "scripts": {
44
- "example": "yarn workspace mobilyflow-react-native-sdk-example",
45
44
  "test": "jest",
46
45
  "compile": "tsc",
47
46
  "lint": "eslint \"**/*.{js,ts,tsx}\"",
48
- "clean": "del-cli android/build example/android/build example/android/app/build example/ios/build lib",
49
- "prepare": "bob build",
50
- "pub": "yarn prepare && npm publish --access public"
47
+ "clean": "del-cli android/build lib",
48
+ "build": "sh ./scripts/prebuild.sh && bob build",
49
+ "pub": "yarn build && npm publish --access public"
51
50
  },
52
51
  "keywords": [
53
52
  "react-native",
@@ -78,27 +77,18 @@
78
77
  "eslint-plugin-prettier": "^5.0.1",
79
78
  "jest": "^29.7.0",
80
79
  "prettier": "^3.0.3",
81
- "react": "19.0.0",
82
- "react-native": "0.78.0",
83
- "react-native-builder-bob": "^0.36.0",
84
- "turbo": "^1.10.7",
80
+ "react": "19.2.0",
81
+ "react-native": ">=0.80.0",
82
+ "react-native-builder-bob": "^0.41.0",
85
83
  "typescript": "^5.2.2"
86
84
  },
87
- "resolutions": {
88
- "@types/react": "^18.2.44"
89
- },
90
85
  "peerDependencies": {
91
86
  "react": "*",
92
87
  "react-native": "*"
93
88
  },
94
- "workspaces": [
95
- "example"
96
- ],
97
- "packageManager": "yarn@3.6.1",
98
89
  "jest": {
99
90
  "preset": "react-native",
100
91
  "modulePathIgnorePatterns": [
101
- "<rootDir>/example/node_modules",
102
92
  "<rootDir>/lib/"
103
93
  ]
104
94
  },
@@ -160,8 +150,7 @@
160
150
  [
161
151
  "typescript",
162
152
  {
163
- "project": "tsconfig.build.json",
164
- "esm": true
153
+ "project": "tsconfig.build.json"
165
154
  }
166
155
  ]
167
156
  ]
@@ -11,6 +11,7 @@ import { PurchaseOptions } from './models/internal/purchase-options';
11
11
  import { MobilyTransferOwnershipStatus } from './enums/mobily-transfer-ownership-status';
12
12
  import { MobilyEvent } from './models/mobily-event';
13
13
  import { MobilyRefundDialogResult } from './enums/mobily-refund-dialog-result';
14
+ import { BRIDGE_VERSION } from './version';
14
15
 
15
16
  function throwError(error: any) {
16
17
  if (RNPlatform.OS === 'android') {
@@ -227,11 +228,15 @@ export const MobilyPurchaseSDK = {
227
228
  }
228
229
  },
229
230
 
230
- getSDKVersion: async () => {
231
+ getSDKNativeVersion: async () => {
231
232
  try {
232
233
  return await MobilyflowReactNativeSdk.getSDKVersion();
233
234
  } catch (error: any) {
234
235
  throw throwError(error);
235
236
  }
236
237
  },
238
+
239
+ getSDKBridgeVersion: () => {
240
+ return BRIDGE_VERSION;
241
+ },
237
242
  };
package/src/version.ts ADDED
@@ -0,0 +1 @@
1
+ export const BRIDGE_VERSION = '0.7.0-alpha.5';
package/LICENSE DELETED
@@ -1,20 +0,0 @@
1
- MIT License
2
-
3
- Copyright (c) 2025 MobilyFlow
4
- Permission is hereby granted, free of charge, to any person obtaining a copy
5
- of this software and associated documentation files (the "Software"), to deal
6
- in the Software without restriction, including without limitation the rights
7
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8
- copies of the Software, and to permit persons to whom the Software is
9
- furnished to do so, subject to the following conditions:
10
-
11
- The above copyright notice and this permission notice shall be included in all
12
- copies or substantial portions of the Software.
13
-
14
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20
- SOFTWARE.
package/README.md DELETED
@@ -1,33 +0,0 @@
1
- # mobilyflow-react-native-sdk
2
-
3
- MobilyFlow React Native SDK
4
-
5
- ## Installation
6
-
7
- ```sh
8
- npm install mobilyflow-react-native-sdk
9
- ```
10
-
11
- ## Usage
12
-
13
-
14
- ```js
15
- import { multiply } from 'mobilyflow-react-native-sdk';
16
-
17
- // ...
18
-
19
- const result = multiply(3, 7);
20
- ```
21
-
22
-
23
- ## Contributing
24
-
25
- See the [contributing guide](CONTRIBUTING.md) to learn how to contribute to the repository and the development workflow.
26
-
27
- ## License
28
-
29
- MIT
30
-
31
- ---
32
-
33
- Made with [create-react-native-library](https://github.com/callstack/react-native-builder-bob)
@@ -1,172 +0,0 @@
1
- /**
2
- * This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
3
- *
4
- * Do not edit this file as changes may cause incorrect behavior and will be lost
5
- * once the code is regenerated.
6
- *
7
- * @generated by codegen project: GenerateModuleCpp.js
8
- */
9
-
10
- #include "RNMobilyflowReactNativeSdkSpecJSI.h"
11
-
12
- namespace facebook::react {
13
-
14
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_initialize(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
15
- static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->initialize(
16
- rt,
17
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt),
18
- count <= 1 ? throw jsi::JSError(rt, "Expected argument in position 1 to be passed") : args[1].asString(rt),
19
- count <= 2 ? throw jsi::JSError(rt, "Expected argument in position 2 to be passed") : args[2].asString(rt),
20
- count <= 3 || args[3].isUndefined() ? std::nullopt : std::make_optional(args[3].asObject(rt))
21
- );
22
- return jsi::Value::undefined();
23
- }
24
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_close(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
25
- static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->close(
26
- rt
27
- );
28
- return jsi::Value::undefined();
29
- }
30
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_login(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
31
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->login(
32
- rt,
33
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
34
- );
35
- }
36
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_logout(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
37
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->logout(
38
- rt
39
- );
40
- }
41
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getProducts(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
42
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getProducts(
43
- rt,
44
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asObject(rt).asArray(rt),
45
- count <= 1 ? throw jsi::JSError(rt, "Expected argument in position 1 to be passed") : args[1].asBool()
46
- );
47
- }
48
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSubscriptionGroups(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
49
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getSubscriptionGroups(
50
- rt,
51
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asObject(rt).asArray(rt),
52
- count <= 1 ? throw jsi::JSError(rt, "Expected argument in position 1 to be passed") : args[1].asBool()
53
- );
54
- }
55
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSubscriptionGroupById(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
56
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getSubscriptionGroupById(
57
- rt,
58
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
59
- );
60
- }
61
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlementForSubscription(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
62
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getEntitlementForSubscription(
63
- rt,
64
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
65
- );
66
- }
67
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlement(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
68
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getEntitlement(
69
- rt,
70
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
71
- );
72
- }
73
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlements(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
74
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getEntitlements(
75
- rt,
76
- count <= 0 || args[0].isUndefined() ? std::nullopt : std::make_optional(args[0].asObject(rt).asArray(rt))
77
- );
78
- }
79
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getExternalEntitlements(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
80
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getExternalEntitlements(
81
- rt
82
- );
83
- }
84
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_requestTransferOwnership(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
85
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->requestTransferOwnership(
86
- rt
87
- );
88
- }
89
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openManageSubscription(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
90
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->openManageSubscription(
91
- rt
92
- );
93
- }
94
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openRefundDialogForProduct(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
95
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->openRefundDialogForProduct(
96
- rt,
97
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
98
- );
99
- }
100
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openRefundDialogForTransactionId(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
101
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->openRefundDialogForTransactionId(
102
- rt,
103
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
104
- );
105
- }
106
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_purchaseProduct(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
107
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->purchaseProduct(
108
- rt,
109
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt),
110
- count <= 1 || args[1].isUndefined() ? std::nullopt : std::make_optional(args[1].asObject(rt))
111
- );
112
- }
113
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_sendDiagnostic(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
114
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->sendDiagnostic(
115
- rt
116
- );
117
- }
118
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getStoreCountry(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
119
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getStoreCountry(
120
- rt
121
- );
122
- }
123
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_isBillingAvailable(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
124
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->isBillingAvailable(
125
- rt
126
- );
127
- }
128
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_isForwardingEnable(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
129
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->isForwardingEnable(
130
- rt,
131
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
132
- );
133
- }
134
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getCustomer(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
135
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getCustomer(
136
- rt
137
- );
138
- }
139
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSDKVersion(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
140
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getSDKVersion(
141
- rt
142
- );
143
- }
144
-
145
- NativeMobilyflowReactNativeSdkCxxSpecJSI::NativeMobilyflowReactNativeSdkCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker)
146
- : TurboModule("MobilyflowReactNativeSdk", jsInvoker) {
147
- methodMap_["initialize"] = MethodMetadata {4, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_initialize};
148
- methodMap_["close"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_close};
149
- methodMap_["login"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_login};
150
- methodMap_["logout"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_logout};
151
- methodMap_["getProducts"] = MethodMetadata {2, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getProducts};
152
- methodMap_["getSubscriptionGroups"] = MethodMetadata {2, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSubscriptionGroups};
153
- methodMap_["getSubscriptionGroupById"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSubscriptionGroupById};
154
- methodMap_["getEntitlementForSubscription"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlementForSubscription};
155
- methodMap_["getEntitlement"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlement};
156
- methodMap_["getEntitlements"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlements};
157
- methodMap_["getExternalEntitlements"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getExternalEntitlements};
158
- methodMap_["requestTransferOwnership"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_requestTransferOwnership};
159
- methodMap_["openManageSubscription"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openManageSubscription};
160
- methodMap_["openRefundDialogForProduct"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openRefundDialogForProduct};
161
- methodMap_["openRefundDialogForTransactionId"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openRefundDialogForTransactionId};
162
- methodMap_["purchaseProduct"] = MethodMetadata {2, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_purchaseProduct};
163
- methodMap_["sendDiagnostic"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_sendDiagnostic};
164
- methodMap_["getStoreCountry"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getStoreCountry};
165
- methodMap_["isBillingAvailable"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_isBillingAvailable};
166
- methodMap_["isForwardingEnable"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_isForwardingEnable};
167
- methodMap_["getCustomer"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getCustomer};
168
- methodMap_["getSDKVersion"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSDKVersion};
169
- }
170
-
171
-
172
- } // namespace facebook::react
@@ -1,5 +0,0 @@
1
- MobilyflowReactNativeSdk_kotlinVersion=2.1.0
2
- MobilyflowReactNativeSdk_minSdkVersion=24
3
- MobilyflowReactNativeSdk_targetSdkVersion=34
4
- MobilyflowReactNativeSdk_compileSdkVersion=35
5
- MobilyflowReactNativeSdk_ndkVersion=27.1.12297006
@@ -1,172 +0,0 @@
1
- /**
2
- * This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
3
- *
4
- * Do not edit this file as changes may cause incorrect behavior and will be lost
5
- * once the code is regenerated.
6
- *
7
- * @generated by codegen project: GenerateModuleCpp.js
8
- */
9
-
10
- #include "RNMobilyflowReactNativeSdkSpecJSI.h"
11
-
12
- namespace facebook::react {
13
-
14
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_initialize(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
15
- static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->initialize(
16
- rt,
17
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt),
18
- count <= 1 ? throw jsi::JSError(rt, "Expected argument in position 1 to be passed") : args[1].asString(rt),
19
- count <= 2 ? throw jsi::JSError(rt, "Expected argument in position 2 to be passed") : args[2].asString(rt),
20
- count <= 3 || args[3].isUndefined() ? std::nullopt : std::make_optional(args[3].asObject(rt))
21
- );
22
- return jsi::Value::undefined();
23
- }
24
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_close(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
25
- static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->close(
26
- rt
27
- );
28
- return jsi::Value::undefined();
29
- }
30
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_login(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
31
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->login(
32
- rt,
33
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
34
- );
35
- }
36
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_logout(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
37
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->logout(
38
- rt
39
- );
40
- }
41
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getProducts(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
42
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getProducts(
43
- rt,
44
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asObject(rt).asArray(rt),
45
- count <= 1 ? throw jsi::JSError(rt, "Expected argument in position 1 to be passed") : args[1].asBool()
46
- );
47
- }
48
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSubscriptionGroups(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
49
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getSubscriptionGroups(
50
- rt,
51
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asObject(rt).asArray(rt),
52
- count <= 1 ? throw jsi::JSError(rt, "Expected argument in position 1 to be passed") : args[1].asBool()
53
- );
54
- }
55
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSubscriptionGroupById(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
56
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getSubscriptionGroupById(
57
- rt,
58
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
59
- );
60
- }
61
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlementForSubscription(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
62
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getEntitlementForSubscription(
63
- rt,
64
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
65
- );
66
- }
67
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlement(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
68
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getEntitlement(
69
- rt,
70
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
71
- );
72
- }
73
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlements(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
74
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getEntitlements(
75
- rt,
76
- count <= 0 || args[0].isUndefined() ? std::nullopt : std::make_optional(args[0].asObject(rt).asArray(rt))
77
- );
78
- }
79
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getExternalEntitlements(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
80
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getExternalEntitlements(
81
- rt
82
- );
83
- }
84
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_requestTransferOwnership(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
85
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->requestTransferOwnership(
86
- rt
87
- );
88
- }
89
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openManageSubscription(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
90
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->openManageSubscription(
91
- rt
92
- );
93
- }
94
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openRefundDialogForProduct(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
95
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->openRefundDialogForProduct(
96
- rt,
97
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
98
- );
99
- }
100
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openRefundDialogForTransactionId(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
101
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->openRefundDialogForTransactionId(
102
- rt,
103
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
104
- );
105
- }
106
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_purchaseProduct(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
107
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->purchaseProduct(
108
- rt,
109
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt),
110
- count <= 1 || args[1].isUndefined() ? std::nullopt : std::make_optional(args[1].asObject(rt))
111
- );
112
- }
113
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_sendDiagnostic(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
114
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->sendDiagnostic(
115
- rt
116
- );
117
- }
118
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getStoreCountry(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
119
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getStoreCountry(
120
- rt
121
- );
122
- }
123
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_isBillingAvailable(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
124
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->isBillingAvailable(
125
- rt
126
- );
127
- }
128
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_isForwardingEnable(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
129
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->isForwardingEnable(
130
- rt,
131
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt)
132
- );
133
- }
134
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getCustomer(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
135
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getCustomer(
136
- rt
137
- );
138
- }
139
- static jsi::Value __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSDKVersion(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
140
- return static_cast<NativeMobilyflowReactNativeSdkCxxSpecJSI *>(&turboModule)->getSDKVersion(
141
- rt
142
- );
143
- }
144
-
145
- NativeMobilyflowReactNativeSdkCxxSpecJSI::NativeMobilyflowReactNativeSdkCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker)
146
- : TurboModule("MobilyflowReactNativeSdk", jsInvoker) {
147
- methodMap_["initialize"] = MethodMetadata {4, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_initialize};
148
- methodMap_["close"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_close};
149
- methodMap_["login"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_login};
150
- methodMap_["logout"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_logout};
151
- methodMap_["getProducts"] = MethodMetadata {2, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getProducts};
152
- methodMap_["getSubscriptionGroups"] = MethodMetadata {2, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSubscriptionGroups};
153
- methodMap_["getSubscriptionGroupById"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSubscriptionGroupById};
154
- methodMap_["getEntitlementForSubscription"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlementForSubscription};
155
- methodMap_["getEntitlement"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlement};
156
- methodMap_["getEntitlements"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getEntitlements};
157
- methodMap_["getExternalEntitlements"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getExternalEntitlements};
158
- methodMap_["requestTransferOwnership"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_requestTransferOwnership};
159
- methodMap_["openManageSubscription"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openManageSubscription};
160
- methodMap_["openRefundDialogForProduct"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openRefundDialogForProduct};
161
- methodMap_["openRefundDialogForTransactionId"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_openRefundDialogForTransactionId};
162
- methodMap_["purchaseProduct"] = MethodMetadata {2, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_purchaseProduct};
163
- methodMap_["sendDiagnostic"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_sendDiagnostic};
164
- methodMap_["getStoreCountry"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getStoreCountry};
165
- methodMap_["isBillingAvailable"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_isBillingAvailable};
166
- methodMap_["isForwardingEnable"] = MethodMetadata {1, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_isForwardingEnable};
167
- methodMap_["getCustomer"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getCustomer};
168
- methodMap_["getSDKVersion"] = MethodMetadata {0, __hostFunction_NativeMobilyflowReactNativeSdkCxxSpecJSI_getSDKVersion};
169
- }
170
-
171
-
172
- } // namespace facebook::react