capacitor-plugin-ihealth 1.1.0

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 (178) hide show
  1. package/CapacitorPluginIhealth.podspec +35 -0
  2. package/README.md +214 -0
  3. package/android/build.gradle +58 -0
  4. package/android/src/main/AndroidManifest.xml +2 -0
  5. package/android/src/main/java/com/managemyhealth/plugins/ihealth/ihealth.java +11 -0
  6. package/android/src/main/java/com/managemyhealth/plugins/ihealth/ihealthPlugin.java +22 -0
  7. package/android/src/main/res/.gitkeep +0 -0
  8. package/dist/docs.json +450 -0
  9. package/dist/esm/definitions.d.ts +29 -0
  10. package/dist/esm/definitions.js +2 -0
  11. package/dist/esm/definitions.js.map +1 -0
  12. package/dist/esm/index.d.ts +4 -0
  13. package/dist/esm/index.js +7 -0
  14. package/dist/esm/index.js.map +1 -0
  15. package/dist/esm/web.d.ts +37 -0
  16. package/dist/esm/web.js +42 -0
  17. package/dist/esm/web.js.map +1 -0
  18. package/dist/plugin.cjs.js +58 -0
  19. package/dist/plugin.cjs.js.map +1 -0
  20. package/dist/plugin.js +61 -0
  21. package/dist/plugin.js.map +1 -0
  22. package/ios/Plugin/Info.plist +24 -0
  23. package/ios/Plugin/Plugin-Bridging-Header.h +35 -0
  24. package/ios/Plugin/iHealthSDKHeaders/ABI.h +82 -0
  25. package/ios/Plugin/iHealthSDKHeaders/ABIController.h +28 -0
  26. package/ios/Plugin/iHealthSDKHeaders/ABPM.h +144 -0
  27. package/ios/Plugin/iHealthSDKHeaders/ABPMController.h +25 -0
  28. package/ios/Plugin/iHealthSDKHeaders/AM3.h +188 -0
  29. package/ios/Plugin/iHealthSDKHeaders/AM3Controller.h +29 -0
  30. package/ios/Plugin/iHealthSDKHeaders/AM3SController_V2.h +29 -0
  31. package/ios/Plugin/iHealthSDKHeaders/AM3S_V2.h +227 -0
  32. package/ios/Plugin/iHealthSDKHeaders/AM4.h +223 -0
  33. package/ios/Plugin/iHealthSDKHeaders/AM4Controller.h +31 -0
  34. package/ios/Plugin/iHealthSDKHeaders/AM5.h +335 -0
  35. package/ios/Plugin/iHealthSDKHeaders/AM5Controller.h +30 -0
  36. package/ios/Plugin/iHealthSDKHeaders/AM5Header.h +20 -0
  37. package/ios/Plugin/iHealthSDKHeaders/AMHeader.h +27 -0
  38. package/ios/Plugin/iHealthSDKHeaders/AMMacroFile.h +1171 -0
  39. package/ios/Plugin/iHealthSDKHeaders/BG1.h +53 -0
  40. package/ios/Plugin/iHealthSDKHeaders/BG1Controller.h +46 -0
  41. package/ios/Plugin/iHealthSDKHeaders/BG1S.h +64 -0
  42. package/ios/Plugin/iHealthSDKHeaders/BG1SController.h +25 -0
  43. package/ios/Plugin/iHealthSDKHeaders/BG3.h +83 -0
  44. package/ios/Plugin/iHealthSDKHeaders/BG3Controller.h +28 -0
  45. package/ios/Plugin/iHealthSDKHeaders/BG5.h +158 -0
  46. package/ios/Plugin/iHealthSDKHeaders/BG5Controller.h +28 -0
  47. package/ios/Plugin/iHealthSDKHeaders/BG5S.h +294 -0
  48. package/ios/Plugin/iHealthSDKHeaders/BG5SController.h +29 -0
  49. package/ios/Plugin/iHealthSDKHeaders/BGController.h +32 -0
  50. package/ios/Plugin/iHealthSDKHeaders/BGDevice.h +42 -0
  51. package/ios/Plugin/iHealthSDKHeaders/BGHeader.h +23 -0
  52. package/ios/Plugin/iHealthSDKHeaders/BGMacroFile.h +507 -0
  53. package/ios/Plugin/iHealthSDKHeaders/BP3.h +77 -0
  54. package/ios/Plugin/iHealthSDKHeaders/BP3Controller.h +27 -0
  55. package/ios/Plugin/iHealthSDKHeaders/BP3L.h +58 -0
  56. package/ios/Plugin/iHealthSDKHeaders/BP3LController.h +30 -0
  57. package/ios/Plugin/iHealthSDKHeaders/BP5.h +32 -0
  58. package/ios/Plugin/iHealthSDKHeaders/BP5C.h +131 -0
  59. package/ios/Plugin/iHealthSDKHeaders/BP5CController.h +25 -0
  60. package/ios/Plugin/iHealthSDKHeaders/BP5Controller.h +25 -0
  61. package/ios/Plugin/iHealthSDKHeaders/BP5S.h +97 -0
  62. package/ios/Plugin/iHealthSDKHeaders/BP5SController.h +27 -0
  63. package/ios/Plugin/iHealthSDKHeaders/BP5SRW.h +101 -0
  64. package/ios/Plugin/iHealthSDKHeaders/BP5SRWController.h +26 -0
  65. package/ios/Plugin/iHealthSDKHeaders/BP7.h +141 -0
  66. package/ios/Plugin/iHealthSDKHeaders/BP7Controller.h +25 -0
  67. package/ios/Plugin/iHealthSDKHeaders/BP7S.h +106 -0
  68. package/ios/Plugin/iHealthSDKHeaders/BP7SController.h +32 -0
  69. package/ios/Plugin/iHealthSDKHeaders/BPAV10Device.h +15 -0
  70. package/ios/Plugin/iHealthSDKHeaders/BPBTLEDevice.h +17 -0
  71. package/ios/Plugin/iHealthSDKHeaders/BPBV10Device.h +20 -0
  72. package/ios/Plugin/iHealthSDKHeaders/BPContinua.h +56 -0
  73. package/ios/Plugin/iHealthSDKHeaders/BPContinuaController.h +30 -0
  74. package/ios/Plugin/iHealthSDKHeaders/BPController.h +40 -0
  75. package/ios/Plugin/iHealthSDKHeaders/BPDevice.h +131 -0
  76. package/ios/Plugin/iHealthSDKHeaders/BPHeader.h +54 -0
  77. package/ios/Plugin/iHealthSDKHeaders/BPLoopMeasureSettingModel.h +120 -0
  78. package/ios/Plugin/iHealthSDKHeaders/BPM1AE.h +80 -0
  79. package/ios/Plugin/iHealthSDKHeaders/BPMacroFile.h +247 -0
  80. package/ios/Plugin/iHealthSDKHeaders/BPV24Device.h +16 -0
  81. package/ios/Plugin/iHealthSDKHeaders/BPV25Device.h +17 -0
  82. package/ios/Plugin/iHealthSDKHeaders/ConnectDeviceController.h +27 -0
  83. package/ios/Plugin/iHealthSDKHeaders/DFUController.h +160 -0
  84. package/ios/Plugin/iHealthSDKHeaders/DFUDeviceFirmwareInfo.h +56 -0
  85. package/ios/Plugin/iHealthSDKHeaders/DFUHeader.h +19 -0
  86. package/ios/Plugin/iHealthSDKHeaders/DFUMacro.h +264 -0
  87. package/ios/Plugin/iHealthSDKHeaders/DFUServerFirmwareInfo.h +48 -0
  88. package/ios/Plugin/iHealthSDKHeaders/ECG3.h +94 -0
  89. package/ios/Plugin/iHealthSDKHeaders/ECG3Controller.h +30 -0
  90. package/ios/Plugin/iHealthSDKHeaders/ECG3USB.h +145 -0
  91. package/ios/Plugin/iHealthSDKHeaders/ECG3USBController.h +31 -0
  92. package/ios/Plugin/iHealthSDKHeaders/ECGHeader.h +20 -0
  93. package/ios/Plugin/iHealthSDKHeaders/ECGMacroFile.h +84 -0
  94. package/ios/Plugin/iHealthSDKHeaders/HFSmartLink.h +88 -0
  95. package/ios/Plugin/iHealthSDKHeaders/HFSmartLinkDeviceInfo.h +14 -0
  96. package/ios/Plugin/iHealthSDKHeaders/HS2.h +64 -0
  97. package/ios/Plugin/iHealthSDKHeaders/HS2Controller.h +25 -0
  98. package/ios/Plugin/iHealthSDKHeaders/HS2S.h +399 -0
  99. package/ios/Plugin/iHealthSDKHeaders/HS2SController.h +27 -0
  100. package/ios/Plugin/iHealthSDKHeaders/HS3.h +63 -0
  101. package/ios/Plugin/iHealthSDKHeaders/HS3Controller.h +32 -0
  102. package/ios/Plugin/iHealthSDKHeaders/HS4.h +64 -0
  103. package/ios/Plugin/iHealthSDKHeaders/HS4Controller.h +26 -0
  104. package/ios/Plugin/iHealthSDKHeaders/HS5.h +141 -0
  105. package/ios/Plugin/iHealthSDKHeaders/HS5Controller.h +38 -0
  106. package/ios/Plugin/iHealthSDKHeaders/HSHeader.h +25 -0
  107. package/ios/Plugin/iHealthSDKHeaders/HSMacroFile.h +709 -0
  108. package/ios/Plugin/iHealthSDKHeaders/HealthHeader.h +67 -0
  109. package/ios/Plugin/iHealthSDKHeaders/HealthUser.h +126 -0
  110. package/ios/Plugin/iHealthSDKHeaders/IDOBindEnum.h +49 -0
  111. package/ios/Plugin/iHealthSDKHeaders/IDOBlueDataResponse.h +66 -0
  112. package/ios/Plugin/iHealthSDKHeaders/IDOBlueEnum.h +213 -0
  113. package/ios/Plugin/iHealthSDKHeaders/IDOBluetoothBaseModel.h +112 -0
  114. package/ios/Plugin/iHealthSDKHeaders/IDOBluetoothEngine.h +283 -0
  115. package/ios/Plugin/iHealthSDKHeaders/IDOBluetoothManager.h +166 -0
  116. package/ios/Plugin/iHealthSDKHeaders/IDOBluetoothServices.h +75 -0
  117. package/ios/Plugin/iHealthSDKHeaders/IDOCalculateBluetoothModel.h +263 -0
  118. package/ios/Plugin/iHealthSDKHeaders/IDOCommonMacro.h +89 -0
  119. package/ios/Plugin/iHealthSDKHeaders/IDODataExchangeModel.h +128 -0
  120. package/ios/Plugin/iHealthSDKHeaders/IDODataMigrationManager.h +79 -0
  121. package/ios/Plugin/iHealthSDKHeaders/IDOErrorCodeToStr.h +19 -0
  122. package/ios/Plugin/iHealthSDKHeaders/IDOFoundationCommand.h +1178 -0
  123. package/ios/Plugin/iHealthSDKHeaders/IDOGetInfoBluetoothModel.h +1924 -0
  124. package/ios/Plugin/iHealthSDKHeaders/IDOLogEnum.h +165 -0
  125. package/ios/Plugin/iHealthSDKHeaders/IDOPeripheralModel.h +59 -0
  126. package/ios/Plugin/iHealthSDKHeaders/IDORecordDeviceLog.h +56 -0
  127. package/ios/Plugin/iHealthSDKHeaders/IDOSetInfoBluetoothModel.h +1760 -0
  128. package/ios/Plugin/iHealthSDKHeaders/IDOSyncActivityDataModel.h +207 -0
  129. package/ios/Plugin/iHealthSDKHeaders/IDOSyncBpDataModel.h +191 -0
  130. package/ios/Plugin/iHealthSDKHeaders/IDOSyncEnum.h +316 -0
  131. package/ios/Plugin/iHealthSDKHeaders/IDOSyncGpsDataModel.h +133 -0
  132. package/ios/Plugin/iHealthSDKHeaders/IDOSyncHeartRateDataModel.h +442 -0
  133. package/ios/Plugin/iHealthSDKHeaders/IDOSyncManager.h +161 -0
  134. package/ios/Plugin/iHealthSDKHeaders/IDOSyncPressureDataModel.h +158 -0
  135. package/ios/Plugin/iHealthSDKHeaders/IDOSyncSleepDataModel.h +224 -0
  136. package/ios/Plugin/iHealthSDKHeaders/IDOSyncSpo2DataModel.h +175 -0
  137. package/ios/Plugin/iHealthSDKHeaders/IDOSyncSportDataModel.h +221 -0
  138. package/ios/Plugin/iHealthSDKHeaders/IDOSyncSwimDataModel.h +188 -0
  139. package/ios/Plugin/iHealthSDKHeaders/IDOTranEnum.h +93 -0
  140. package/ios/Plugin/iHealthSDKHeaders/IDOTransferFileManager.h +116 -0
  141. package/ios/Plugin/iHealthSDKHeaders/IDOWatchDialInfoModel.h +95 -0
  142. package/ios/Plugin/iHealthSDKHeaders/IDOWatchDialManager.h +75 -0
  143. package/ios/Plugin/iHealthSDKHeaders/IDOWeightBluetoothModel.h +124 -0
  144. package/ios/Plugin/iHealthSDKHeaders/IHSDKCloudUser.h +104 -0
  145. package/ios/Plugin/iHealthSDKHeaders/KN550BT.h +115 -0
  146. package/ios/Plugin/iHealthSDKHeaders/KN550BTController.h +32 -0
  147. package/ios/Plugin/iHealthSDKHeaders/ManageDeviceController.h +34 -0
  148. package/ios/Plugin/iHealthSDKHeaders/NT13B.h +33 -0
  149. package/ios/Plugin/iHealthSDKHeaders/NT13BController.h +28 -0
  150. package/ios/Plugin/iHealthSDKHeaders/NT13BHeader.h +16 -0
  151. package/ios/Plugin/iHealthSDKHeaders/NT13BMacroFile.h +34 -0
  152. package/ios/Plugin/iHealthSDKHeaders/PO1.h +82 -0
  153. package/ios/Plugin/iHealthSDKHeaders/PO1Controller.h +29 -0
  154. package/ios/Plugin/iHealthSDKHeaders/PO3.h +96 -0
  155. package/ios/Plugin/iHealthSDKHeaders/PO3Controller.h +29 -0
  156. package/ios/Plugin/iHealthSDKHeaders/POHeader.h +20 -0
  157. package/ios/Plugin/iHealthSDKHeaders/POMacroFile.h +142 -0
  158. package/ios/Plugin/iHealthSDKHeaders/PT3SBT.h +167 -0
  159. package/ios/Plugin/iHealthSDKHeaders/PT3SBTController.h +27 -0
  160. package/ios/Plugin/iHealthSDKHeaders/PT3SBTMacroFile.h +92 -0
  161. package/ios/Plugin/iHealthSDKHeaders/SDKFlowUpdateDevice.h +196 -0
  162. package/ios/Plugin/iHealthSDKHeaders/SDKInfo.h +30 -0
  163. package/ios/Plugin/iHealthSDKHeaders/SDKUpdateDevice.h +235 -0
  164. package/ios/Plugin/iHealthSDKHeaders/ScanDeviceController.h +47 -0
  165. package/ios/Plugin/iHealthSDKHeaders/THV3.h +104 -0
  166. package/ios/Plugin/iHealthSDKHeaders/THV3Controller.h +30 -0
  167. package/ios/Plugin/iHealthSDKHeaders/THV3Macro.h +17 -0
  168. package/ios/Plugin/iHealthSDKHeaders/TS28B.h +26 -0
  169. package/ios/Plugin/iHealthSDKHeaders/TS28BController.h +142 -0
  170. package/ios/Plugin/iHealthSDKHeaders/TS28BHeader.h +15 -0
  171. package/ios/Plugin/iHealthSDKHeaders/iHealthHS6.h +174 -0
  172. package/ios/Plugin/ihealth.swift +8 -0
  173. package/ios/Plugin/ihealthPlugin.h +10 -0
  174. package/ios/Plugin/ihealthPlugin.m +16 -0
  175. package/ios/Plugin/ihealthPlugin.swift +1502 -0
  176. package/ios/Plugin/libiHealthSDK2.7.8.a +0 -0
  177. package/ios/Plugin/test.m +9 -0
  178. package/package.json +78 -0
@@ -0,0 +1,35 @@
1
+ require 'json'
2
+
3
+ package = JSON.parse(File.read(File.join(__dir__, 'package.json')))
4
+
5
+ Pod::Spec.new do |s|
6
+ s.name = 'CapacitorPluginIhealth'
7
+ s.version = package['version']
8
+ s.summary = package['description']
9
+ s.license = package['license']
10
+ s.homepage = package['repository']['url']
11
+ s.author = package['author']
12
+
13
+ s.source = { :http => 'https://github.com/vamsi3293/capacitor-plugin-ihealth/releases/tag/0.0.2/iHealthSDK2.7.8.a' }
14
+ # s.source = { :git => package['repository']['url'], :tag => s.version.to_s }
15
+ s.source_files = 'ios/Plugin/**/*.{swift,h,m,c,cc,mm,cpp}','ios/Plugin/libiHealthSDK2.7.8.a'
16
+ s.ios.deployment_target = '13.0'
17
+ s.dependency 'Capacitor'
18
+ s.swift_version = '5.1'
19
+ # s.vendored_frameworks = 'iHealthSDK2.7.8.a'
20
+ s.ios.vendored_library = 'ios/Plugin/libiHealthSDK2.7.8.a'
21
+ # s.vendored_library = 'ios/Pods/Frameworks/iHealthSDK2.7.8.a'
22
+ s.preserve_paths = 'ios/Plugin/libiHealthSDK2.7.8.a'
23
+ # s.prepare_command = <<-CMD
24
+ # if [ -f $PWD/ios/Plugin/libiHealthSDK2.7.8.a ]
25
+ # then
26
+ # rm -rf $PWD/ios/Plugin/libiHealthSDK2.7.8.a
27
+ # fi
28
+ # ln -sf $PWD/ios/Plugin/iHealthSDK2.7.8.a $PWD/ios/Plugin/libiHealthSDK2.7.8.a
29
+ # CMD
30
+ s.libraries = 'c++','iHealthSDK2.7.8'
31
+ # s.xcconfig = { 'LIBRARY_SEARCH_PATHS' => '"$(PROJECT_DIR)/","$(PROJECT_DIR)/ios/Plugin/","$(PROJECT_DIR)/"' }
32
+ # s.resource = 'ios/Pods/YourResourceFolder/YourBundle.bundle'
33
+ # s.xcconfig = {'ENABLE_BITCODE' => 'NO'}
34
+ # s.xcconfig = { 'LIBRARY_SEARCH_PATHS' => 'ios/Pods/Frameworks/' }
35
+ end
package/README.md ADDED
@@ -0,0 +1,214 @@
1
+ # capacitor-plugin-ihealth
2
+
3
+ capacitor plugin to integrate ihealth sdk
4
+
5
+ ## Install
6
+
7
+ ```bash
8
+ npm install capacitor-plugin-ihealth
9
+ npx cap sync
10
+ ```
11
+
12
+ ## API
13
+
14
+ <docgen-index>
15
+
16
+ * [`authoriseiHealthSdk()`](#authoriseihealthsdk)
17
+ * [`isBluetoothEnabled()`](#isbluetoothenabled)
18
+ * [`initialiseCentralManager()`](#initialisecentralmanager)
19
+ * [`scanDiscover(...)`](#scandiscover)
20
+ * [`connectDevice(...)`](#connectdevice)
21
+ * [`getConnectedDeviceInstance(...)`](#getconnecteddeviceinstance)
22
+ * [`disconnectDevice()`](#disconnectdevice)
23
+ * [`deleteDeviceData()`](#deletedevicedata)
24
+ * [`getDeviceOfflineData()`](#getdeviceofflinedata)
25
+ * [`addListener([eventName: 'OnlineDeviceData', listenerFunc: (info: any) => void] | [eventName: 'error', listenerFunc: (info: any) => void] | [eventName: 'deviceDatafound', listenerFunc: (info: any) => void] | [eventName: 'dataNotFound', listenerFunc: (info: any) => void] | [eventName: 'deviceConnectFail', listenerFunc: (info: any) => void] | [eventName: 'deviceDisconnect', listenerFunc: (info: any) => void] | [eventName: 'deviceDiscover', listenerFunc: (info: any) => void] | [eventName: 'deviceConnect', listenerFunc: (info: any) => void], ...)`](#addlistenereventname-onlinedevicedata-listenerfunc-info-any--void--eventname-error-listenerfunc-info-any--void--eventname-devicedatafound-listenerfunc-info-any--void--eventname-datanotfound-listenerfunc-info-any--void--eventname-deviceconnectfail-listenerfunc-info-any--void--eventname-devicedisconnect-listenerfunc-info-any--void--eventname-devicediscover-listenerfunc-info-any--void--eventname-deviceconnect-listenerfunc-info-any--void)
26
+ * [Interfaces](#interfaces)
27
+ * [Type Aliases](#type-aliases)
28
+
29
+ </docgen-index>
30
+
31
+ <docgen-api>
32
+ <!--Update the source file JSDoc comments and rerun docgen to update the docs below-->
33
+
34
+ ### authoriseiHealthSdk()
35
+
36
+ ```typescript
37
+ authoriseiHealthSdk() => Promise<{ value: any; }>
38
+ ```
39
+
40
+ **Returns:** <code>Promise&lt;{ value: any; }&gt;</code>
41
+
42
+ --------------------
43
+
44
+
45
+ ### isBluetoothEnabled()
46
+
47
+ ```typescript
48
+ isBluetoothEnabled() => Promise<{ value: any; }>
49
+ ```
50
+
51
+ **Returns:** <code>Promise&lt;{ value: any; }&gt;</code>
52
+
53
+ --------------------
54
+
55
+
56
+ ### initialiseCentralManager()
57
+
58
+ ```typescript
59
+ initialiseCentralManager() => Promise<{ value: any; }>
60
+ ```
61
+
62
+ **Returns:** <code>Promise&lt;{ value: any; }&gt;</code>
63
+
64
+ --------------------
65
+
66
+
67
+ ### scanDiscover(...)
68
+
69
+ ```typescript
70
+ scanDiscover(options: Object) => Promise<{ value: any; }>
71
+ ```
72
+
73
+ | Param | Type |
74
+ | ------------- | ----------------------------------------- |
75
+ | **`options`** | <code><a href="#object">Object</a></code> |
76
+
77
+ **Returns:** <code>Promise&lt;{ value: any; }&gt;</code>
78
+
79
+ --------------------
80
+
81
+
82
+ ### connectDevice(...)
83
+
84
+ ```typescript
85
+ connectDevice(options: Object) => Promise<any>
86
+ ```
87
+
88
+ | Param | Type |
89
+ | ------------- | ----------------------------------------- |
90
+ | **`options`** | <code><a href="#object">Object</a></code> |
91
+
92
+ **Returns:** <code>Promise&lt;any&gt;</code>
93
+
94
+ --------------------
95
+
96
+
97
+ ### getConnectedDeviceInstance(...)
98
+
99
+ ```typescript
100
+ getConnectedDeviceInstance(options: Object) => Promise<{ value: any; }>
101
+ ```
102
+
103
+ | Param | Type |
104
+ | ------------- | ----------------------------------------- |
105
+ | **`options`** | <code><a href="#object">Object</a></code> |
106
+
107
+ **Returns:** <code>Promise&lt;{ value: any; }&gt;</code>
108
+
109
+ --------------------
110
+
111
+
112
+ ### disconnectDevice()
113
+
114
+ ```typescript
115
+ disconnectDevice() => Promise<{ value: any; }>
116
+ ```
117
+
118
+ **Returns:** <code>Promise&lt;{ value: any; }&gt;</code>
119
+
120
+ --------------------
121
+
122
+
123
+ ### deleteDeviceData()
124
+
125
+ ```typescript
126
+ deleteDeviceData() => Promise<{ value: any; }>
127
+ ```
128
+
129
+ **Returns:** <code>Promise&lt;{ value: any; }&gt;</code>
130
+
131
+ --------------------
132
+
133
+
134
+ ### getDeviceOfflineData()
135
+
136
+ ```typescript
137
+ getDeviceOfflineData() => Promise<{ value: any; }>
138
+ ```
139
+
140
+ **Returns:** <code>Promise&lt;{ value: any; }&gt;</code>
141
+
142
+ --------------------
143
+
144
+
145
+ ### addListener([eventName: 'OnlineDeviceData', listenerFunc: (info: any) => void] | [eventName: 'error', listenerFunc: (info: any) => void] | [eventName: 'deviceDatafound', listenerFunc: (info: any) => void] | [eventName: 'dataNotFound', listenerFunc: (info: any) => void] | [eventName: 'deviceConnectFail', listenerFunc: (info: any) => void] | [eventName: 'deviceDisconnect', listenerFunc: (info: any) => void] | [eventName: 'deviceDiscover', listenerFunc: (info: any) => void] | [eventName: 'deviceConnect', listenerFunc: (info: any) => void], ...)
146
+
147
+ ```typescript
148
+ addListener(...args: [eventName: "OnlineDeviceData", listenerFunc: (info: any) => void] | [eventName: "error", listenerFunc: (info: any) => void] | [eventName: "deviceDatafound", listenerFunc: (info: any) => void] | [eventName: "dataNotFound", listenerFunc: (info: any) => void] | [eventName: "deviceConnectFail", listenerFunc: (info: any) => void] | [eventName: "deviceDisconnect", listenerFunc: (info: any) => void] | [eventName: "deviceDiscover", listenerFunc: (info: any) => void] | [eventName: "deviceConnect", listenerFunc: (info: any) => void]) => Promise<PluginListenerHandle> & PluginListenerHandle
149
+ ```
150
+
151
+ | Param | Type |
152
+ | ---------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
153
+ | **`args`** | <code>[eventName: 'OnlineDeviceData', listenerFunc: (info: any) =&gt; void] \| [eventName: 'error', listenerFunc: (info: any) =&gt; void] \| [eventName: 'deviceDatafound', listenerFunc: (info: any) =&gt; void] \| [eventName: 'dataNotFound', listenerFunc: (info: any) =&gt; void] \| [eventName: 'deviceConnectFail', listenerFunc: (info: any) =&gt; void] \| [eventName: 'deviceDisconnect', listenerFunc: (info: any) =&gt; void] \| [eventName: 'deviceDiscover', listenerFunc: (info: any) =&gt; void] \| [eventName: 'deviceConnect', listenerFunc: (info: any) =&gt; void]</code> |
154
+
155
+ **Returns:** <code>Promise&lt;<a href="#pluginlistenerhandle">PluginListenerHandle</a>&gt; & <a href="#pluginlistenerhandle">PluginListenerHandle</a></code>
156
+
157
+ --------------------
158
+
159
+
160
+ ### Interfaces
161
+
162
+
163
+ #### Object
164
+
165
+ Provides functionality common to all JavaScript objects.
166
+
167
+ | Prop | Type | Description |
168
+ | ----------------- | --------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
169
+ | **`constructor`** | <code><a href="#function">Function</a></code> | The initial value of <a href="#object">Object</a>.prototype.constructor is the standard built-in <a href="#object">Object</a> constructor. |
170
+
171
+ | Method | Signature | Description |
172
+ | ------------------------ | --------------------------------------------------------- | ------------------------------------------------------------------------ |
173
+ | **toString** | () =&gt; string | Returns a string representation of an object. |
174
+ | **toLocaleString** | () =&gt; string | Returns a date converted to a string using the current locale. |
175
+ | **valueOf** | () =&gt; <a href="#object">Object</a> | Returns the primitive value of the specified object. |
176
+ | **hasOwnProperty** | (v: <a href="#propertykey">PropertyKey</a>) =&gt; boolean | Determines whether an object has a property with the specified name. |
177
+ | **isPrototypeOf** | (v: <a href="#object">Object</a>) =&gt; boolean | Determines whether an object exists in another object's prototype chain. |
178
+ | **propertyIsEnumerable** | (v: <a href="#propertykey">PropertyKey</a>) =&gt; boolean | Determines whether a specified property is enumerable. |
179
+
180
+
181
+ #### Function
182
+
183
+ Creates a new function.
184
+
185
+ | Prop | Type |
186
+ | --------------- | --------------------------------------------- |
187
+ | **`prototype`** | <code>any</code> |
188
+ | **`length`** | <code>number</code> |
189
+ | **`arguments`** | <code>any</code> |
190
+ | **`caller`** | <code><a href="#function">Function</a></code> |
191
+
192
+ | Method | Signature | Description |
193
+ | ------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
194
+ | **apply** | (this: <a href="#function">Function</a>, thisArg: any, argArray?: any) =&gt; any | Calls the function, substituting the specified object for the this value of the function, and the specified array for the arguments of the function. |
195
+ | **call** | (this: <a href="#function">Function</a>, thisArg: any, ...argArray: any[]) =&gt; any | Calls a method of an object, substituting another object for the current object. |
196
+ | **bind** | (this: <a href="#function">Function</a>, thisArg: any, ...argArray: any[]) =&gt; any | For a given function, creates a bound function that has the same body as the original function. The this object of the bound function is associated with the specified object, and has the specified initial parameters. |
197
+ | **toString** | () =&gt; string | Returns a string representation of a function. |
198
+
199
+
200
+ #### PluginListenerHandle
201
+
202
+ | Prop | Type |
203
+ | ------------ | ----------------------------------------- |
204
+ | **`remove`** | <code>() =&gt; Promise&lt;void&gt;</code> |
205
+
206
+
207
+ ### Type Aliases
208
+
209
+
210
+ #### PropertyKey
211
+
212
+ <code>string | number | symbol</code>
213
+
214
+ </docgen-api>
@@ -0,0 +1,58 @@
1
+ ext {
2
+ junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
3
+ androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.6.1'
4
+ androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.1.5'
5
+ androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.5.1'
6
+ }
7
+
8
+ buildscript {
9
+ repositories {
10
+ google()
11
+ mavenCentral()
12
+ }
13
+ dependencies {
14
+ classpath 'com.android.tools.build:gradle:8.0.0'
15
+ }
16
+ }
17
+
18
+ apply plugin: 'com.android.library'
19
+
20
+ android {
21
+ namespace "com.managemyhealth.plugins.ihealth"
22
+ compileSdkVersion project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 33
23
+ defaultConfig {
24
+ minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 22
25
+ targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 33
26
+ versionCode 1
27
+ versionName "1.0"
28
+ testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
29
+ }
30
+ buildTypes {
31
+ release {
32
+ minifyEnabled false
33
+ proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
34
+ }
35
+ }
36
+ lintOptions {
37
+ abortOnError false
38
+ }
39
+ compileOptions {
40
+ sourceCompatibility JavaVersion.VERSION_17
41
+ targetCompatibility JavaVersion.VERSION_17
42
+ }
43
+ }
44
+
45
+ repositories {
46
+ google()
47
+ mavenCentral()
48
+ }
49
+
50
+
51
+ dependencies {
52
+ implementation fileTree(dir: 'libs', include: ['*.jar'])
53
+ implementation project(':capacitor-android')
54
+ implementation "androidx.appcompat:appcompat:$androidxAppCompatVersion"
55
+ testImplementation "junit:junit:$junitVersion"
56
+ androidTestImplementation "androidx.test.ext:junit:$androidxJunitVersion"
57
+ androidTestImplementation "androidx.test.espresso:espresso-core:$androidxEspressoCoreVersion"
58
+ }
@@ -0,0 +1,2 @@
1
+ <manifest xmlns:android="http://schemas.android.com/apk/res/android">
2
+ </manifest>
@@ -0,0 +1,11 @@
1
+ package com.managemyhealth.plugins.ihealth;
2
+
3
+ import android.util.Log;
4
+
5
+ public class ihealth {
6
+
7
+ public String echo(String value) {
8
+ Log.i("Echo", value);
9
+ return value;
10
+ }
11
+ }
@@ -0,0 +1,22 @@
1
+ package com.managemyhealth.plugins.ihealth;
2
+
3
+ import com.getcapacitor.JSObject;
4
+ import com.getcapacitor.Plugin;
5
+ import com.getcapacitor.PluginCall;
6
+ import com.getcapacitor.PluginMethod;
7
+ import com.getcapacitor.annotation.CapacitorPlugin;
8
+
9
+ @CapacitorPlugin(name = "ihealth")
10
+ public class ihealthPlugin extends Plugin {
11
+
12
+ private ihealth implementation = new ihealth();
13
+
14
+ @PluginMethod
15
+ public void echo(PluginCall call) {
16
+ String value = call.getString("value");
17
+
18
+ JSObject ret = new JSObject();
19
+ ret.put("value", implementation.echo(value));
20
+ call.resolve(ret);
21
+ }
22
+ }
File without changes