react-native-ble-nitro 1.0.0-beta.9 → 1.0.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.
- package/BleNitro.podspec +39 -0
- package/LICENSE +1 -1
- package/README.md +273 -77
- package/ios/BleNitroBleManager.swift +426 -458
- package/ios/BlePeripheralDelegate.swift +174 -0
- package/lib/commonjs/index.d.ts +174 -10
- package/lib/commonjs/index.d.ts.map +1 -1
- package/lib/commonjs/index.js +461 -38
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/specs/NativeBleNitro.d.ts +5 -0
- package/lib/commonjs/specs/NativeBleNitro.d.ts.map +1 -0
- package/lib/commonjs/{utils/index.js → specs/NativeBleNitro.js} +6 -3
- package/lib/commonjs/specs/NativeBleNitro.js.map +1 -0
- package/lib/commonjs/specs/NativeBleNitro.nitro.d.ts +69 -0
- package/lib/commonjs/specs/NativeBleNitro.nitro.d.ts.map +1 -0
- package/lib/commonjs/specs/NativeBleNitro.nitro.js +14 -0
- package/lib/commonjs/specs/NativeBleNitro.nitro.js.map +1 -0
- package/lib/index.d.ts +174 -10
- package/lib/index.js +456 -16
- package/lib/specs/NativeBleNitro.d.ts +4 -0
- package/lib/specs/NativeBleNitro.js +5 -0
- package/lib/specs/NativeBleNitro.nitro.d.ts +68 -0
- package/lib/specs/NativeBleNitro.nitro.js +10 -0
- package/nitro.json +1 -1
- package/nitrogen/generated/android/BleNitro+autolinking.cmake +2 -10
- package/nitrogen/generated/android/BleNitroOnLoad.cpp +25 -22
- package/nitrogen/generated/android/c++/JBLEDevice.hpp +95 -0
- package/nitrogen/generated/android/c++/{JState.hpp → JBLEState.hpp} +22 -22
- package/nitrogen/generated/android/c++/JFunc_void_BLEDevice.hpp +82 -0
- package/nitrogen/generated/android/c++/JFunc_void_BLEState.hpp +76 -0
- package/nitrogen/generated/android/c++/JFunc_void_bool.hpp +74 -0
- package/nitrogen/generated/android/c++/JFunc_void_bool_std__string.hpp +75 -0
- package/nitrogen/generated/android/c++/JFunc_void_bool_std__string_std__string.hpp +75 -0
- package/nitrogen/generated/android/c++/JFunc_void_bool_std__vector_double__std__string.hpp +86 -0
- package/nitrogen/generated/android/c++/JFunc_void_std__string_bool_std__string.hpp +75 -0
- package/nitrogen/generated/android/c++/JFunc_void_std__string_std__vector_double_.hpp +86 -0
- package/nitrogen/generated/android/c++/JFunc_void_std__vector_BLEDevice_.hpp +99 -0
- package/nitrogen/generated/android/c++/JFunc_void_std__vector_std__string_.hpp +93 -0
- package/nitrogen/generated/android/c++/JHybridNativeBleNitroSpec.cpp +171 -0
- package/nitrogen/generated/android/c++/JHybridNativeBleNitroSpec.hpp +83 -0
- package/nitrogen/generated/android/c++/JManufacturerData.hpp +73 -0
- package/nitrogen/generated/android/c++/JManufacturerDataEntry.hpp +68 -0
- package/nitrogen/generated/android/c++/JScanFilter.hpp +79 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/BLEDevice.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/{LogLevel.kt → BLEState.kt} +9 -13
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/{Func_void_std__optional_NativeBleError__std__optional_NativeDevice_.kt → Func_void_BLEDevice.kt} +15 -14
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/{Func_void.kt → Func_void_BLEState.kt} +15 -14
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/{Func_void_State.kt → Func_void_bool.kt} +15 -14
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/{Func_void_std__optional_NativeBleError__std__optional_NativeCharacteristic_.kt → Func_void_bool_std__string.kt} +15 -14
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/Func_void_bool_std__string_std__string.kt +81 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/Func_void_bool_std__vector_double__std__string.kt +81 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/Func_void_std__string_bool_std__string.kt +81 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/Func_void_std__string_std__vector_double_.kt +81 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/Func_void_std__vector_BLEDevice_.kt +81 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/Func_void_std__vector_std__string_.kt +81 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/HybridNativeBleNitroSpec.kt +223 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/{ServiceDataEntry.kt → ManufacturerData.kt} +7 -5
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/{ConnectionOptions.kt → ManufacturerDataEntry.kt} +10 -6
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/{NativeService.kt → ScanFilter.kt} +13 -7
- package/nitrogen/generated/ios/BleNitro-Swift-Cxx-Bridge.cpp +67 -175
- package/nitrogen/generated/ios/BleNitro-Swift-Cxx-Bridge.hpp +205 -867
- package/nitrogen/generated/ios/BleNitro-Swift-Cxx-Umbrella.hpp +20 -88
- package/nitrogen/generated/ios/BleNitroAutolinking.mm +3 -3
- package/nitrogen/generated/ios/BleNitroAutolinking.swift +4 -4
- package/nitrogen/generated/ios/c++/{HybridCharacteristicSpecSwift.cpp → HybridNativeBleNitroSpecSwift.cpp} +2 -2
- package/nitrogen/generated/ios/c++/HybridNativeBleNitroSpecSwift.hpp +205 -0
- package/nitrogen/generated/ios/swift/BLEDevice.swift +102 -0
- package/nitrogen/generated/ios/swift/{State.swift → BLEState.swift} +6 -6
- package/nitrogen/generated/ios/swift/Func_void.swift +1 -0
- package/nitrogen/generated/ios/swift/{Func_void_State.swift → Func_void_BLEDevice.swift} +12 -11
- package/nitrogen/generated/ios/swift/{Func_void_LogLevel.swift → Func_void_BLEState.swift} +12 -11
- package/nitrogen/generated/ios/swift/Func_void_bool.swift +6 -5
- package/nitrogen/generated/ios/swift/{Func_void_NativeDescriptor.swift → Func_void_bool_std__string.swift} +12 -11
- package/nitrogen/generated/ios/swift/{Func_void_std__vector_NativeCharacteristic_.swift → Func_void_bool_std__string_std__string.swift} +12 -11
- package/nitrogen/generated/ios/swift/Func_void_bool_std__vector_double__std__string.swift +47 -0
- package/nitrogen/generated/ios/swift/Func_void_std__exception_ptr.swift +1 -0
- package/nitrogen/generated/ios/swift/{Func_void_NativeDevice.swift → Func_void_std__string_bool_std__string.swift} +12 -11
- package/nitrogen/generated/ios/swift/{Func_void_std__optional_BleRestoredState_.swift → Func_void_std__string_std__vector_double_.swift} +12 -17
- package/nitrogen/generated/ios/swift/{Func_void_NativeCharacteristic.swift → Func_void_std__vector_BLEDevice_.swift} +12 -11
- package/nitrogen/generated/ios/swift/{Func_void_std__vector_NativeDevice_.swift → Func_void_std__vector_std__string_.swift} +12 -11
- package/nitrogen/generated/ios/swift/HybridNativeBleNitroSpec.swift +68 -0
- package/nitrogen/generated/ios/swift/HybridNativeBleNitroSpec_cxx.swift +485 -0
- package/nitrogen/generated/ios/swift/ManufacturerData.swift +47 -0
- package/nitrogen/generated/ios/swift/ManufacturerDataEntry.swift +58 -0
- package/nitrogen/generated/ios/swift/ScanFilter.swift +69 -0
- package/nitrogen/generated/shared/c++/BLEDevice.hpp +90 -0
- package/nitrogen/generated/shared/c++/{State.hpp → BLEState.hpp} +13 -15
- package/nitrogen/generated/shared/c++/HybridNativeBleNitroSpec.cpp +40 -0
- package/nitrogen/generated/shared/c++/HybridNativeBleNitroSpec.hpp +93 -0
- package/nitrogen/generated/shared/c++/ManufacturerData.hpp +69 -0
- package/nitrogen/generated/shared/c++/{ServiceDataEntry.hpp → ManufacturerDataEntry.hpp} +19 -20
- package/nitrogen/generated/shared/c++/ScanFilter.hpp +76 -0
- package/package.json +9 -11
- package/react-native.config.js +2 -7
- package/src/__tests__/index.test.ts +188 -0
- package/src/index.ts +604 -45
- package/src/specs/NativeBleNitro.nitro.ts +84 -0
- package/src/specs/NativeBleNitro.ts +8 -0
- package/android/build.gradle +0 -58
- package/android/src/main/AndroidManifest.xml +0 -23
- package/android/src/main/kotlin/com/margelo/nitro/co/zyke/ble/BleNitroBleManager.kt +0 -760
- package/ios/BleNitro.podspec +0 -44
- package/ios/BleNitroModule.swift +0 -24
- package/lib/BleManagerCompatFactory.d.ts +0 -55
- package/lib/BleManagerCompatFactory.js +0 -194
- package/lib/BleManagerFactory.d.ts +0 -30
- package/lib/BleManagerFactory.js +0 -73
- package/lib/commonjs/BleManagerCompatFactory.d.ts +0 -56
- package/lib/commonjs/BleManagerCompatFactory.d.ts.map +0 -1
- package/lib/commonjs/BleManagerCompatFactory.js +0 -201
- package/lib/commonjs/BleManagerCompatFactory.js.map +0 -1
- package/lib/commonjs/BleManagerFactory.d.ts +0 -31
- package/lib/commonjs/BleManagerFactory.d.ts.map +0 -1
- package/lib/commonjs/BleManagerFactory.js +0 -81
- package/lib/commonjs/BleManagerFactory.js.map +0 -1
- package/lib/commonjs/compatibility/constants.d.ts +0 -50
- package/lib/commonjs/compatibility/constants.d.ts.map +0 -1
- package/lib/commonjs/compatibility/constants.js +0 -58
- package/lib/commonjs/compatibility/constants.js.map +0 -1
- package/lib/commonjs/compatibility/deviceWrapper.d.ts +0 -100
- package/lib/commonjs/compatibility/deviceWrapper.d.ts.map +0 -1
- package/lib/commonjs/compatibility/deviceWrapper.js +0 -268
- package/lib/commonjs/compatibility/deviceWrapper.js.map +0 -1
- package/lib/commonjs/compatibility/enums.d.ts +0 -39
- package/lib/commonjs/compatibility/enums.d.ts.map +0 -1
- package/lib/commonjs/compatibility/enums.js +0 -179
- package/lib/commonjs/compatibility/enums.js.map +0 -1
- package/lib/commonjs/compatibility/index.d.ts +0 -13
- package/lib/commonjs/compatibility/index.d.ts.map +0 -1
- package/lib/commonjs/compatibility/index.js +0 -41
- package/lib/commonjs/compatibility/index.js.map +0 -1
- package/lib/commonjs/compatibility/serviceData.d.ts +0 -52
- package/lib/commonjs/compatibility/serviceData.d.ts.map +0 -1
- package/lib/commonjs/compatibility/serviceData.js +0 -80
- package/lib/commonjs/compatibility/serviceData.js.map +0 -1
- package/lib/commonjs/errors/BleError.d.ts +0 -60
- package/lib/commonjs/errors/BleError.d.ts.map +0 -1
- package/lib/commonjs/errors/BleError.js +0 -125
- package/lib/commonjs/errors/BleError.js.map +0 -1
- package/lib/commonjs/specs/BleManager.nitro.d.ts +0 -45
- package/lib/commonjs/specs/BleManager.nitro.d.ts.map +0 -1
- package/lib/commonjs/specs/BleManager.nitro.js +0 -3
- package/lib/commonjs/specs/BleManager.nitro.js.map +0 -1
- package/lib/commonjs/specs/Characteristic.nitro.d.ts +0 -27
- package/lib/commonjs/specs/Characteristic.nitro.d.ts.map +0 -1
- package/lib/commonjs/specs/Characteristic.nitro.js +0 -3
- package/lib/commonjs/specs/Characteristic.nitro.js.map +0 -1
- package/lib/commonjs/specs/Descriptor.nitro.d.ts +0 -18
- package/lib/commonjs/specs/Descriptor.nitro.d.ts.map +0 -1
- package/lib/commonjs/specs/Descriptor.nitro.js +0 -3
- package/lib/commonjs/specs/Descriptor.nitro.js.map +0 -1
- package/lib/commonjs/specs/Device.nitro.d.ts +0 -38
- package/lib/commonjs/specs/Device.nitro.d.ts.map +0 -1
- package/lib/commonjs/specs/Device.nitro.js +0 -3
- package/lib/commonjs/specs/Device.nitro.js.map +0 -1
- package/lib/commonjs/specs/Service.nitro.d.ts +0 -20
- package/lib/commonjs/specs/Service.nitro.d.ts.map +0 -1
- package/lib/commonjs/specs/Service.nitro.js +0 -3
- package/lib/commonjs/specs/Service.nitro.js.map +0 -1
- package/lib/commonjs/specs/types.d.ts +0 -229
- package/lib/commonjs/specs/types.d.ts.map +0 -1
- package/lib/commonjs/specs/types.js +0 -150
- package/lib/commonjs/specs/types.js.map +0 -1
- package/lib/commonjs/utils/base64.d.ts +0 -26
- package/lib/commonjs/utils/base64.d.ts.map +0 -1
- package/lib/commonjs/utils/base64.js +0 -88
- package/lib/commonjs/utils/base64.js.map +0 -1
- package/lib/commonjs/utils/index.d.ts +0 -3
- package/lib/commonjs/utils/index.d.ts.map +0 -1
- package/lib/commonjs/utils/index.js.map +0 -1
- package/lib/commonjs/utils/uuid.d.ts +0 -10
- package/lib/commonjs/utils/uuid.d.ts.map +0 -1
- package/lib/commonjs/utils/uuid.js +0 -41
- package/lib/commonjs/utils/uuid.js.map +0 -1
- package/lib/compatibility/constants.d.ts +0 -49
- package/lib/compatibility/constants.js +0 -50
- package/lib/compatibility/deviceWrapper.d.ts +0 -99
- package/lib/compatibility/deviceWrapper.js +0 -259
- package/lib/compatibility/enums.d.ts +0 -38
- package/lib/compatibility/enums.js +0 -159
- package/lib/compatibility/index.d.ts +0 -12
- package/lib/compatibility/index.js +0 -12
- package/lib/compatibility/serviceData.d.ts +0 -51
- package/lib/compatibility/serviceData.js +0 -70
- package/lib/errors/BleError.d.ts +0 -59
- package/lib/errors/BleError.js +0 -120
- package/lib/specs/BleManager.nitro.d.ts +0 -44
- package/lib/specs/BleManager.nitro.js +0 -1
- package/lib/specs/Characteristic.nitro.d.ts +0 -26
- package/lib/specs/Characteristic.nitro.js +0 -1
- package/lib/specs/Descriptor.nitro.d.ts +0 -17
- package/lib/specs/Descriptor.nitro.js +0 -1
- package/lib/specs/Device.nitro.d.ts +0 -37
- package/lib/specs/Device.nitro.js +0 -1
- package/lib/specs/Service.nitro.d.ts +0 -19
- package/lib/specs/Service.nitro.js +0 -1
- package/lib/specs/types.d.ts +0 -228
- package/lib/specs/types.js +0 -146
- package/lib/utils/base64.d.ts +0 -25
- package/lib/utils/base64.js +0 -80
- package/lib/utils/index.d.ts +0 -2
- package/lib/utils/index.js +0 -2
- package/lib/utils/uuid.d.ts +0 -9
- package/lib/utils/uuid.js +0 -37
- package/nitrogen/generated/android/c++/JBleATTErrorCode.hpp +0 -107
- package/nitrogen/generated/android/c++/JBleAndroidErrorCode.hpp +0 -101
- package/nitrogen/generated/android/c++/JBleErrorCode.hpp +0 -170
- package/nitrogen/generated/android/c++/JBleIOSErrorCode.hpp +0 -92
- package/nitrogen/generated/android/c++/JBleManagerNitroOptions.hpp +0 -54
- package/nitrogen/generated/android/c++/JBleRestoredState.hpp +0 -76
- package/nitrogen/generated/android/c++/JCharacteristicSubscriptionType.hpp +0 -59
- package/nitrogen/generated/android/c++/JConnectionOptions.hpp +0 -61
- package/nitrogen/generated/android/c++/JConnectionPriority.hpp +0 -62
- package/nitrogen/generated/android/c++/JFunc_void.hpp +0 -74
- package/nitrogen/generated/android/c++/JFunc_void_State.hpp +0 -76
- package/nitrogen/generated/android/c++/JFunc_void_std__optional_NativeBleError__std__optional_NativeCharacteristic_.hpp +0 -88
- package/nitrogen/generated/android/c++/JFunc_void_std__optional_NativeBleError__std__optional_NativeDevice_.hpp +0 -91
- package/nitrogen/generated/android/c++/JHybridBleManagerSpec.cpp +0 -653
- package/nitrogen/generated/android/c++/JHybridBleManagerSpec.hpp +0 -92
- package/nitrogen/generated/android/c++/JHybridCharacteristicSpec.cpp +0 -253
- package/nitrogen/generated/android/c++/JHybridCharacteristicSpec.hpp +0 -79
- package/nitrogen/generated/android/c++/JHybridDescriptorSpec.cpp +0 -115
- package/nitrogen/generated/android/c++/JHybridDescriptorSpec.hpp +0 -70
- package/nitrogen/generated/android/c++/JHybridDeviceSpec.cpp +0 -476
- package/nitrogen/generated/android/c++/JHybridDeviceSpec.hpp +0 -90
- package/nitrogen/generated/android/c++/JHybridServiceSpec.cpp +0 -232
- package/nitrogen/generated/android/c++/JHybridServiceSpec.hpp +0 -72
- package/nitrogen/generated/android/c++/JLogLevel.hpp +0 -71
- package/nitrogen/generated/android/c++/JNativeBleError.hpp +0 -98
- package/nitrogen/generated/android/c++/JNativeCharacteristic.hpp +0 -98
- package/nitrogen/generated/android/c++/JNativeDescriptor.hpp +0 -82
- package/nitrogen/generated/android/c++/JNativeDevice.hpp +0 -173
- package/nitrogen/generated/android/c++/JNativeService.hpp +0 -65
- package/nitrogen/generated/android/c++/JScanCallbackType.hpp +0 -62
- package/nitrogen/generated/android/c++/JScanMode.hpp +0 -65
- package/nitrogen/generated/android/c++/JScanOptions.hpp +0 -69
- package/nitrogen/generated/android/c++/JServiceDataEntry.hpp +0 -57
- package/nitrogen/generated/android/c++/JSubscription.hpp +0 -64
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/BleATTErrorCode.kt +0 -41
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/BleAndroidErrorCode.kt +0 -39
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/BleErrorCode.kt +0 -62
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/BleIOSErrorCode.kt +0 -36
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/BleManagerNitroOptions.kt +0 -26
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/BleRestoredState.kt +0 -26
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/CharacteristicSubscriptionType.kt +0 -25
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/ConnectionPriority.kt +0 -26
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/HybridBleManagerSpec.kt +0 -192
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/HybridCharacteristicSpec.kt +0 -127
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/HybridDescriptorSpec.kt +0 -86
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/HybridDeviceSpec.kt +0 -176
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/HybridServiceSpec.kt +0 -99
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/NativeBleError.kt +0 -35
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/NativeCharacteristic.kt +0 -37
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/NativeDescriptor.kt +0 -33
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/NativeDevice.kt +0 -38
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/ScanCallbackType.kt +0 -26
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/ScanMode.kt +0 -27
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/ScanOptions.kt +0 -29
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/State.kt +0 -29
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/co/zyke/ble/Subscription.kt +0 -30
- package/nitrogen/generated/ios/c++/HybridBleManagerSpecSwift.cpp +0 -11
- package/nitrogen/generated/ios/c++/HybridBleManagerSpecSwift.hpp +0 -377
- package/nitrogen/generated/ios/c++/HybridCharacteristicSpecSwift.hpp +0 -192
- package/nitrogen/generated/ios/c++/HybridDescriptorSpecSwift.cpp +0 -11
- package/nitrogen/generated/ios/c++/HybridDescriptorSpecSwift.hpp +0 -112
- package/nitrogen/generated/ios/c++/HybridDeviceSpecSwift.cpp +0 -11
- package/nitrogen/generated/ios/c++/HybridDeviceSpecSwift.hpp +0 -294
- package/nitrogen/generated/ios/c++/HybridServiceSpecSwift.cpp +0 -11
- package/nitrogen/generated/ios/c++/HybridServiceSpecSwift.hpp +0 -170
- package/nitrogen/generated/ios/swift/BleATTErrorCode.swift +0 -104
- package/nitrogen/generated/ios/swift/BleAndroidErrorCode.swift +0 -96
- package/nitrogen/generated/ios/swift/BleErrorCode.swift +0 -188
- package/nitrogen/generated/ios/swift/BleIOSErrorCode.swift +0 -84
- package/nitrogen/generated/ios/swift/BleManagerNitroOptions.swift +0 -53
- package/nitrogen/generated/ios/swift/BleRestoredState.swift +0 -47
- package/nitrogen/generated/ios/swift/CharacteristicSubscriptionType.swift +0 -40
- package/nitrogen/generated/ios/swift/ConnectionOptions.swift +0 -57
- package/nitrogen/generated/ios/swift/ConnectionPriority.swift +0 -44
- package/nitrogen/generated/ios/swift/Func_void_std__optional_NativeBleError__std__optional_NativeCharacteristic_.swift +0 -58
- package/nitrogen/generated/ios/swift/Func_void_std__optional_NativeBleError__std__optional_NativeDevice_.swift +0 -58
- package/nitrogen/generated/ios/swift/Func_void_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec_.swift +0 -50
- package/nitrogen/generated/ios/swift/Func_void_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec_.swift +0 -50
- package/nitrogen/generated/ios/swift/Func_void_std__vector_NativeDescriptor_.swift +0 -46
- package/nitrogen/generated/ios/swift/Func_void_std__vector_NativeService_.swift +0 -46
- package/nitrogen/generated/ios/swift/HybridBleManagerSpec.swift +0 -78
- package/nitrogen/generated/ios/swift/HybridBleManagerSpec_cxx.swift +0 -852
- package/nitrogen/generated/ios/swift/HybridCharacteristicSpec.swift +0 -65
- package/nitrogen/generated/ios/swift/HybridCharacteristicSpec_cxx.swift +0 -384
- package/nitrogen/generated/ios/swift/HybridDescriptorSpec.swift +0 -56
- package/nitrogen/generated/ios/swift/HybridDescriptorSpec_cxx.swift +0 -218
- package/nitrogen/generated/ios/swift/HybridDeviceSpec.swift +0 -76
- package/nitrogen/generated/ios/swift/HybridDeviceSpec_cxx.swift +0 -702
- package/nitrogen/generated/ios/swift/HybridServiceSpec.swift +0 -58
- package/nitrogen/generated/ios/swift/HybridServiceSpec_cxx.swift +0 -338
- package/nitrogen/generated/ios/swift/LogLevel.swift +0 -56
- package/nitrogen/generated/ios/swift/NativeBleError.swift +0 -278
- package/nitrogen/generated/ios/swift/NativeCharacteristic.swift +0 -174
- package/nitrogen/generated/ios/swift/NativeDescriptor.swift +0 -130
- package/nitrogen/generated/ios/swift/NativeDevice.swift +0 -377
- package/nitrogen/generated/ios/swift/NativeService.swift +0 -68
- package/nitrogen/generated/ios/swift/ScanCallbackType.swift +0 -44
- package/nitrogen/generated/ios/swift/ScanMode.swift +0 -48
- package/nitrogen/generated/ios/swift/ScanOptions.swift +0 -116
- package/nitrogen/generated/ios/swift/ServiceDataEntry.swift +0 -46
- package/nitrogen/generated/ios/swift/Subscription.swift +0 -46
- package/nitrogen/generated/shared/c++/BleATTErrorCode.hpp +0 -80
- package/nitrogen/generated/shared/c++/BleAndroidErrorCode.hpp +0 -78
- package/nitrogen/generated/shared/c++/BleErrorCode.hpp +0 -101
- package/nitrogen/generated/shared/c++/BleIOSErrorCode.hpp +0 -75
- package/nitrogen/generated/shared/c++/BleManagerNitroOptions.hpp +0 -70
- package/nitrogen/generated/shared/c++/BleRestoredState.hpp +0 -71
- package/nitrogen/generated/shared/c++/CharacteristicSubscriptionType.hpp +0 -64
- package/nitrogen/generated/shared/c++/ConnectionOptions.hpp +0 -77
- package/nitrogen/generated/shared/c++/ConnectionPriority.hpp +0 -65
- package/nitrogen/generated/shared/c++/HybridBleManagerSpec.cpp +0 -51
- package/nitrogen/generated/shared/c++/HybridBleManagerSpec.hpp +0 -137
- package/nitrogen/generated/shared/c++/HybridCharacteristicSpec.cpp +0 -39
- package/nitrogen/generated/shared/c++/HybridCharacteristicSpec.hpp +0 -101
- package/nitrogen/generated/shared/c++/HybridDescriptorSpec.cpp +0 -30
- package/nitrogen/generated/shared/c++/HybridDescriptorSpec.hpp +0 -75
- package/nitrogen/generated/shared/c++/HybridDeviceSpec.cpp +0 -50
- package/nitrogen/generated/shared/c++/HybridDeviceSpec.hpp +0 -123
- package/nitrogen/generated/shared/c++/HybridServiceSpec.cpp +0 -32
- package/nitrogen/generated/shared/c++/HybridServiceSpec.hpp +0 -90
- package/nitrogen/generated/shared/c++/LogLevel.hpp +0 -68
- package/nitrogen/generated/shared/c++/NativeBleError.hpp +0 -117
- package/nitrogen/generated/shared/c++/NativeCharacteristic.hpp +0 -114
- package/nitrogen/generated/shared/c++/NativeDescriptor.hpp +0 -98
- package/nitrogen/generated/shared/c++/NativeDevice.hpp +0 -121
- package/nitrogen/generated/shared/c++/NativeService.hpp +0 -81
- package/nitrogen/generated/shared/c++/ScanCallbackType.hpp +0 -65
- package/nitrogen/generated/shared/c++/ScanMode.hpp +0 -66
- package/nitrogen/generated/shared/c++/ScanOptions.hpp +0 -86
- package/nitrogen/generated/shared/c++/Subscription.hpp +0 -69
- package/src/BleManagerCompatFactory.ts +0 -371
- package/src/BleManagerFactory.ts +0 -93
- package/src/__tests__/BleManager.test.ts +0 -327
- package/src/__tests__/compatibility/deviceWrapper.test.ts +0 -563
- package/src/__tests__/compatibility/enums.test.ts +0 -264
- package/src/compatibility/constants.ts +0 -71
- package/src/compatibility/deviceWrapper.ts +0 -427
- package/src/compatibility/enums.ts +0 -190
- package/src/compatibility/index.ts +0 -32
- package/src/compatibility/serviceData.ts +0 -85
- package/src/errors/BleError.ts +0 -193
- package/src/specs/BleManager.nitro.ts +0 -165
- package/src/specs/Characteristic.nitro.ts +0 -61
- package/src/specs/Descriptor.nitro.ts +0 -28
- package/src/specs/Device.nitro.ts +0 -104
- package/src/specs/Service.nitro.ts +0 -64
- package/src/specs/types.ts +0 -259
- package/src/utils/base64.ts +0 -80
- package/src/utils/index.ts +0 -2
- package/src/utils/uuid.ts +0 -45
|
@@ -8,92 +8,27 @@
|
|
|
8
8
|
#pragma once
|
|
9
9
|
|
|
10
10
|
// Forward declarations of C++ defined types
|
|
11
|
-
// Forward declaration of `
|
|
12
|
-
namespace margelo::nitro::co::zyke::ble {
|
|
13
|
-
// Forward declaration of `
|
|
14
|
-
namespace margelo::nitro::co::zyke::ble { enum class
|
|
15
|
-
// Forward declaration of `
|
|
16
|
-
namespace margelo::nitro::co::zyke::ble {
|
|
17
|
-
// Forward declaration of `
|
|
18
|
-
namespace margelo::nitro::co::zyke::ble {
|
|
19
|
-
// Forward declaration of `
|
|
20
|
-
namespace margelo::nitro::co::zyke::ble { struct
|
|
21
|
-
// Forward declaration of `CharacteristicSubscriptionType` to properly resolve imports.
|
|
22
|
-
namespace margelo::nitro::co::zyke::ble { enum class CharacteristicSubscriptionType; }
|
|
23
|
-
// Forward declaration of `ConnectionOptions` to properly resolve imports.
|
|
24
|
-
namespace margelo::nitro::co::zyke::ble { struct ConnectionOptions; }
|
|
25
|
-
// Forward declaration of `HybridBleManagerSpec` to properly resolve imports.
|
|
26
|
-
namespace margelo::nitro::co::zyke::ble { class HybridBleManagerSpec; }
|
|
27
|
-
// Forward declaration of `HybridCharacteristicSpec` to properly resolve imports.
|
|
28
|
-
namespace margelo::nitro::co::zyke::ble { class HybridCharacteristicSpec; }
|
|
29
|
-
// Forward declaration of `HybridDescriptorSpec` to properly resolve imports.
|
|
30
|
-
namespace margelo::nitro::co::zyke::ble { class HybridDescriptorSpec; }
|
|
31
|
-
// Forward declaration of `HybridDeviceSpec` to properly resolve imports.
|
|
32
|
-
namespace margelo::nitro::co::zyke::ble { class HybridDeviceSpec; }
|
|
33
|
-
// Forward declaration of `HybridServiceSpec` to properly resolve imports.
|
|
34
|
-
namespace margelo::nitro::co::zyke::ble { class HybridServiceSpec; }
|
|
35
|
-
// Forward declaration of `LogLevel` to properly resolve imports.
|
|
36
|
-
namespace margelo::nitro::co::zyke::ble { enum class LogLevel; }
|
|
37
|
-
// Forward declaration of `NativeBleError` to properly resolve imports.
|
|
38
|
-
namespace margelo::nitro::co::zyke::ble { struct NativeBleError; }
|
|
39
|
-
// Forward declaration of `NativeCharacteristic` to properly resolve imports.
|
|
40
|
-
namespace margelo::nitro::co::zyke::ble { struct NativeCharacteristic; }
|
|
41
|
-
// Forward declaration of `NativeDescriptor` to properly resolve imports.
|
|
42
|
-
namespace margelo::nitro::co::zyke::ble { struct NativeDescriptor; }
|
|
43
|
-
// Forward declaration of `NativeDevice` to properly resolve imports.
|
|
44
|
-
namespace margelo::nitro::co::zyke::ble { struct NativeDevice; }
|
|
45
|
-
// Forward declaration of `NativeService` to properly resolve imports.
|
|
46
|
-
namespace margelo::nitro::co::zyke::ble { struct NativeService; }
|
|
47
|
-
// Forward declaration of `ScanCallbackType` to properly resolve imports.
|
|
48
|
-
namespace margelo::nitro::co::zyke::ble { enum class ScanCallbackType; }
|
|
49
|
-
// Forward declaration of `ScanMode` to properly resolve imports.
|
|
50
|
-
namespace margelo::nitro::co::zyke::ble { enum class ScanMode; }
|
|
51
|
-
// Forward declaration of `ScanOptions` to properly resolve imports.
|
|
52
|
-
namespace margelo::nitro::co::zyke::ble { struct ScanOptions; }
|
|
53
|
-
// Forward declaration of `ServiceDataEntry` to properly resolve imports.
|
|
54
|
-
namespace margelo::nitro::co::zyke::ble { struct ServiceDataEntry; }
|
|
55
|
-
// Forward declaration of `State` to properly resolve imports.
|
|
56
|
-
namespace margelo::nitro::co::zyke::ble { enum class State; }
|
|
57
|
-
// Forward declaration of `Subscription` to properly resolve imports.
|
|
58
|
-
namespace margelo::nitro::co::zyke::ble { struct Subscription; }
|
|
11
|
+
// Forward declaration of `BLEDevice` to properly resolve imports.
|
|
12
|
+
namespace margelo::nitro::co::zyke::ble { struct BLEDevice; }
|
|
13
|
+
// Forward declaration of `BLEState` to properly resolve imports.
|
|
14
|
+
namespace margelo::nitro::co::zyke::ble { enum class BLEState; }
|
|
15
|
+
// Forward declaration of `HybridNativeBleNitroSpec` to properly resolve imports.
|
|
16
|
+
namespace margelo::nitro::co::zyke::ble { class HybridNativeBleNitroSpec; }
|
|
17
|
+
// Forward declaration of `ManufacturerDataEntry` to properly resolve imports.
|
|
18
|
+
namespace margelo::nitro::co::zyke::ble { struct ManufacturerDataEntry; }
|
|
19
|
+
// Forward declaration of `ManufacturerData` to properly resolve imports.
|
|
20
|
+
namespace margelo::nitro::co::zyke::ble { struct ManufacturerData; }
|
|
59
21
|
|
|
60
22
|
// Forward declarations of Swift defined types
|
|
61
|
-
// Forward declaration of `
|
|
62
|
-
namespace BleNitro { class
|
|
63
|
-
// Forward declaration of `HybridCharacteristicSpec_cxx` to properly resolve imports.
|
|
64
|
-
namespace BleNitro { class HybridCharacteristicSpec_cxx; }
|
|
65
|
-
// Forward declaration of `HybridDescriptorSpec_cxx` to properly resolve imports.
|
|
66
|
-
namespace BleNitro { class HybridDescriptorSpec_cxx; }
|
|
67
|
-
// Forward declaration of `HybridDeviceSpec_cxx` to properly resolve imports.
|
|
68
|
-
namespace BleNitro { class HybridDeviceSpec_cxx; }
|
|
69
|
-
// Forward declaration of `HybridServiceSpec_cxx` to properly resolve imports.
|
|
70
|
-
namespace BleNitro { class HybridServiceSpec_cxx; }
|
|
23
|
+
// Forward declaration of `HybridNativeBleNitroSpec_cxx` to properly resolve imports.
|
|
24
|
+
namespace BleNitro { class HybridNativeBleNitroSpec_cxx; }
|
|
71
25
|
|
|
72
26
|
// Include C++ defined types
|
|
73
|
-
#include "
|
|
74
|
-
#include "
|
|
75
|
-
#include "
|
|
76
|
-
#include "
|
|
77
|
-
#include "
|
|
78
|
-
#include "CharacteristicSubscriptionType.hpp"
|
|
79
|
-
#include "ConnectionOptions.hpp"
|
|
80
|
-
#include "HybridBleManagerSpec.hpp"
|
|
81
|
-
#include "HybridCharacteristicSpec.hpp"
|
|
82
|
-
#include "HybridDescriptorSpec.hpp"
|
|
83
|
-
#include "HybridDeviceSpec.hpp"
|
|
84
|
-
#include "HybridServiceSpec.hpp"
|
|
85
|
-
#include "LogLevel.hpp"
|
|
86
|
-
#include "NativeBleError.hpp"
|
|
87
|
-
#include "NativeCharacteristic.hpp"
|
|
88
|
-
#include "NativeDescriptor.hpp"
|
|
89
|
-
#include "NativeDevice.hpp"
|
|
90
|
-
#include "NativeService.hpp"
|
|
91
|
-
#include "ScanCallbackType.hpp"
|
|
92
|
-
#include "ScanMode.hpp"
|
|
93
|
-
#include "ScanOptions.hpp"
|
|
94
|
-
#include "ServiceDataEntry.hpp"
|
|
95
|
-
#include "State.hpp"
|
|
96
|
-
#include "Subscription.hpp"
|
|
27
|
+
#include "BLEDevice.hpp"
|
|
28
|
+
#include "BLEState.hpp"
|
|
29
|
+
#include "HybridNativeBleNitroSpec.hpp"
|
|
30
|
+
#include "ManufacturerData.hpp"
|
|
31
|
+
#include "ManufacturerDataEntry.hpp"
|
|
97
32
|
#include <NitroModules/Promise.hpp>
|
|
98
33
|
#include <NitroModules/PromiseHolder.hpp>
|
|
99
34
|
#include <NitroModules/Result.hpp>
|
|
@@ -110,100 +45,6 @@ namespace BleNitro { class HybridServiceSpec_cxx; }
|
|
|
110
45
|
*/
|
|
111
46
|
namespace margelo::nitro::co::zyke::ble::bridge::swift {
|
|
112
47
|
|
|
113
|
-
// pragma MARK: std::shared_ptr<Promise<void>>
|
|
114
|
-
/**
|
|
115
|
-
* Specialized version of `std::shared_ptr<Promise<void>>`.
|
|
116
|
-
*/
|
|
117
|
-
using std__shared_ptr_Promise_void__ = std::shared_ptr<Promise<void>>;
|
|
118
|
-
inline std::shared_ptr<Promise<void>> create_std__shared_ptr_Promise_void__() {
|
|
119
|
-
return Promise<void>::create();
|
|
120
|
-
}
|
|
121
|
-
inline PromiseHolder<void> wrap_std__shared_ptr_Promise_void__(std::shared_ptr<Promise<void>> promise) {
|
|
122
|
-
return PromiseHolder<void>(std::move(promise));
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
// pragma MARK: std::function<void()>
|
|
126
|
-
/**
|
|
127
|
-
* Specialized version of `std::function<void()>`.
|
|
128
|
-
*/
|
|
129
|
-
using Func_void = std::function<void()>;
|
|
130
|
-
/**
|
|
131
|
-
* Wrapper class for a `std::function<void()>`, this can be used from Swift.
|
|
132
|
-
*/
|
|
133
|
-
class Func_void_Wrapper final {
|
|
134
|
-
public:
|
|
135
|
-
explicit Func_void_Wrapper(std::function<void()>&& func): _function(std::make_unique<std::function<void()>>(std::move(func))) {}
|
|
136
|
-
inline void call() const {
|
|
137
|
-
_function->operator()();
|
|
138
|
-
}
|
|
139
|
-
private:
|
|
140
|
-
std::unique_ptr<std::function<void()>> _function;
|
|
141
|
-
} SWIFT_NONCOPYABLE;
|
|
142
|
-
Func_void create_Func_void(void* _Nonnull swiftClosureWrapper);
|
|
143
|
-
inline Func_void_Wrapper wrap_Func_void(Func_void value) {
|
|
144
|
-
return Func_void_Wrapper(std::move(value));
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
// pragma MARK: std::function<void(const std::exception_ptr& /* error */)>
|
|
148
|
-
/**
|
|
149
|
-
* Specialized version of `std::function<void(const std::exception_ptr&)>`.
|
|
150
|
-
*/
|
|
151
|
-
using Func_void_std__exception_ptr = std::function<void(const std::exception_ptr& /* error */)>;
|
|
152
|
-
/**
|
|
153
|
-
* Wrapper class for a `std::function<void(const std::exception_ptr& / * error * /)>`, this can be used from Swift.
|
|
154
|
-
*/
|
|
155
|
-
class Func_void_std__exception_ptr_Wrapper final {
|
|
156
|
-
public:
|
|
157
|
-
explicit Func_void_std__exception_ptr_Wrapper(std::function<void(const std::exception_ptr& /* error */)>&& func): _function(std::make_unique<std::function<void(const std::exception_ptr& /* error */)>>(std::move(func))) {}
|
|
158
|
-
inline void call(std::exception_ptr error) const {
|
|
159
|
-
_function->operator()(error);
|
|
160
|
-
}
|
|
161
|
-
private:
|
|
162
|
-
std::unique_ptr<std::function<void(const std::exception_ptr& /* error */)>> _function;
|
|
163
|
-
} SWIFT_NONCOPYABLE;
|
|
164
|
-
Func_void_std__exception_ptr create_Func_void_std__exception_ptr(void* _Nonnull swiftClosureWrapper);
|
|
165
|
-
inline Func_void_std__exception_ptr_Wrapper wrap_Func_void_std__exception_ptr(Func_void_std__exception_ptr value) {
|
|
166
|
-
return Func_void_std__exception_ptr_Wrapper(std::move(value));
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
// pragma MARK: std::optional<std::string>
|
|
170
|
-
/**
|
|
171
|
-
* Specialized version of `std::optional<std::string>`.
|
|
172
|
-
*/
|
|
173
|
-
using std__optional_std__string_ = std::optional<std::string>;
|
|
174
|
-
inline std::optional<std::string> create_std__optional_std__string_(const std::string& value) {
|
|
175
|
-
return std::optional<std::string>(value);
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
// pragma MARK: std::optional<double>
|
|
179
|
-
/**
|
|
180
|
-
* Specialized version of `std::optional<double>`.
|
|
181
|
-
*/
|
|
182
|
-
using std__optional_double_ = std::optional<double>;
|
|
183
|
-
inline std::optional<double> create_std__optional_double_(const double& value) {
|
|
184
|
-
return std::optional<double>(value);
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
// pragma MARK: std::vector<ServiceDataEntry>
|
|
188
|
-
/**
|
|
189
|
-
* Specialized version of `std::vector<ServiceDataEntry>`.
|
|
190
|
-
*/
|
|
191
|
-
using std__vector_ServiceDataEntry_ = std::vector<ServiceDataEntry>;
|
|
192
|
-
inline std::vector<ServiceDataEntry> create_std__vector_ServiceDataEntry_(size_t size) {
|
|
193
|
-
std::vector<ServiceDataEntry> vector;
|
|
194
|
-
vector.reserve(size);
|
|
195
|
-
return vector;
|
|
196
|
-
}
|
|
197
|
-
|
|
198
|
-
// pragma MARK: std::optional<std::vector<ServiceDataEntry>>
|
|
199
|
-
/**
|
|
200
|
-
* Specialized version of `std::optional<std::vector<ServiceDataEntry>>`.
|
|
201
|
-
*/
|
|
202
|
-
using std__optional_std__vector_ServiceDataEntry__ = std::optional<std::vector<ServiceDataEntry>>;
|
|
203
|
-
inline std::optional<std::vector<ServiceDataEntry>> create_std__optional_std__vector_ServiceDataEntry__(const std::vector<ServiceDataEntry>& value) {
|
|
204
|
-
return std::optional<std::vector<ServiceDataEntry>>(value);
|
|
205
|
-
}
|
|
206
|
-
|
|
207
48
|
// pragma MARK: std::vector<std::string>
|
|
208
49
|
/**
|
|
209
50
|
* Specialized version of `std::vector<std::string>`.
|
|
@@ -215,327 +56,70 @@ namespace margelo::nitro::co::zyke::ble::bridge::swift {
|
|
|
215
56
|
return vector;
|
|
216
57
|
}
|
|
217
58
|
|
|
218
|
-
// pragma MARK: std::
|
|
219
|
-
/**
|
|
220
|
-
* Specialized version of `std::optional<std::vector<std::string>>`.
|
|
221
|
-
*/
|
|
222
|
-
using std__optional_std__vector_std__string__ = std::optional<std::vector<std::string>>;
|
|
223
|
-
inline std::optional<std::vector<std::string>> create_std__optional_std__vector_std__string__(const std::vector<std::string>& value) {
|
|
224
|
-
return std::optional<std::vector<std::string>>(value);
|
|
225
|
-
}
|
|
226
|
-
|
|
227
|
-
// pragma MARK: std::optional<bool>
|
|
228
|
-
/**
|
|
229
|
-
* Specialized version of `std::optional<bool>`.
|
|
230
|
-
*/
|
|
231
|
-
using std__optional_bool_ = std::optional<bool>;
|
|
232
|
-
inline std::optional<bool> create_std__optional_bool_(const bool& value) {
|
|
233
|
-
return std::optional<bool>(value);
|
|
234
|
-
}
|
|
235
|
-
|
|
236
|
-
// pragma MARK: std::vector<NativeDevice>
|
|
59
|
+
// pragma MARK: std::vector<double>
|
|
237
60
|
/**
|
|
238
|
-
* Specialized version of `std::vector<
|
|
61
|
+
* Specialized version of `std::vector<double>`.
|
|
239
62
|
*/
|
|
240
|
-
using
|
|
241
|
-
inline std::vector<
|
|
242
|
-
std::vector<
|
|
63
|
+
using std__vector_double_ = std::vector<double>;
|
|
64
|
+
inline std::vector<double> create_std__vector_double_(size_t size) {
|
|
65
|
+
std::vector<double> vector;
|
|
243
66
|
vector.reserve(size);
|
|
244
67
|
return vector;
|
|
245
68
|
}
|
|
246
69
|
|
|
247
|
-
// pragma MARK: std::
|
|
70
|
+
// pragma MARK: std::vector<ManufacturerDataEntry>
|
|
248
71
|
/**
|
|
249
|
-
* Specialized version of `std::
|
|
72
|
+
* Specialized version of `std::vector<ManufacturerDataEntry>`.
|
|
250
73
|
*/
|
|
251
|
-
using
|
|
252
|
-
inline std::
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
// pragma MARK: std::shared_ptr<Promise<std::optional<BleRestoredState>>>
|
|
257
|
-
/**
|
|
258
|
-
* Specialized version of `std::shared_ptr<Promise<std::optional<BleRestoredState>>>`.
|
|
259
|
-
*/
|
|
260
|
-
using std__shared_ptr_Promise_std__optional_BleRestoredState___ = std::shared_ptr<Promise<std::optional<BleRestoredState>>>;
|
|
261
|
-
inline std::shared_ptr<Promise<std::optional<BleRestoredState>>> create_std__shared_ptr_Promise_std__optional_BleRestoredState___() {
|
|
262
|
-
return Promise<std::optional<BleRestoredState>>::create();
|
|
263
|
-
}
|
|
264
|
-
inline PromiseHolder<std::optional<BleRestoredState>> wrap_std__shared_ptr_Promise_std__optional_BleRestoredState___(std::shared_ptr<Promise<std::optional<BleRestoredState>>> promise) {
|
|
265
|
-
return PromiseHolder<std::optional<BleRestoredState>>(std::move(promise));
|
|
266
|
-
}
|
|
267
|
-
|
|
268
|
-
// pragma MARK: std::function<void(const std::optional<BleRestoredState>& /* result */)>
|
|
269
|
-
/**
|
|
270
|
-
* Specialized version of `std::function<void(const std::optional<BleRestoredState>&)>`.
|
|
271
|
-
*/
|
|
272
|
-
using Func_void_std__optional_BleRestoredState_ = std::function<void(const std::optional<BleRestoredState>& /* result */)>;
|
|
273
|
-
/**
|
|
274
|
-
* Wrapper class for a `std::function<void(const std::optional<BleRestoredState>& / * result * /)>`, this can be used from Swift.
|
|
275
|
-
*/
|
|
276
|
-
class Func_void_std__optional_BleRestoredState__Wrapper final {
|
|
277
|
-
public:
|
|
278
|
-
explicit Func_void_std__optional_BleRestoredState__Wrapper(std::function<void(const std::optional<BleRestoredState>& /* result */)>&& func): _function(std::make_unique<std::function<void(const std::optional<BleRestoredState>& /* result */)>>(std::move(func))) {}
|
|
279
|
-
inline void call(std::optional<BleRestoredState> result) const {
|
|
280
|
-
_function->operator()(result);
|
|
281
|
-
}
|
|
282
|
-
private:
|
|
283
|
-
std::unique_ptr<std::function<void(const std::optional<BleRestoredState>& /* result */)>> _function;
|
|
284
|
-
} SWIFT_NONCOPYABLE;
|
|
285
|
-
Func_void_std__optional_BleRestoredState_ create_Func_void_std__optional_BleRestoredState_(void* _Nonnull swiftClosureWrapper);
|
|
286
|
-
inline Func_void_std__optional_BleRestoredState__Wrapper wrap_Func_void_std__optional_BleRestoredState_(Func_void_std__optional_BleRestoredState_ value) {
|
|
287
|
-
return Func_void_std__optional_BleRestoredState__Wrapper(std::move(value));
|
|
288
|
-
}
|
|
289
|
-
|
|
290
|
-
// pragma MARK: std::shared_ptr<Promise<LogLevel>>
|
|
291
|
-
/**
|
|
292
|
-
* Specialized version of `std::shared_ptr<Promise<LogLevel>>`.
|
|
293
|
-
*/
|
|
294
|
-
using std__shared_ptr_Promise_LogLevel__ = std::shared_ptr<Promise<LogLevel>>;
|
|
295
|
-
inline std::shared_ptr<Promise<LogLevel>> create_std__shared_ptr_Promise_LogLevel__() {
|
|
296
|
-
return Promise<LogLevel>::create();
|
|
297
|
-
}
|
|
298
|
-
inline PromiseHolder<LogLevel> wrap_std__shared_ptr_Promise_LogLevel__(std::shared_ptr<Promise<LogLevel>> promise) {
|
|
299
|
-
return PromiseHolder<LogLevel>(std::move(promise));
|
|
300
|
-
}
|
|
301
|
-
|
|
302
|
-
// pragma MARK: std::function<void(LogLevel /* result */)>
|
|
303
|
-
/**
|
|
304
|
-
* Specialized version of `std::function<void(LogLevel)>`.
|
|
305
|
-
*/
|
|
306
|
-
using Func_void_LogLevel = std::function<void(LogLevel /* result */)>;
|
|
307
|
-
/**
|
|
308
|
-
* Wrapper class for a `std::function<void(LogLevel / * result * /)>`, this can be used from Swift.
|
|
309
|
-
*/
|
|
310
|
-
class Func_void_LogLevel_Wrapper final {
|
|
311
|
-
public:
|
|
312
|
-
explicit Func_void_LogLevel_Wrapper(std::function<void(LogLevel /* result */)>&& func): _function(std::make_unique<std::function<void(LogLevel /* result */)>>(std::move(func))) {}
|
|
313
|
-
inline void call(int result) const {
|
|
314
|
-
_function->operator()(static_cast<LogLevel>(result));
|
|
315
|
-
}
|
|
316
|
-
private:
|
|
317
|
-
std::unique_ptr<std::function<void(LogLevel /* result */)>> _function;
|
|
318
|
-
} SWIFT_NONCOPYABLE;
|
|
319
|
-
Func_void_LogLevel create_Func_void_LogLevel(void* _Nonnull swiftClosureWrapper);
|
|
320
|
-
inline Func_void_LogLevel_Wrapper wrap_Func_void_LogLevel(Func_void_LogLevel value) {
|
|
321
|
-
return Func_void_LogLevel_Wrapper(std::move(value));
|
|
322
|
-
}
|
|
323
|
-
|
|
324
|
-
// pragma MARK: std::shared_ptr<Promise<State>>
|
|
325
|
-
/**
|
|
326
|
-
* Specialized version of `std::shared_ptr<Promise<State>>`.
|
|
327
|
-
*/
|
|
328
|
-
using std__shared_ptr_Promise_State__ = std::shared_ptr<Promise<State>>;
|
|
329
|
-
inline std::shared_ptr<Promise<State>> create_std__shared_ptr_Promise_State__() {
|
|
330
|
-
return Promise<State>::create();
|
|
331
|
-
}
|
|
332
|
-
inline PromiseHolder<State> wrap_std__shared_ptr_Promise_State__(std::shared_ptr<Promise<State>> promise) {
|
|
333
|
-
return PromiseHolder<State>(std::move(promise));
|
|
334
|
-
}
|
|
335
|
-
|
|
336
|
-
// pragma MARK: std::function<void(State /* result */)>
|
|
337
|
-
/**
|
|
338
|
-
* Specialized version of `std::function<void(State)>`.
|
|
339
|
-
*/
|
|
340
|
-
using Func_void_State = std::function<void(State /* result */)>;
|
|
341
|
-
/**
|
|
342
|
-
* Wrapper class for a `std::function<void(State / * result * /)>`, this can be used from Swift.
|
|
343
|
-
*/
|
|
344
|
-
class Func_void_State_Wrapper final {
|
|
345
|
-
public:
|
|
346
|
-
explicit Func_void_State_Wrapper(std::function<void(State /* result */)>&& func): _function(std::make_unique<std::function<void(State /* result */)>>(std::move(func))) {}
|
|
347
|
-
inline void call(int result) const {
|
|
348
|
-
_function->operator()(static_cast<State>(result));
|
|
349
|
-
}
|
|
350
|
-
private:
|
|
351
|
-
std::unique_ptr<std::function<void(State /* result */)>> _function;
|
|
352
|
-
} SWIFT_NONCOPYABLE;
|
|
353
|
-
Func_void_State create_Func_void_State(void* _Nonnull swiftClosureWrapper);
|
|
354
|
-
inline Func_void_State_Wrapper wrap_Func_void_State(Func_void_State value) {
|
|
355
|
-
return Func_void_State_Wrapper(std::move(value));
|
|
356
|
-
}
|
|
357
|
-
|
|
358
|
-
// pragma MARK: std::optional<ScanMode>
|
|
359
|
-
/**
|
|
360
|
-
* Specialized version of `std::optional<ScanMode>`.
|
|
361
|
-
*/
|
|
362
|
-
using std__optional_ScanMode_ = std::optional<ScanMode>;
|
|
363
|
-
inline std::optional<ScanMode> create_std__optional_ScanMode_(const ScanMode& value) {
|
|
364
|
-
return std::optional<ScanMode>(value);
|
|
365
|
-
}
|
|
366
|
-
|
|
367
|
-
// pragma MARK: std::optional<ScanCallbackType>
|
|
368
|
-
/**
|
|
369
|
-
* Specialized version of `std::optional<ScanCallbackType>`.
|
|
370
|
-
*/
|
|
371
|
-
using std__optional_ScanCallbackType_ = std::optional<ScanCallbackType>;
|
|
372
|
-
inline std::optional<ScanCallbackType> create_std__optional_ScanCallbackType_(const ScanCallbackType& value) {
|
|
373
|
-
return std::optional<ScanCallbackType>(value);
|
|
374
|
-
}
|
|
375
|
-
|
|
376
|
-
// pragma MARK: std::optional<ScanOptions>
|
|
377
|
-
/**
|
|
378
|
-
* Specialized version of `std::optional<ScanOptions>`.
|
|
379
|
-
*/
|
|
380
|
-
using std__optional_ScanOptions_ = std::optional<ScanOptions>;
|
|
381
|
-
inline std::optional<ScanOptions> create_std__optional_ScanOptions_(const ScanOptions& value) {
|
|
382
|
-
return std::optional<ScanOptions>(value);
|
|
383
|
-
}
|
|
384
|
-
|
|
385
|
-
// pragma MARK: std::optional<BleATTErrorCode>
|
|
386
|
-
/**
|
|
387
|
-
* Specialized version of `std::optional<BleATTErrorCode>`.
|
|
388
|
-
*/
|
|
389
|
-
using std__optional_BleATTErrorCode_ = std::optional<BleATTErrorCode>;
|
|
390
|
-
inline std::optional<BleATTErrorCode> create_std__optional_BleATTErrorCode_(const BleATTErrorCode& value) {
|
|
391
|
-
return std::optional<BleATTErrorCode>(value);
|
|
392
|
-
}
|
|
393
|
-
|
|
394
|
-
// pragma MARK: std::optional<BleIOSErrorCode>
|
|
395
|
-
/**
|
|
396
|
-
* Specialized version of `std::optional<BleIOSErrorCode>`.
|
|
397
|
-
*/
|
|
398
|
-
using std__optional_BleIOSErrorCode_ = std::optional<BleIOSErrorCode>;
|
|
399
|
-
inline std::optional<BleIOSErrorCode> create_std__optional_BleIOSErrorCode_(const BleIOSErrorCode& value) {
|
|
400
|
-
return std::optional<BleIOSErrorCode>(value);
|
|
401
|
-
}
|
|
402
|
-
|
|
403
|
-
// pragma MARK: std::optional<BleAndroidErrorCode>
|
|
404
|
-
/**
|
|
405
|
-
* Specialized version of `std::optional<BleAndroidErrorCode>`.
|
|
406
|
-
*/
|
|
407
|
-
using std__optional_BleAndroidErrorCode_ = std::optional<BleAndroidErrorCode>;
|
|
408
|
-
inline std::optional<BleAndroidErrorCode> create_std__optional_BleAndroidErrorCode_(const BleAndroidErrorCode& value) {
|
|
409
|
-
return std::optional<BleAndroidErrorCode>(value);
|
|
410
|
-
}
|
|
411
|
-
|
|
412
|
-
// pragma MARK: std::optional<NativeBleError>
|
|
413
|
-
/**
|
|
414
|
-
* Specialized version of `std::optional<NativeBleError>`.
|
|
415
|
-
*/
|
|
416
|
-
using std__optional_NativeBleError_ = std::optional<NativeBleError>;
|
|
417
|
-
inline std::optional<NativeBleError> create_std__optional_NativeBleError_(const NativeBleError& value) {
|
|
418
|
-
return std::optional<NativeBleError>(value);
|
|
419
|
-
}
|
|
420
|
-
|
|
421
|
-
// pragma MARK: std::optional<NativeDevice>
|
|
422
|
-
/**
|
|
423
|
-
* Specialized version of `std::optional<NativeDevice>`.
|
|
424
|
-
*/
|
|
425
|
-
using std__optional_NativeDevice_ = std::optional<NativeDevice>;
|
|
426
|
-
inline std::optional<NativeDevice> create_std__optional_NativeDevice_(const NativeDevice& value) {
|
|
427
|
-
return std::optional<NativeDevice>(value);
|
|
428
|
-
}
|
|
429
|
-
|
|
430
|
-
// pragma MARK: std::function<void(const std::optional<NativeBleError>& /* error */, const std::optional<NativeDevice>& /* scannedDevice */)>
|
|
431
|
-
/**
|
|
432
|
-
* Specialized version of `std::function<void(const std::optional<NativeBleError>&, const std::optional<NativeDevice>&)>`.
|
|
433
|
-
*/
|
|
434
|
-
using Func_void_std__optional_NativeBleError__std__optional_NativeDevice_ = std::function<void(const std::optional<NativeBleError>& /* error */, const std::optional<NativeDevice>& /* scannedDevice */)>;
|
|
435
|
-
/**
|
|
436
|
-
* Wrapper class for a `std::function<void(const std::optional<NativeBleError>& / * error * /, const std::optional<NativeDevice>& / * scannedDevice * /)>`, this can be used from Swift.
|
|
437
|
-
*/
|
|
438
|
-
class Func_void_std__optional_NativeBleError__std__optional_NativeDevice__Wrapper final {
|
|
439
|
-
public:
|
|
440
|
-
explicit Func_void_std__optional_NativeBleError__std__optional_NativeDevice__Wrapper(std::function<void(const std::optional<NativeBleError>& /* error */, const std::optional<NativeDevice>& /* scannedDevice */)>&& func): _function(std::make_unique<std::function<void(const std::optional<NativeBleError>& /* error */, const std::optional<NativeDevice>& /* scannedDevice */)>>(std::move(func))) {}
|
|
441
|
-
inline void call(std::optional<NativeBleError> error, std::optional<NativeDevice> scannedDevice) const {
|
|
442
|
-
_function->operator()(error, scannedDevice);
|
|
443
|
-
}
|
|
444
|
-
private:
|
|
445
|
-
std::unique_ptr<std::function<void(const std::optional<NativeBleError>& /* error */, const std::optional<NativeDevice>& /* scannedDevice */)>> _function;
|
|
446
|
-
} SWIFT_NONCOPYABLE;
|
|
447
|
-
Func_void_std__optional_NativeBleError__std__optional_NativeDevice_ create_Func_void_std__optional_NativeBleError__std__optional_NativeDevice_(void* _Nonnull swiftClosureWrapper);
|
|
448
|
-
inline Func_void_std__optional_NativeBleError__std__optional_NativeDevice__Wrapper wrap_Func_void_std__optional_NativeBleError__std__optional_NativeDevice_(Func_void_std__optional_NativeBleError__std__optional_NativeDevice_ value) {
|
|
449
|
-
return Func_void_std__optional_NativeBleError__std__optional_NativeDevice__Wrapper(std::move(value));
|
|
450
|
-
}
|
|
451
|
-
|
|
452
|
-
// pragma MARK: std::shared_ptr<Promise<NativeDevice>>
|
|
453
|
-
/**
|
|
454
|
-
* Specialized version of `std::shared_ptr<Promise<NativeDevice>>`.
|
|
455
|
-
*/
|
|
456
|
-
using std__shared_ptr_Promise_NativeDevice__ = std::shared_ptr<Promise<NativeDevice>>;
|
|
457
|
-
inline std::shared_ptr<Promise<NativeDevice>> create_std__shared_ptr_Promise_NativeDevice__() {
|
|
458
|
-
return Promise<NativeDevice>::create();
|
|
459
|
-
}
|
|
460
|
-
inline PromiseHolder<NativeDevice> wrap_std__shared_ptr_Promise_NativeDevice__(std::shared_ptr<Promise<NativeDevice>> promise) {
|
|
461
|
-
return PromiseHolder<NativeDevice>(std::move(promise));
|
|
74
|
+
using std__vector_ManufacturerDataEntry_ = std::vector<ManufacturerDataEntry>;
|
|
75
|
+
inline std::vector<ManufacturerDataEntry> create_std__vector_ManufacturerDataEntry_(size_t size) {
|
|
76
|
+
std::vector<ManufacturerDataEntry> vector;
|
|
77
|
+
vector.reserve(size);
|
|
78
|
+
return vector;
|
|
462
79
|
}
|
|
463
80
|
|
|
464
|
-
// pragma MARK: std::function<void(const
|
|
81
|
+
// pragma MARK: std::function<void(const BLEDevice& /* device */)>
|
|
465
82
|
/**
|
|
466
|
-
* Specialized version of `std::function<void(const
|
|
83
|
+
* Specialized version of `std::function<void(const BLEDevice&)>`.
|
|
467
84
|
*/
|
|
468
|
-
using
|
|
85
|
+
using Func_void_BLEDevice = std::function<void(const BLEDevice& /* device */)>;
|
|
469
86
|
/**
|
|
470
|
-
* Wrapper class for a `std::function<void(const
|
|
87
|
+
* Wrapper class for a `std::function<void(const BLEDevice& / * device * /)>`, this can be used from Swift.
|
|
471
88
|
*/
|
|
472
|
-
class
|
|
89
|
+
class Func_void_BLEDevice_Wrapper final {
|
|
473
90
|
public:
|
|
474
|
-
explicit
|
|
475
|
-
inline void call(
|
|
476
|
-
_function->operator()(
|
|
91
|
+
explicit Func_void_BLEDevice_Wrapper(std::function<void(const BLEDevice& /* device */)>&& func): _function(std::make_unique<std::function<void(const BLEDevice& /* device */)>>(std::move(func))) {}
|
|
92
|
+
inline void call(BLEDevice device) const {
|
|
93
|
+
_function->operator()(device);
|
|
477
94
|
}
|
|
478
95
|
private:
|
|
479
|
-
std::unique_ptr<std::function<void(const
|
|
96
|
+
std::unique_ptr<std::function<void(const BLEDevice& /* device */)>> _function;
|
|
480
97
|
} SWIFT_NONCOPYABLE;
|
|
481
|
-
|
|
482
|
-
inline
|
|
483
|
-
return
|
|
98
|
+
Func_void_BLEDevice create_Func_void_BLEDevice(void* _Nonnull swiftClosureWrapper);
|
|
99
|
+
inline Func_void_BLEDevice_Wrapper wrap_Func_void_BLEDevice(Func_void_BLEDevice value) {
|
|
100
|
+
return Func_void_BLEDevice_Wrapper(std::move(value));
|
|
484
101
|
}
|
|
485
102
|
|
|
486
|
-
// pragma MARK: std::
|
|
103
|
+
// pragma MARK: std::function<void(bool /* success */, const std::string& /* error */)>
|
|
487
104
|
/**
|
|
488
|
-
* Specialized version of `std::
|
|
105
|
+
* Specialized version of `std::function<void(bool, const std::string&)>`.
|
|
489
106
|
*/
|
|
490
|
-
using
|
|
491
|
-
inline std::shared_ptr<Promise<std::vector<NativeDevice>>> create_std__shared_ptr_Promise_std__vector_NativeDevice___() {
|
|
492
|
-
return Promise<std::vector<NativeDevice>>::create();
|
|
493
|
-
}
|
|
494
|
-
inline PromiseHolder<std::vector<NativeDevice>> wrap_std__shared_ptr_Promise_std__vector_NativeDevice___(std::shared_ptr<Promise<std::vector<NativeDevice>>> promise) {
|
|
495
|
-
return PromiseHolder<std::vector<NativeDevice>>(std::move(promise));
|
|
496
|
-
}
|
|
497
|
-
|
|
498
|
-
// pragma MARK: std::function<void(const std::vector<NativeDevice>& /* result */)>
|
|
107
|
+
using Func_void_bool_std__string = std::function<void(bool /* success */, const std::string& /* error */)>;
|
|
499
108
|
/**
|
|
500
|
-
*
|
|
109
|
+
* Wrapper class for a `std::function<void(bool / * success * /, const std::string& / * error * /)>`, this can be used from Swift.
|
|
501
110
|
*/
|
|
502
|
-
|
|
503
|
-
/**
|
|
504
|
-
* Wrapper class for a `std::function<void(const std::vector<NativeDevice>& / * result * /)>`, this can be used from Swift.
|
|
505
|
-
*/
|
|
506
|
-
class Func_void_std__vector_NativeDevice__Wrapper final {
|
|
111
|
+
class Func_void_bool_std__string_Wrapper final {
|
|
507
112
|
public:
|
|
508
|
-
explicit
|
|
509
|
-
inline void call(std::
|
|
510
|
-
_function->operator()(
|
|
113
|
+
explicit Func_void_bool_std__string_Wrapper(std::function<void(bool /* success */, const std::string& /* error */)>&& func): _function(std::make_unique<std::function<void(bool /* success */, const std::string& /* error */)>>(std::move(func))) {}
|
|
114
|
+
inline void call(bool success, std::string error) const {
|
|
115
|
+
_function->operator()(success, error);
|
|
511
116
|
}
|
|
512
117
|
private:
|
|
513
|
-
std::unique_ptr<std::function<void(const std::
|
|
118
|
+
std::unique_ptr<std::function<void(bool /* success */, const std::string& /* error */)>> _function;
|
|
514
119
|
} SWIFT_NONCOPYABLE;
|
|
515
|
-
|
|
516
|
-
inline
|
|
517
|
-
return
|
|
518
|
-
}
|
|
519
|
-
|
|
520
|
-
// pragma MARK: std::optional<ConnectionOptions>
|
|
521
|
-
/**
|
|
522
|
-
* Specialized version of `std::optional<ConnectionOptions>`.
|
|
523
|
-
*/
|
|
524
|
-
using std__optional_ConnectionOptions_ = std::optional<ConnectionOptions>;
|
|
525
|
-
inline std::optional<ConnectionOptions> create_std__optional_ConnectionOptions_(const ConnectionOptions& value) {
|
|
526
|
-
return std::optional<ConnectionOptions>(value);
|
|
527
|
-
}
|
|
528
|
-
|
|
529
|
-
// pragma MARK: std::shared_ptr<Promise<bool>>
|
|
530
|
-
/**
|
|
531
|
-
* Specialized version of `std::shared_ptr<Promise<bool>>`.
|
|
532
|
-
*/
|
|
533
|
-
using std__shared_ptr_Promise_bool__ = std::shared_ptr<Promise<bool>>;
|
|
534
|
-
inline std::shared_ptr<Promise<bool>> create_std__shared_ptr_Promise_bool__() {
|
|
535
|
-
return Promise<bool>::create();
|
|
536
|
-
}
|
|
537
|
-
inline PromiseHolder<bool> wrap_std__shared_ptr_Promise_bool__(std::shared_ptr<Promise<bool>> promise) {
|
|
538
|
-
return PromiseHolder<bool>(std::move(promise));
|
|
120
|
+
Func_void_bool_std__string create_Func_void_bool_std__string(void* _Nonnull swiftClosureWrapper);
|
|
121
|
+
inline Func_void_bool_std__string_Wrapper wrap_Func_void_bool_std__string(Func_void_bool_std__string value) {
|
|
122
|
+
return Func_void_bool_std__string_Wrapper(std::move(value));
|
|
539
123
|
}
|
|
540
124
|
|
|
541
125
|
// pragma MARK: std::function<void(bool /* result */)>
|
|
@@ -560,510 +144,264 @@ namespace margelo::nitro::co::zyke::ble::bridge::swift {
|
|
|
560
144
|
return Func_void_bool_Wrapper(std::move(value));
|
|
561
145
|
}
|
|
562
146
|
|
|
563
|
-
// pragma MARK: std::vector<
|
|
147
|
+
// pragma MARK: std::vector<BLEDevice>
|
|
564
148
|
/**
|
|
565
|
-
* Specialized version of `std::vector<
|
|
149
|
+
* Specialized version of `std::vector<BLEDevice>`.
|
|
566
150
|
*/
|
|
567
|
-
using
|
|
568
|
-
inline std::vector<
|
|
569
|
-
std::vector<
|
|
151
|
+
using std__vector_BLEDevice_ = std::vector<BLEDevice>;
|
|
152
|
+
inline std::vector<BLEDevice> create_std__vector_BLEDevice_(size_t size) {
|
|
153
|
+
std::vector<BLEDevice> vector;
|
|
570
154
|
vector.reserve(size);
|
|
571
155
|
return vector;
|
|
572
156
|
}
|
|
573
157
|
|
|
574
|
-
// pragma MARK: std::
|
|
575
|
-
/**
|
|
576
|
-
* Specialized version of `std::shared_ptr<Promise<std::vector<NativeService>>>`.
|
|
577
|
-
*/
|
|
578
|
-
using std__shared_ptr_Promise_std__vector_NativeService___ = std::shared_ptr<Promise<std::vector<NativeService>>>;
|
|
579
|
-
inline std::shared_ptr<Promise<std::vector<NativeService>>> create_std__shared_ptr_Promise_std__vector_NativeService___() {
|
|
580
|
-
return Promise<std::vector<NativeService>>::create();
|
|
581
|
-
}
|
|
582
|
-
inline PromiseHolder<std::vector<NativeService>> wrap_std__shared_ptr_Promise_std__vector_NativeService___(std::shared_ptr<Promise<std::vector<NativeService>>> promise) {
|
|
583
|
-
return PromiseHolder<std::vector<NativeService>>(std::move(promise));
|
|
584
|
-
}
|
|
585
|
-
|
|
586
|
-
// pragma MARK: std::function<void(const std::vector<NativeService>& /* result */)>
|
|
158
|
+
// pragma MARK: std::function<void(const std::vector<BLEDevice>& /* devices */)>
|
|
587
159
|
/**
|
|
588
|
-
* Specialized version of `std::function<void(const std::vector<
|
|
160
|
+
* Specialized version of `std::function<void(const std::vector<BLEDevice>&)>`.
|
|
589
161
|
*/
|
|
590
|
-
using
|
|
162
|
+
using Func_void_std__vector_BLEDevice_ = std::function<void(const std::vector<BLEDevice>& /* devices */)>;
|
|
591
163
|
/**
|
|
592
|
-
* Wrapper class for a `std::function<void(const std::vector<
|
|
164
|
+
* Wrapper class for a `std::function<void(const std::vector<BLEDevice>& / * devices * /)>`, this can be used from Swift.
|
|
593
165
|
*/
|
|
594
|
-
class
|
|
166
|
+
class Func_void_std__vector_BLEDevice__Wrapper final {
|
|
595
167
|
public:
|
|
596
|
-
explicit
|
|
597
|
-
inline void call(std::vector<
|
|
598
|
-
_function->operator()(
|
|
168
|
+
explicit Func_void_std__vector_BLEDevice__Wrapper(std::function<void(const std::vector<BLEDevice>& /* devices */)>&& func): _function(std::make_unique<std::function<void(const std::vector<BLEDevice>& /* devices */)>>(std::move(func))) {}
|
|
169
|
+
inline void call(std::vector<BLEDevice> devices) const {
|
|
170
|
+
_function->operator()(devices);
|
|
599
171
|
}
|
|
600
172
|
private:
|
|
601
|
-
std::unique_ptr<std::function<void(const std::vector<
|
|
173
|
+
std::unique_ptr<std::function<void(const std::vector<BLEDevice>& /* devices */)>> _function;
|
|
602
174
|
} SWIFT_NONCOPYABLE;
|
|
603
|
-
|
|
604
|
-
inline
|
|
605
|
-
return
|
|
175
|
+
Func_void_std__vector_BLEDevice_ create_Func_void_std__vector_BLEDevice_(void* _Nonnull swiftClosureWrapper);
|
|
176
|
+
inline Func_void_std__vector_BLEDevice__Wrapper wrap_Func_void_std__vector_BLEDevice_(Func_void_std__vector_BLEDevice_ value) {
|
|
177
|
+
return Func_void_std__vector_BLEDevice__Wrapper(std::move(value));
|
|
606
178
|
}
|
|
607
179
|
|
|
608
|
-
// pragma MARK: std::
|
|
180
|
+
// pragma MARK: std::function<void(bool /* success */, const std::string& /* deviceId */, const std::string& /* error */)>
|
|
609
181
|
/**
|
|
610
|
-
* Specialized version of `std::
|
|
182
|
+
* Specialized version of `std::function<void(bool, const std::string&, const std::string&)>`.
|
|
611
183
|
*/
|
|
612
|
-
using
|
|
613
|
-
inline std::vector<NativeCharacteristic> create_std__vector_NativeCharacteristic_(size_t size) {
|
|
614
|
-
std::vector<NativeCharacteristic> vector;
|
|
615
|
-
vector.reserve(size);
|
|
616
|
-
return vector;
|
|
617
|
-
}
|
|
618
|
-
|
|
619
|
-
// pragma MARK: std::shared_ptr<Promise<std::vector<NativeCharacteristic>>>
|
|
184
|
+
using Func_void_bool_std__string_std__string = std::function<void(bool /* success */, const std::string& /* deviceId */, const std::string& /* error */)>;
|
|
620
185
|
/**
|
|
621
|
-
*
|
|
186
|
+
* Wrapper class for a `std::function<void(bool / * success * /, const std::string& / * deviceId * /, const std::string& / * error * /)>`, this can be used from Swift.
|
|
622
187
|
*/
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
188
|
+
class Func_void_bool_std__string_std__string_Wrapper final {
|
|
189
|
+
public:
|
|
190
|
+
explicit Func_void_bool_std__string_std__string_Wrapper(std::function<void(bool /* success */, const std::string& /* deviceId */, const std::string& /* error */)>&& func): _function(std::make_unique<std::function<void(bool /* success */, const std::string& /* deviceId */, const std::string& /* error */)>>(std::move(func))) {}
|
|
191
|
+
inline void call(bool success, std::string deviceId, std::string error) const {
|
|
192
|
+
_function->operator()(success, deviceId, error);
|
|
193
|
+
}
|
|
194
|
+
private:
|
|
195
|
+
std::unique_ptr<std::function<void(bool /* success */, const std::string& /* deviceId */, const std::string& /* error */)>> _function;
|
|
196
|
+
} SWIFT_NONCOPYABLE;
|
|
197
|
+
Func_void_bool_std__string_std__string create_Func_void_bool_std__string_std__string(void* _Nonnull swiftClosureWrapper);
|
|
198
|
+
inline Func_void_bool_std__string_std__string_Wrapper wrap_Func_void_bool_std__string_std__string(Func_void_bool_std__string_std__string value) {
|
|
199
|
+
return Func_void_bool_std__string_std__string_Wrapper(std::move(value));
|
|
629
200
|
}
|
|
630
201
|
|
|
631
|
-
// pragma MARK: std::function<void(const std::
|
|
202
|
+
// pragma MARK: std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>
|
|
632
203
|
/**
|
|
633
|
-
* Specialized version of `std::function<void(const std::
|
|
204
|
+
* Specialized version of `std::function<void(const std::string&, bool, const std::string&)>`.
|
|
634
205
|
*/
|
|
635
|
-
using
|
|
206
|
+
using Func_void_std__string_bool_std__string = std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>;
|
|
636
207
|
/**
|
|
637
|
-
* Wrapper class for a `std::function<void(const std::
|
|
208
|
+
* Wrapper class for a `std::function<void(const std::string& / * deviceId * /, bool / * interrupted * /, const std::string& / * error * /)>`, this can be used from Swift.
|
|
638
209
|
*/
|
|
639
|
-
class
|
|
210
|
+
class Func_void_std__string_bool_std__string_Wrapper final {
|
|
640
211
|
public:
|
|
641
|
-
explicit
|
|
642
|
-
inline void call(std::
|
|
643
|
-
_function->operator()(
|
|
212
|
+
explicit Func_void_std__string_bool_std__string_Wrapper(std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>&& func): _function(std::make_unique<std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>>(std::move(func))) {}
|
|
213
|
+
inline void call(std::string deviceId, bool interrupted, std::string error) const {
|
|
214
|
+
_function->operator()(deviceId, interrupted, error);
|
|
644
215
|
}
|
|
645
216
|
private:
|
|
646
|
-
std::unique_ptr<std::function<void(const std::
|
|
217
|
+
std::unique_ptr<std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>> _function;
|
|
647
218
|
} SWIFT_NONCOPYABLE;
|
|
648
|
-
|
|
649
|
-
inline
|
|
650
|
-
return
|
|
219
|
+
Func_void_std__string_bool_std__string create_Func_void_std__string_bool_std__string(void* _Nonnull swiftClosureWrapper);
|
|
220
|
+
inline Func_void_std__string_bool_std__string_Wrapper wrap_Func_void_std__string_bool_std__string(Func_void_std__string_bool_std__string value) {
|
|
221
|
+
return Func_void_std__string_bool_std__string_Wrapper(std::move(value));
|
|
651
222
|
}
|
|
652
223
|
|
|
653
|
-
// pragma MARK: std::
|
|
224
|
+
// pragma MARK: std::optional<std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>>
|
|
654
225
|
/**
|
|
655
|
-
* Specialized version of `std::
|
|
226
|
+
* Specialized version of `std::optional<std::function<void(const std::string& / * deviceId * /, bool / * interrupted * /, const std::string& / * error * /)>>`.
|
|
656
227
|
*/
|
|
657
|
-
using
|
|
658
|
-
inline std::
|
|
659
|
-
return
|
|
660
|
-
}
|
|
661
|
-
inline PromiseHolder<NativeCharacteristic> wrap_std__shared_ptr_Promise_NativeCharacteristic__(std::shared_ptr<Promise<NativeCharacteristic>> promise) {
|
|
662
|
-
return PromiseHolder<NativeCharacteristic>(std::move(promise));
|
|
228
|
+
using std__optional_std__function_void_const_std__string_____deviceId_____bool____interrupted_____const_std__string_____error______ = std::optional<std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>>;
|
|
229
|
+
inline std::optional<std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>> create_std__optional_std__function_void_const_std__string_____deviceId_____bool____interrupted_____const_std__string_____error______(const std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>& value) {
|
|
230
|
+
return std::optional<std::function<void(const std::string& /* deviceId */, bool /* interrupted */, const std::string& /* error */)>>(value);
|
|
663
231
|
}
|
|
664
232
|
|
|
665
|
-
// pragma MARK: std::function<void(const
|
|
233
|
+
// pragma MARK: std::function<void(const std::vector<std::string>& /* result */)>
|
|
666
234
|
/**
|
|
667
|
-
* Specialized version of `std::function<void(const
|
|
235
|
+
* Specialized version of `std::function<void(const std::vector<std::string>&)>`.
|
|
668
236
|
*/
|
|
669
|
-
using
|
|
237
|
+
using Func_void_std__vector_std__string_ = std::function<void(const std::vector<std::string>& /* result */)>;
|
|
670
238
|
/**
|
|
671
|
-
* Wrapper class for a `std::function<void(const
|
|
239
|
+
* Wrapper class for a `std::function<void(const std::vector<std::string>& / * result * /)>`, this can be used from Swift.
|
|
672
240
|
*/
|
|
673
|
-
class
|
|
241
|
+
class Func_void_std__vector_std__string__Wrapper final {
|
|
674
242
|
public:
|
|
675
|
-
explicit
|
|
676
|
-
inline void call(
|
|
243
|
+
explicit Func_void_std__vector_std__string__Wrapper(std::function<void(const std::vector<std::string>& /* result */)>&& func): _function(std::make_unique<std::function<void(const std::vector<std::string>& /* result */)>>(std::move(func))) {}
|
|
244
|
+
inline void call(std::vector<std::string> result) const {
|
|
677
245
|
_function->operator()(result);
|
|
678
246
|
}
|
|
679
247
|
private:
|
|
680
|
-
std::unique_ptr<std::function<void(const
|
|
248
|
+
std::unique_ptr<std::function<void(const std::vector<std::string>& /* result */)>> _function;
|
|
681
249
|
} SWIFT_NONCOPYABLE;
|
|
682
|
-
|
|
683
|
-
inline
|
|
684
|
-
return
|
|
685
|
-
}
|
|
686
|
-
|
|
687
|
-
// pragma MARK: std::optional<NativeCharacteristic>
|
|
688
|
-
/**
|
|
689
|
-
* Specialized version of `std::optional<NativeCharacteristic>`.
|
|
690
|
-
*/
|
|
691
|
-
using std__optional_NativeCharacteristic_ = std::optional<NativeCharacteristic>;
|
|
692
|
-
inline std::optional<NativeCharacteristic> create_std__optional_NativeCharacteristic_(const NativeCharacteristic& value) {
|
|
693
|
-
return std::optional<NativeCharacteristic>(value);
|
|
250
|
+
Func_void_std__vector_std__string_ create_Func_void_std__vector_std__string_(void* _Nonnull swiftClosureWrapper);
|
|
251
|
+
inline Func_void_std__vector_std__string__Wrapper wrap_Func_void_std__vector_std__string_(Func_void_std__vector_std__string_ value) {
|
|
252
|
+
return Func_void_std__vector_std__string__Wrapper(std::move(value));
|
|
694
253
|
}
|
|
695
254
|
|
|
696
|
-
// pragma MARK: std::function<void(const std::
|
|
255
|
+
// pragma MARK: std::function<void(bool /* success */, const std::vector<double>& /* data */, const std::string& /* error */)>
|
|
697
256
|
/**
|
|
698
|
-
* Specialized version of `std::function<void(const std::
|
|
257
|
+
* Specialized version of `std::function<void(bool, const std::vector<double>&, const std::string&)>`.
|
|
699
258
|
*/
|
|
700
|
-
using
|
|
259
|
+
using Func_void_bool_std__vector_double__std__string = std::function<void(bool /* success */, const std::vector<double>& /* data */, const std::string& /* error */)>;
|
|
701
260
|
/**
|
|
702
|
-
* Wrapper class for a `std::function<void(const std::
|
|
261
|
+
* Wrapper class for a `std::function<void(bool / * success * /, const std::vector<double>& / * data * /, const std::string& / * error * /)>`, this can be used from Swift.
|
|
703
262
|
*/
|
|
704
|
-
class
|
|
263
|
+
class Func_void_bool_std__vector_double__std__string_Wrapper final {
|
|
705
264
|
public:
|
|
706
|
-
explicit
|
|
707
|
-
inline void call(std::
|
|
708
|
-
_function->operator()(
|
|
265
|
+
explicit Func_void_bool_std__vector_double__std__string_Wrapper(std::function<void(bool /* success */, const std::vector<double>& /* data */, const std::string& /* error */)>&& func): _function(std::make_unique<std::function<void(bool /* success */, const std::vector<double>& /* data */, const std::string& /* error */)>>(std::move(func))) {}
|
|
266
|
+
inline void call(bool success, std::vector<double> data, std::string error) const {
|
|
267
|
+
_function->operator()(success, data, error);
|
|
709
268
|
}
|
|
710
269
|
private:
|
|
711
|
-
std::unique_ptr<std::function<void(const std::
|
|
270
|
+
std::unique_ptr<std::function<void(bool /* success */, const std::vector<double>& /* data */, const std::string& /* error */)>> _function;
|
|
712
271
|
} SWIFT_NONCOPYABLE;
|
|
713
|
-
|
|
714
|
-
inline
|
|
715
|
-
return
|
|
272
|
+
Func_void_bool_std__vector_double__std__string create_Func_void_bool_std__vector_double__std__string(void* _Nonnull swiftClosureWrapper);
|
|
273
|
+
inline Func_void_bool_std__vector_double__std__string_Wrapper wrap_Func_void_bool_std__vector_double__std__string(Func_void_bool_std__vector_double__std__string value) {
|
|
274
|
+
return Func_void_bool_std__vector_double__std__string_Wrapper(std::move(value));
|
|
716
275
|
}
|
|
717
276
|
|
|
718
|
-
// pragma MARK: std::
|
|
277
|
+
// pragma MARK: std::function<void(const std::string& /* characteristicId */, const std::vector<double>& /* data */)>
|
|
719
278
|
/**
|
|
720
|
-
* Specialized version of `std::
|
|
279
|
+
* Specialized version of `std::function<void(const std::string&, const std::vector<double>&)>`.
|
|
721
280
|
*/
|
|
722
|
-
using
|
|
723
|
-
inline std::optional<CharacteristicSubscriptionType> create_std__optional_CharacteristicSubscriptionType_(const CharacteristicSubscriptionType& value) {
|
|
724
|
-
return std::optional<CharacteristicSubscriptionType>(value);
|
|
725
|
-
}
|
|
726
|
-
|
|
727
|
-
// pragma MARK: std::vector<NativeDescriptor>
|
|
281
|
+
using Func_void_std__string_std__vector_double_ = std::function<void(const std::string& /* characteristicId */, const std::vector<double>& /* data */)>;
|
|
728
282
|
/**
|
|
729
|
-
*
|
|
283
|
+
* Wrapper class for a `std::function<void(const std::string& / * characteristicId * /, const std::vector<double>& / * data * /)>`, this can be used from Swift.
|
|
730
284
|
*/
|
|
731
|
-
|
|
732
|
-
inline std::vector<NativeDescriptor> create_std__vector_NativeDescriptor_(size_t size) {
|
|
733
|
-
std::vector<NativeDescriptor> vector;
|
|
734
|
-
vector.reserve(size);
|
|
735
|
-
return vector;
|
|
736
|
-
}
|
|
737
|
-
|
|
738
|
-
// pragma MARK: std::shared_ptr<Promise<std::vector<NativeDescriptor>>>
|
|
739
|
-
/**
|
|
740
|
-
* Specialized version of `std::shared_ptr<Promise<std::vector<NativeDescriptor>>>`.
|
|
741
|
-
*/
|
|
742
|
-
using std__shared_ptr_Promise_std__vector_NativeDescriptor___ = std::shared_ptr<Promise<std::vector<NativeDescriptor>>>;
|
|
743
|
-
inline std::shared_ptr<Promise<std::vector<NativeDescriptor>>> create_std__shared_ptr_Promise_std__vector_NativeDescriptor___() {
|
|
744
|
-
return Promise<std::vector<NativeDescriptor>>::create();
|
|
745
|
-
}
|
|
746
|
-
inline PromiseHolder<std::vector<NativeDescriptor>> wrap_std__shared_ptr_Promise_std__vector_NativeDescriptor___(std::shared_ptr<Promise<std::vector<NativeDescriptor>>> promise) {
|
|
747
|
-
return PromiseHolder<std::vector<NativeDescriptor>>(std::move(promise));
|
|
748
|
-
}
|
|
749
|
-
|
|
750
|
-
// pragma MARK: std::function<void(const std::vector<NativeDescriptor>& /* result */)>
|
|
751
|
-
/**
|
|
752
|
-
* Specialized version of `std::function<void(const std::vector<NativeDescriptor>&)>`.
|
|
753
|
-
*/
|
|
754
|
-
using Func_void_std__vector_NativeDescriptor_ = std::function<void(const std::vector<NativeDescriptor>& /* result */)>;
|
|
755
|
-
/**
|
|
756
|
-
* Wrapper class for a `std::function<void(const std::vector<NativeDescriptor>& / * result * /)>`, this can be used from Swift.
|
|
757
|
-
*/
|
|
758
|
-
class Func_void_std__vector_NativeDescriptor__Wrapper final {
|
|
285
|
+
class Func_void_std__string_std__vector_double__Wrapper final {
|
|
759
286
|
public:
|
|
760
|
-
explicit
|
|
761
|
-
inline void call(std::vector<
|
|
762
|
-
_function->operator()(
|
|
287
|
+
explicit Func_void_std__string_std__vector_double__Wrapper(std::function<void(const std::string& /* characteristicId */, const std::vector<double>& /* data */)>&& func): _function(std::make_unique<std::function<void(const std::string& /* characteristicId */, const std::vector<double>& /* data */)>>(std::move(func))) {}
|
|
288
|
+
inline void call(std::string characteristicId, std::vector<double> data) const {
|
|
289
|
+
_function->operator()(characteristicId, data);
|
|
763
290
|
}
|
|
764
291
|
private:
|
|
765
|
-
std::unique_ptr<std::function<void(const std::vector<
|
|
292
|
+
std::unique_ptr<std::function<void(const std::string& /* characteristicId */, const std::vector<double>& /* data */)>> _function;
|
|
766
293
|
} SWIFT_NONCOPYABLE;
|
|
767
|
-
|
|
768
|
-
inline
|
|
769
|
-
return
|
|
294
|
+
Func_void_std__string_std__vector_double_ create_Func_void_std__string_std__vector_double_(void* _Nonnull swiftClosureWrapper);
|
|
295
|
+
inline Func_void_std__string_std__vector_double__Wrapper wrap_Func_void_std__string_std__vector_double_(Func_void_std__string_std__vector_double_ value) {
|
|
296
|
+
return Func_void_std__string_std__vector_double__Wrapper(std::move(value));
|
|
770
297
|
}
|
|
771
298
|
|
|
772
|
-
// pragma MARK: std::
|
|
299
|
+
// pragma MARK: std::function<void(BLEState /* state */)>
|
|
773
300
|
/**
|
|
774
|
-
* Specialized version of `std::
|
|
301
|
+
* Specialized version of `std::function<void(BLEState)>`.
|
|
775
302
|
*/
|
|
776
|
-
using
|
|
777
|
-
inline std::shared_ptr<Promise<NativeDescriptor>> create_std__shared_ptr_Promise_NativeDescriptor__() {
|
|
778
|
-
return Promise<NativeDescriptor>::create();
|
|
779
|
-
}
|
|
780
|
-
inline PromiseHolder<NativeDescriptor> wrap_std__shared_ptr_Promise_NativeDescriptor__(std::shared_ptr<Promise<NativeDescriptor>> promise) {
|
|
781
|
-
return PromiseHolder<NativeDescriptor>(std::move(promise));
|
|
782
|
-
}
|
|
783
|
-
|
|
784
|
-
// pragma MARK: std::function<void(const NativeDescriptor& /* result */)>
|
|
303
|
+
using Func_void_BLEState = std::function<void(BLEState /* state */)>;
|
|
785
304
|
/**
|
|
786
|
-
*
|
|
305
|
+
* Wrapper class for a `std::function<void(BLEState / * state * /)>`, this can be used from Swift.
|
|
787
306
|
*/
|
|
788
|
-
|
|
789
|
-
/**
|
|
790
|
-
* Wrapper class for a `std::function<void(const NativeDescriptor& / * result * /)>`, this can be used from Swift.
|
|
791
|
-
*/
|
|
792
|
-
class Func_void_NativeDescriptor_Wrapper final {
|
|
307
|
+
class Func_void_BLEState_Wrapper final {
|
|
793
308
|
public:
|
|
794
|
-
explicit
|
|
795
|
-
inline void call(
|
|
796
|
-
_function->operator()(
|
|
309
|
+
explicit Func_void_BLEState_Wrapper(std::function<void(BLEState /* state */)>&& func): _function(std::make_unique<std::function<void(BLEState /* state */)>>(std::move(func))) {}
|
|
310
|
+
inline void call(int state) const {
|
|
311
|
+
_function->operator()(static_cast<BLEState>(state));
|
|
797
312
|
}
|
|
798
313
|
private:
|
|
799
|
-
std::unique_ptr<std::function<void(
|
|
314
|
+
std::unique_ptr<std::function<void(BLEState /* state */)>> _function;
|
|
800
315
|
} SWIFT_NONCOPYABLE;
|
|
801
|
-
|
|
802
|
-
inline
|
|
803
|
-
return
|
|
804
|
-
}
|
|
805
|
-
|
|
806
|
-
// pragma MARK: std::shared_ptr<margelo::nitro::co::zyke::ble::HybridBleManagerSpec>
|
|
807
|
-
/**
|
|
808
|
-
* Specialized version of `std::shared_ptr<margelo::nitro::co::zyke::ble::HybridBleManagerSpec>`.
|
|
809
|
-
*/
|
|
810
|
-
using std__shared_ptr_margelo__nitro__co__zyke__ble__HybridBleManagerSpec_ = std::shared_ptr<margelo::nitro::co::zyke::ble::HybridBleManagerSpec>;
|
|
811
|
-
std::shared_ptr<margelo::nitro::co::zyke::ble::HybridBleManagerSpec> create_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridBleManagerSpec_(void* _Nonnull swiftUnsafePointer);
|
|
812
|
-
void* _Nonnull get_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridBleManagerSpec_(std__shared_ptr_margelo__nitro__co__zyke__ble__HybridBleManagerSpec_ cppType);
|
|
813
|
-
|
|
814
|
-
// pragma MARK: std::weak_ptr<margelo::nitro::co::zyke::ble::HybridBleManagerSpec>
|
|
815
|
-
using std__weak_ptr_margelo__nitro__co__zyke__ble__HybridBleManagerSpec_ = std::weak_ptr<margelo::nitro::co::zyke::ble::HybridBleManagerSpec>;
|
|
816
|
-
inline std__weak_ptr_margelo__nitro__co__zyke__ble__HybridBleManagerSpec_ weakify_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridBleManagerSpec_(const std::shared_ptr<margelo::nitro::co::zyke::ble::HybridBleManagerSpec>& strong) { return strong; }
|
|
817
|
-
|
|
818
|
-
// pragma MARK: Result<std::shared_ptr<Promise<void>>>
|
|
819
|
-
using Result_std__shared_ptr_Promise_void___ = Result<std::shared_ptr<Promise<void>>>;
|
|
820
|
-
inline Result_std__shared_ptr_Promise_void___ create_Result_std__shared_ptr_Promise_void___(const std::shared_ptr<Promise<void>>& value) {
|
|
821
|
-
return Result<std::shared_ptr<Promise<void>>>::withValue(value);
|
|
822
|
-
}
|
|
823
|
-
inline Result_std__shared_ptr_Promise_void___ create_Result_std__shared_ptr_Promise_void___(const std::exception_ptr& error) {
|
|
824
|
-
return Result<std::shared_ptr<Promise<void>>>::withError(error);
|
|
825
|
-
}
|
|
826
|
-
|
|
827
|
-
// pragma MARK: Result<std::shared_ptr<Promise<std::optional<BleRestoredState>>>>
|
|
828
|
-
using Result_std__shared_ptr_Promise_std__optional_BleRestoredState____ = Result<std::shared_ptr<Promise<std::optional<BleRestoredState>>>>;
|
|
829
|
-
inline Result_std__shared_ptr_Promise_std__optional_BleRestoredState____ create_Result_std__shared_ptr_Promise_std__optional_BleRestoredState____(const std::shared_ptr<Promise<std::optional<BleRestoredState>>>& value) {
|
|
830
|
-
return Result<std::shared_ptr<Promise<std::optional<BleRestoredState>>>>::withValue(value);
|
|
831
|
-
}
|
|
832
|
-
inline Result_std__shared_ptr_Promise_std__optional_BleRestoredState____ create_Result_std__shared_ptr_Promise_std__optional_BleRestoredState____(const std::exception_ptr& error) {
|
|
833
|
-
return Result<std::shared_ptr<Promise<std::optional<BleRestoredState>>>>::withError(error);
|
|
834
|
-
}
|
|
835
|
-
|
|
836
|
-
// pragma MARK: Result<std::shared_ptr<Promise<LogLevel>>>
|
|
837
|
-
using Result_std__shared_ptr_Promise_LogLevel___ = Result<std::shared_ptr<Promise<LogLevel>>>;
|
|
838
|
-
inline Result_std__shared_ptr_Promise_LogLevel___ create_Result_std__shared_ptr_Promise_LogLevel___(const std::shared_ptr<Promise<LogLevel>>& value) {
|
|
839
|
-
return Result<std::shared_ptr<Promise<LogLevel>>>::withValue(value);
|
|
840
|
-
}
|
|
841
|
-
inline Result_std__shared_ptr_Promise_LogLevel___ create_Result_std__shared_ptr_Promise_LogLevel___(const std::exception_ptr& error) {
|
|
842
|
-
return Result<std::shared_ptr<Promise<LogLevel>>>::withError(error);
|
|
843
|
-
}
|
|
844
|
-
|
|
845
|
-
// pragma MARK: Result<std::shared_ptr<Promise<State>>>
|
|
846
|
-
using Result_std__shared_ptr_Promise_State___ = Result<std::shared_ptr<Promise<State>>>;
|
|
847
|
-
inline Result_std__shared_ptr_Promise_State___ create_Result_std__shared_ptr_Promise_State___(const std::shared_ptr<Promise<State>>& value) {
|
|
848
|
-
return Result<std::shared_ptr<Promise<State>>>::withValue(value);
|
|
849
|
-
}
|
|
850
|
-
inline Result_std__shared_ptr_Promise_State___ create_Result_std__shared_ptr_Promise_State___(const std::exception_ptr& error) {
|
|
851
|
-
return Result<std::shared_ptr<Promise<State>>>::withError(error);
|
|
852
|
-
}
|
|
853
|
-
|
|
854
|
-
// pragma MARK: Result<Subscription>
|
|
855
|
-
using Result_Subscription_ = Result<Subscription>;
|
|
856
|
-
inline Result_Subscription_ create_Result_Subscription_(const Subscription& value) {
|
|
857
|
-
return Result<Subscription>::withValue(value);
|
|
858
|
-
}
|
|
859
|
-
inline Result_Subscription_ create_Result_Subscription_(const std::exception_ptr& error) {
|
|
860
|
-
return Result<Subscription>::withError(error);
|
|
861
|
-
}
|
|
862
|
-
|
|
863
|
-
// pragma MARK: Result<std::shared_ptr<Promise<NativeDevice>>>
|
|
864
|
-
using Result_std__shared_ptr_Promise_NativeDevice___ = Result<std::shared_ptr<Promise<NativeDevice>>>;
|
|
865
|
-
inline Result_std__shared_ptr_Promise_NativeDevice___ create_Result_std__shared_ptr_Promise_NativeDevice___(const std::shared_ptr<Promise<NativeDevice>>& value) {
|
|
866
|
-
return Result<std::shared_ptr<Promise<NativeDevice>>>::withValue(value);
|
|
867
|
-
}
|
|
868
|
-
inline Result_std__shared_ptr_Promise_NativeDevice___ create_Result_std__shared_ptr_Promise_NativeDevice___(const std::exception_ptr& error) {
|
|
869
|
-
return Result<std::shared_ptr<Promise<NativeDevice>>>::withError(error);
|
|
870
|
-
}
|
|
871
|
-
|
|
872
|
-
// pragma MARK: Result<std::shared_ptr<Promise<std::vector<NativeDevice>>>>
|
|
873
|
-
using Result_std__shared_ptr_Promise_std__vector_NativeDevice____ = Result<std::shared_ptr<Promise<std::vector<NativeDevice>>>>;
|
|
874
|
-
inline Result_std__shared_ptr_Promise_std__vector_NativeDevice____ create_Result_std__shared_ptr_Promise_std__vector_NativeDevice____(const std::shared_ptr<Promise<std::vector<NativeDevice>>>& value) {
|
|
875
|
-
return Result<std::shared_ptr<Promise<std::vector<NativeDevice>>>>::withValue(value);
|
|
876
|
-
}
|
|
877
|
-
inline Result_std__shared_ptr_Promise_std__vector_NativeDevice____ create_Result_std__shared_ptr_Promise_std__vector_NativeDevice____(const std::exception_ptr& error) {
|
|
878
|
-
return Result<std::shared_ptr<Promise<std::vector<NativeDevice>>>>::withError(error);
|
|
879
|
-
}
|
|
880
|
-
|
|
881
|
-
// pragma MARK: Result<std::shared_ptr<Promise<bool>>>
|
|
882
|
-
using Result_std__shared_ptr_Promise_bool___ = Result<std::shared_ptr<Promise<bool>>>;
|
|
883
|
-
inline Result_std__shared_ptr_Promise_bool___ create_Result_std__shared_ptr_Promise_bool___(const std::shared_ptr<Promise<bool>>& value) {
|
|
884
|
-
return Result<std::shared_ptr<Promise<bool>>>::withValue(value);
|
|
885
|
-
}
|
|
886
|
-
inline Result_std__shared_ptr_Promise_bool___ create_Result_std__shared_ptr_Promise_bool___(const std::exception_ptr& error) {
|
|
887
|
-
return Result<std::shared_ptr<Promise<bool>>>::withError(error);
|
|
888
|
-
}
|
|
889
|
-
|
|
890
|
-
// pragma MARK: Result<std::shared_ptr<Promise<std::vector<NativeService>>>>
|
|
891
|
-
using Result_std__shared_ptr_Promise_std__vector_NativeService____ = Result<std::shared_ptr<Promise<std::vector<NativeService>>>>;
|
|
892
|
-
inline Result_std__shared_ptr_Promise_std__vector_NativeService____ create_Result_std__shared_ptr_Promise_std__vector_NativeService____(const std::shared_ptr<Promise<std::vector<NativeService>>>& value) {
|
|
893
|
-
return Result<std::shared_ptr<Promise<std::vector<NativeService>>>>::withValue(value);
|
|
894
|
-
}
|
|
895
|
-
inline Result_std__shared_ptr_Promise_std__vector_NativeService____ create_Result_std__shared_ptr_Promise_std__vector_NativeService____(const std::exception_ptr& error) {
|
|
896
|
-
return Result<std::shared_ptr<Promise<std::vector<NativeService>>>>::withError(error);
|
|
897
|
-
}
|
|
898
|
-
|
|
899
|
-
// pragma MARK: Result<std::shared_ptr<Promise<std::vector<NativeCharacteristic>>>>
|
|
900
|
-
using Result_std__shared_ptr_Promise_std__vector_NativeCharacteristic____ = Result<std::shared_ptr<Promise<std::vector<NativeCharacteristic>>>>;
|
|
901
|
-
inline Result_std__shared_ptr_Promise_std__vector_NativeCharacteristic____ create_Result_std__shared_ptr_Promise_std__vector_NativeCharacteristic____(const std::shared_ptr<Promise<std::vector<NativeCharacteristic>>>& value) {
|
|
902
|
-
return Result<std::shared_ptr<Promise<std::vector<NativeCharacteristic>>>>::withValue(value);
|
|
903
|
-
}
|
|
904
|
-
inline Result_std__shared_ptr_Promise_std__vector_NativeCharacteristic____ create_Result_std__shared_ptr_Promise_std__vector_NativeCharacteristic____(const std::exception_ptr& error) {
|
|
905
|
-
return Result<std::shared_ptr<Promise<std::vector<NativeCharacteristic>>>>::withError(error);
|
|
906
|
-
}
|
|
907
|
-
|
|
908
|
-
// pragma MARK: Result<std::shared_ptr<Promise<NativeCharacteristic>>>
|
|
909
|
-
using Result_std__shared_ptr_Promise_NativeCharacteristic___ = Result<std::shared_ptr<Promise<NativeCharacteristic>>>;
|
|
910
|
-
inline Result_std__shared_ptr_Promise_NativeCharacteristic___ create_Result_std__shared_ptr_Promise_NativeCharacteristic___(const std::shared_ptr<Promise<NativeCharacteristic>>& value) {
|
|
911
|
-
return Result<std::shared_ptr<Promise<NativeCharacteristic>>>::withValue(value);
|
|
912
|
-
}
|
|
913
|
-
inline Result_std__shared_ptr_Promise_NativeCharacteristic___ create_Result_std__shared_ptr_Promise_NativeCharacteristic___(const std::exception_ptr& error) {
|
|
914
|
-
return Result<std::shared_ptr<Promise<NativeCharacteristic>>>::withError(error);
|
|
915
|
-
}
|
|
916
|
-
|
|
917
|
-
// pragma MARK: Result<std::shared_ptr<Promise<std::vector<NativeDescriptor>>>>
|
|
918
|
-
using Result_std__shared_ptr_Promise_std__vector_NativeDescriptor____ = Result<std::shared_ptr<Promise<std::vector<NativeDescriptor>>>>;
|
|
919
|
-
inline Result_std__shared_ptr_Promise_std__vector_NativeDescriptor____ create_Result_std__shared_ptr_Promise_std__vector_NativeDescriptor____(const std::shared_ptr<Promise<std::vector<NativeDescriptor>>>& value) {
|
|
920
|
-
return Result<std::shared_ptr<Promise<std::vector<NativeDescriptor>>>>::withValue(value);
|
|
921
|
-
}
|
|
922
|
-
inline Result_std__shared_ptr_Promise_std__vector_NativeDescriptor____ create_Result_std__shared_ptr_Promise_std__vector_NativeDescriptor____(const std::exception_ptr& error) {
|
|
923
|
-
return Result<std::shared_ptr<Promise<std::vector<NativeDescriptor>>>>::withError(error);
|
|
924
|
-
}
|
|
925
|
-
|
|
926
|
-
// pragma MARK: Result<std::shared_ptr<Promise<NativeDescriptor>>>
|
|
927
|
-
using Result_std__shared_ptr_Promise_NativeDescriptor___ = Result<std::shared_ptr<Promise<NativeDescriptor>>>;
|
|
928
|
-
inline Result_std__shared_ptr_Promise_NativeDescriptor___ create_Result_std__shared_ptr_Promise_NativeDescriptor___(const std::shared_ptr<Promise<NativeDescriptor>>& value) {
|
|
929
|
-
return Result<std::shared_ptr<Promise<NativeDescriptor>>>::withValue(value);
|
|
316
|
+
Func_void_BLEState create_Func_void_BLEState(void* _Nonnull swiftClosureWrapper);
|
|
317
|
+
inline Func_void_BLEState_Wrapper wrap_Func_void_BLEState(Func_void_BLEState value) {
|
|
318
|
+
return Func_void_BLEState_Wrapper(std::move(value));
|
|
930
319
|
}
|
|
931
|
-
inline Result_std__shared_ptr_Promise_NativeDescriptor___ create_Result_std__shared_ptr_Promise_NativeDescriptor___(const std::exception_ptr& error) {
|
|
932
|
-
return Result<std::shared_ptr<Promise<NativeDescriptor>>>::withError(error);
|
|
933
|
-
}
|
|
934
|
-
|
|
935
|
-
// pragma MARK: std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>
|
|
936
|
-
/**
|
|
937
|
-
* Specialized version of `std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>`.
|
|
938
|
-
*/
|
|
939
|
-
using std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec_ = std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>;
|
|
940
|
-
std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec> create_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec_(void* _Nonnull swiftUnsafePointer);
|
|
941
|
-
void* _Nonnull get_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec_(std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec_ cppType);
|
|
942
|
-
|
|
943
|
-
// pragma MARK: std::weak_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>
|
|
944
|
-
using std__weak_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec_ = std::weak_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>;
|
|
945
|
-
inline std__weak_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec_ weakify_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec_(const std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>& strong) { return strong; }
|
|
946
320
|
|
|
947
|
-
// pragma MARK: std::shared_ptr<Promise<
|
|
321
|
+
// pragma MARK: std::shared_ptr<Promise<void>>
|
|
948
322
|
/**
|
|
949
|
-
* Specialized version of `std::shared_ptr<Promise<
|
|
323
|
+
* Specialized version of `std::shared_ptr<Promise<void>>`.
|
|
950
324
|
*/
|
|
951
|
-
using
|
|
952
|
-
inline std::shared_ptr<Promise<
|
|
953
|
-
return Promise<
|
|
325
|
+
using std__shared_ptr_Promise_void__ = std::shared_ptr<Promise<void>>;
|
|
326
|
+
inline std::shared_ptr<Promise<void>> create_std__shared_ptr_Promise_void__() {
|
|
327
|
+
return Promise<void>::create();
|
|
954
328
|
}
|
|
955
|
-
inline PromiseHolder<
|
|
956
|
-
return PromiseHolder<
|
|
329
|
+
inline PromiseHolder<void> wrap_std__shared_ptr_Promise_void__(std::shared_ptr<Promise<void>> promise) {
|
|
330
|
+
return PromiseHolder<void>(std::move(promise));
|
|
957
331
|
}
|
|
958
332
|
|
|
959
|
-
// pragma MARK: std::function<void(
|
|
333
|
+
// pragma MARK: std::function<void()>
|
|
960
334
|
/**
|
|
961
|
-
* Specialized version of `std::function<void(
|
|
335
|
+
* Specialized version of `std::function<void()>`.
|
|
962
336
|
*/
|
|
963
|
-
using
|
|
337
|
+
using Func_void = std::function<void()>;
|
|
964
338
|
/**
|
|
965
|
-
* Wrapper class for a `std::function<void(
|
|
339
|
+
* Wrapper class for a `std::function<void()>`, this can be used from Swift.
|
|
966
340
|
*/
|
|
967
|
-
class
|
|
341
|
+
class Func_void_Wrapper final {
|
|
968
342
|
public:
|
|
969
|
-
explicit
|
|
970
|
-
inline void call(
|
|
971
|
-
_function->operator()(
|
|
343
|
+
explicit Func_void_Wrapper(std::function<void()>&& func): _function(std::make_unique<std::function<void()>>(std::move(func))) {}
|
|
344
|
+
inline void call() const {
|
|
345
|
+
_function->operator()();
|
|
972
346
|
}
|
|
973
347
|
private:
|
|
974
|
-
std::unique_ptr<std::function<void(
|
|
348
|
+
std::unique_ptr<std::function<void()>> _function;
|
|
975
349
|
} SWIFT_NONCOPYABLE;
|
|
976
|
-
|
|
977
|
-
inline
|
|
978
|
-
return
|
|
979
|
-
}
|
|
980
|
-
|
|
981
|
-
// pragma MARK: Result<std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>>>>
|
|
982
|
-
using Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec____ = Result<std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>>>>;
|
|
983
|
-
inline Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec____ create_Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec____(const std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>>>& value) {
|
|
984
|
-
return Result<std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>>>>::withValue(value);
|
|
985
|
-
}
|
|
986
|
-
inline Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec____ create_Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridCharacteristicSpec____(const std::exception_ptr& error) {
|
|
987
|
-
return Result<std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridCharacteristicSpec>>>>::withError(error);
|
|
988
|
-
}
|
|
989
|
-
|
|
990
|
-
// pragma MARK: std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>
|
|
991
|
-
/**
|
|
992
|
-
* Specialized version of `std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>`.
|
|
993
|
-
*/
|
|
994
|
-
using std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec_ = std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>;
|
|
995
|
-
std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec> create_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec_(void* _Nonnull swiftUnsafePointer);
|
|
996
|
-
void* _Nonnull get_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec_(std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec_ cppType);
|
|
997
|
-
|
|
998
|
-
// pragma MARK: std::weak_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>
|
|
999
|
-
using std__weak_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec_ = std::weak_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>;
|
|
1000
|
-
inline std__weak_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec_ weakify_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec_(const std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>& strong) { return strong; }
|
|
1001
|
-
|
|
1002
|
-
// pragma MARK: std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>>
|
|
1003
|
-
/**
|
|
1004
|
-
* Specialized version of `std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>>`.
|
|
1005
|
-
*/
|
|
1006
|
-
using std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec___ = std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>>;
|
|
1007
|
-
inline std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>> create_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec___() {
|
|
1008
|
-
return Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>::create();
|
|
1009
|
-
}
|
|
1010
|
-
inline PromiseHolder<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>> wrap_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec___(std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>> promise) {
|
|
1011
|
-
return PromiseHolder<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>(std::move(promise));
|
|
350
|
+
Func_void create_Func_void(void* _Nonnull swiftClosureWrapper);
|
|
351
|
+
inline Func_void_Wrapper wrap_Func_void(Func_void value) {
|
|
352
|
+
return Func_void_Wrapper(std::move(value));
|
|
1012
353
|
}
|
|
1013
354
|
|
|
1014
|
-
// pragma MARK: std::function<void(const std::
|
|
355
|
+
// pragma MARK: std::function<void(const std::exception_ptr& /* error */)>
|
|
1015
356
|
/**
|
|
1016
|
-
* Specialized version of `std::function<void(const std::
|
|
357
|
+
* Specialized version of `std::function<void(const std::exception_ptr&)>`.
|
|
1017
358
|
*/
|
|
1018
|
-
using
|
|
359
|
+
using Func_void_std__exception_ptr = std::function<void(const std::exception_ptr& /* error */)>;
|
|
1019
360
|
/**
|
|
1020
|
-
* Wrapper class for a `std::function<void(const std::
|
|
361
|
+
* Wrapper class for a `std::function<void(const std::exception_ptr& / * error * /)>`, this can be used from Swift.
|
|
1021
362
|
*/
|
|
1022
|
-
class
|
|
363
|
+
class Func_void_std__exception_ptr_Wrapper final {
|
|
1023
364
|
public:
|
|
1024
|
-
explicit
|
|
1025
|
-
inline void call(std::
|
|
1026
|
-
_function->operator()(
|
|
365
|
+
explicit Func_void_std__exception_ptr_Wrapper(std::function<void(const std::exception_ptr& /* error */)>&& func): _function(std::make_unique<std::function<void(const std::exception_ptr& /* error */)>>(std::move(func))) {}
|
|
366
|
+
inline void call(std::exception_ptr error) const {
|
|
367
|
+
_function->operator()(error);
|
|
1027
368
|
}
|
|
1028
369
|
private:
|
|
1029
|
-
std::unique_ptr<std::function<void(const std::
|
|
370
|
+
std::unique_ptr<std::function<void(const std::exception_ptr& /* error */)>> _function;
|
|
1030
371
|
} SWIFT_NONCOPYABLE;
|
|
1031
|
-
|
|
1032
|
-
inline
|
|
1033
|
-
return
|
|
1034
|
-
}
|
|
1035
|
-
|
|
1036
|
-
// pragma MARK: Result<std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>>>
|
|
1037
|
-
using Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec____ = Result<std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>>>;
|
|
1038
|
-
inline Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec____ create_Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec____(const std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>>& value) {
|
|
1039
|
-
return Result<std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>>>::withValue(value);
|
|
1040
|
-
}
|
|
1041
|
-
inline Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec____ create_Result_std__shared_ptr_Promise_std__shared_ptr_margelo__nitro__co__zyke__ble__HybridDescriptorSpec____(const std::exception_ptr& error) {
|
|
1042
|
-
return Result<std::shared_ptr<Promise<std::shared_ptr<margelo::nitro::co::zyke::ble::HybridDescriptorSpec>>>>::withError(error);
|
|
372
|
+
Func_void_std__exception_ptr create_Func_void_std__exception_ptr(void* _Nonnull swiftClosureWrapper);
|
|
373
|
+
inline Func_void_std__exception_ptr_Wrapper wrap_Func_void_std__exception_ptr(Func_void_std__exception_ptr value) {
|
|
374
|
+
return Func_void_std__exception_ptr_Wrapper(std::move(value));
|
|
1043
375
|
}
|
|
1044
376
|
|
|
1045
|
-
// pragma MARK: std::shared_ptr<
|
|
377
|
+
// pragma MARK: std::shared_ptr<HybridNativeBleNitroSpec>
|
|
1046
378
|
/**
|
|
1047
|
-
* Specialized version of `std::shared_ptr<
|
|
379
|
+
* Specialized version of `std::shared_ptr<HybridNativeBleNitroSpec>`.
|
|
1048
380
|
*/
|
|
1049
|
-
using
|
|
1050
|
-
std::shared_ptr<
|
|
1051
|
-
void* _Nonnull
|
|
381
|
+
using std__shared_ptr_HybridNativeBleNitroSpec_ = std::shared_ptr<HybridNativeBleNitroSpec>;
|
|
382
|
+
std::shared_ptr<HybridNativeBleNitroSpec> create_std__shared_ptr_HybridNativeBleNitroSpec_(void* _Nonnull swiftUnsafePointer);
|
|
383
|
+
void* _Nonnull get_std__shared_ptr_HybridNativeBleNitroSpec_(std__shared_ptr_HybridNativeBleNitroSpec_ cppType);
|
|
1052
384
|
|
|
1053
|
-
// pragma MARK: std::weak_ptr<
|
|
1054
|
-
using
|
|
1055
|
-
inline
|
|
385
|
+
// pragma MARK: std::weak_ptr<HybridNativeBleNitroSpec>
|
|
386
|
+
using std__weak_ptr_HybridNativeBleNitroSpec_ = std::weak_ptr<HybridNativeBleNitroSpec>;
|
|
387
|
+
inline std__weak_ptr_HybridNativeBleNitroSpec_ weakify_std__shared_ptr_HybridNativeBleNitroSpec_(const std::shared_ptr<HybridNativeBleNitroSpec>& strong) { return strong; }
|
|
1056
388
|
|
|
1057
|
-
// pragma MARK:
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
389
|
+
// pragma MARK: Result<void>
|
|
390
|
+
using Result_void_ = Result<void>;
|
|
391
|
+
inline Result_void_ create_Result_void_() {
|
|
392
|
+
return Result<void>::withValue();
|
|
393
|
+
}
|
|
394
|
+
inline Result_void_ create_Result_void_(const std::exception_ptr& error) {
|
|
395
|
+
return Result<void>::withError(error);
|
|
396
|
+
}
|
|
1064
397
|
|
|
1065
|
-
// pragma MARK: std::
|
|
1066
|
-
using
|
|
1067
|
-
inline
|
|
398
|
+
// pragma MARK: Result<std::shared_ptr<Promise<void>>>
|
|
399
|
+
using Result_std__shared_ptr_Promise_void___ = Result<std::shared_ptr<Promise<void>>>;
|
|
400
|
+
inline Result_std__shared_ptr_Promise_void___ create_Result_std__shared_ptr_Promise_void___(const std::shared_ptr<Promise<void>>& value) {
|
|
401
|
+
return Result<std::shared_ptr<Promise<void>>>::withValue(value);
|
|
402
|
+
}
|
|
403
|
+
inline Result_std__shared_ptr_Promise_void___ create_Result_std__shared_ptr_Promise_void___(const std::exception_ptr& error) {
|
|
404
|
+
return Result<std::shared_ptr<Promise<void>>>::withError(error);
|
|
405
|
+
}
|
|
1068
406
|
|
|
1069
407
|
} // namespace margelo::nitro::co::zyke::ble::bridge::swift
|