peachsim 0.1.1684 → 0.1.1692

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (254) hide show
  1. package/cli/commands/coverage-swift.ts +72 -5
  2. package/cli/commands/inspect/actions.ts +1 -0
  3. package/cli/commands/screenshot.ts +12 -0
  4. package/dist-lib/agent-daemon-client.cjs +1 -1
  5. package/dist-lib/agent-events.cjs +1 -1
  6. package/dist-lib/attached-projects.cjs +1 -1
  7. package/dist-lib/auth/shared-session.cjs +1 -1
  8. package/dist-lib/backend-origin.cjs +1 -1
  9. package/dist-lib/beta.cjs +1 -1
  10. package/dist-lib/beta.mjs +1 -1
  11. package/dist-lib/bridge-constants.cjs +1 -1
  12. package/dist-lib/bridge-contract-input.cjs +1 -1
  13. package/dist-lib/bridge-contract-input.mjs +1 -1
  14. package/dist-lib/bridge-contract.cjs +1 -1
  15. package/dist-lib/bridge-contract.mjs +1 -1
  16. package/dist-lib/bundle-channel.cjs +2252 -1462
  17. package/dist-lib/capture-contract.cjs +1 -1
  18. package/dist-lib/capture-contract.mjs +1 -1
  19. package/dist-lib/cloud-contract.cjs +1 -1
  20. package/dist-lib/cloud-contract.mjs +1 -1
  21. package/dist-lib/cloud-test-args.cjs +1 -1
  22. package/dist-lib/cloud-test-args.mjs +1 -1
  23. package/dist-lib/cloud.cjs +1 -1
  24. package/dist-lib/cloud.mjs +1 -1
  25. package/dist-lib/config.cjs +1 -1
  26. package/dist-lib/config.mjs +1 -1
  27. package/dist-lib/detox/index.cjs +1 -1
  28. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  29. package/dist-lib/expo-swift-bundle.cjs +1762 -995
  30. package/dist-lib/expo-swift-metadata.cjs +1 -1
  31. package/dist-lib/expo-swift-metadata.mjs +1 -1
  32. package/dist-lib/home-paths.cjs +1 -1
  33. package/dist-lib/host/bridge-host.cjs +2184 -1417
  34. package/dist-lib/host/fetch-proxy-handler.cjs +3 -3
  35. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  36. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  37. package/dist-lib/host/replacement-module-handler.cjs +1 -1
  38. package/dist-lib/host/websocket-proxy.cjs +1 -1
  39. package/dist-lib/index.cjs +175 -69
  40. package/dist-lib/jump-to-source-babel.cjs +1 -1
  41. package/dist-lib/jump-to-source-native.cjs +1 -1
  42. package/dist-lib/kotlin-host.cjs +1 -1
  43. package/dist-lib/menu.cjs +1 -1
  44. package/dist-lib/menu.mjs +1 -1
  45. package/dist-lib/metro-fingerprint-registry.cjs +1 -1
  46. package/dist-lib/metro-fingerprint-registry.mjs +1 -1
  47. package/dist-lib/metro-production-bundle.cjs +1 -1
  48. package/dist-lib/metro-production-bundle.mjs +1 -1
  49. package/dist-lib/metro.cjs +174 -68
  50. package/dist-lib/native-app-identity-project.cjs +163 -51
  51. package/dist-lib/native-app-identity-project.mjs +206 -82
  52. package/dist-lib/native-app-identity.cjs +1 -1
  53. package/dist-lib/native-app-identity.mjs +1 -1
  54. package/dist-lib/native-firebase-metadata.cjs +1 -1
  55. package/dist-lib/native-firebase-metadata.mjs +1 -1
  56. package/dist-lib/plist.cjs +1 -1
  57. package/dist-lib/plist.mjs +1 -1
  58. package/dist-lib/profiles.cjs +1 -1
  59. package/dist-lib/public-brand.cjs +1 -1
  60. package/dist-lib/public-origins-lib-esm.json +26 -23
  61. package/dist-lib/public-origins-lib.json +74 -61
  62. package/dist-lib/react-native-host-modules.cjs +1 -1
  63. package/dist-lib/react-native-host-modules.mjs +1 -1
  64. package/dist-lib/reap-browser.cjs +1 -1
  65. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  66. package/dist-lib/sdk.cjs +2 -2
  67. package/dist-lib/sdk.mjs +2 -2
  68. package/dist-lib/skills.cjs +2633 -1840
  69. package/dist-lib/swift-compile.cjs +2478 -100
  70. package/dist-lib/swift-compile.mjs +2475 -100
  71. package/dist-lib/swift-package.cjs +108 -50
  72. package/dist-lib/swift-package.mjs +104 -50
  73. package/dist-lib/swift-submit.cjs +1 -1
  74. package/dist-lib/swift-submit.mjs +1 -1
  75. package/dist-lib/swift-toolchain.cjs +1 -1
  76. package/dist-lib/swift.cjs +1 -1
  77. package/dist-lib/vite-swift.cjs +3979 -985
  78. package/dist-lib/vite.cjs +12 -18
  79. package/dist-lib/worklet-executable.cjs +7 -4
  80. package/dist-lib/worklet-executable.mjs +7 -4
  81. package/dist-types/packages/peach-engine/src/engine/clipboardContract.d.ts +15 -1
  82. package/dist-types/packages/peach-globals/src/clipboardBridgeContract.d.ts +6 -0
  83. package/dist-types/packages/peach-globals/src/index.d.ts +1 -1
  84. package/dist-types/packages/peach-globals/src/nodeContract.d.ts +3 -2
  85. package/dist-types/packages/peach-kit/src/capabilities.d.ts +1 -0
  86. package/package.json +1 -1
  87. package/sdk/ios/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h +9 -0
  88. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLAvailability.h +22 -0
  89. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBackgroundActivitySession.h +145 -0
  90. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBeaconIdentityCondition.h +113 -0
  91. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBeaconIdentityConstraint.h +34 -0
  92. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBeaconRegion.h +225 -0
  93. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBody.h +26 -0
  94. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLCircularGeographicCondition.h +59 -0
  95. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLCircularRegion.h +64 -0
  96. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLCondition.h +48 -0
  97. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLError.h +52 -0
  98. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLErrorDomain.h +24 -0
  99. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLGeocoder.h +55 -0
  100. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLHeading.h +117 -0
  101. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocation.h +9 -0
  102. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationManager+CLVisitExtensions.h +45 -0
  103. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationManager.h +877 -0
  104. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationManagerDelegate.h +225 -0
  105. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationPushServiceError.h +33 -0
  106. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationPushServiceExtension.h +28 -0
  107. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationUpdater.h +250 -0
  108. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLMonitor.h +140 -0
  109. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLMonitorConfiguration.h +77 -0
  110. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLMonitoringEvent.h +184 -0
  111. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLMonitoringRecord.h +57 -0
  112. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLPlacemark.h +98 -0
  113. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLRegion.h +123 -0
  114. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLServiceSession.h +211 -0
  115. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLVisit.h +66 -0
  116. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CoreLocation.h +46 -0
  117. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Modules/module.modulemap +7 -0
  118. package/sdk/ios/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h +96 -2
  119. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Headers/IOSurfaceBase.h +52 -0
  120. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Headers/IOSurfaceObjC.h +240 -0
  121. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Headers/IOSurfaceRef.h +474 -0
  122. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Headers/IOSurfaceTypes.h +66 -0
  123. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Modules/module.modulemap +10 -0
  124. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4AccelerationStructure.h +9 -0
  125. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4Archive.h +16 -0
  126. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4ArgumentTable.h +17 -0
  127. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4BinaryFunction.h +13 -0
  128. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4BinaryFunctionDescriptor.h +14 -0
  129. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4BufferRange.h +79 -0
  130. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommandAllocator.h +15 -0
  131. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommandBuffer.h +17 -0
  132. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommandEncoder.h +16 -0
  133. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommandQueue.h +19 -0
  134. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommitFeedback.h +15 -0
  135. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4Compiler.h +13 -0
  136. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CompilerTask.h +13 -0
  137. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4ComputeCommandEncoder.h +19 -0
  138. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4ComputePipeline.h +13 -0
  139. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4Counters.h +19 -0
  140. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4FunctionDescriptor.h +13 -0
  141. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4LibraryDescriptor.h +13 -0
  142. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4LibraryFunctionDescriptor.h +13 -0
  143. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4LinkingDescriptor.h +13 -0
  144. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4MachineLearningCommandEncoder.h +17 -0
  145. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4MachineLearningPipeline.h +13 -0
  146. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4MeshRenderPipeline.h +13 -0
  147. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4PipelineDataSetSerializer.h +13 -0
  148. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4PipelineState.h +13 -0
  149. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4RenderCommandEncoder.h +17 -0
  150. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4RenderPass.h +17 -0
  151. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4RenderPipeline.h +13 -0
  152. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4SpecializedFunctionDescriptor.h +13 -0
  153. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4StitchedFunctionDescriptor.h +13 -0
  154. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4TileRenderPipeline.h +13 -0
  155. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLAccelerationStructure.h +1212 -0
  156. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLAccelerationStructureCommandEncoder.h +322 -0
  157. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLAccelerationStructureTypes.h +224 -0
  158. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLAllocation.h +22 -0
  159. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLArgument.h +279 -0
  160. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLArgumentEncoder.h +199 -0
  161. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLBinaryArchive.h +142 -0
  162. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLBlitCommandEncoder.h +266 -0
  163. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLBlitPass.h +82 -0
  164. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLBuffer.h +94 -0
  165. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCaptureManager.h +113 -0
  166. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCaptureScope.h +43 -0
  167. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCommandBuffer.h +449 -0
  168. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCommandEncoder.h +148 -0
  169. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCommandQueue.h +102 -0
  170. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLComputeCommandEncoder.h +350 -0
  171. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLComputePass.h +90 -0
  172. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLComputePipeline.h +274 -0
  173. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCounters.h +225 -0
  174. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDataType.h +232 -0
  175. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDefines.h +39 -0
  176. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDepthStencil.h +93 -0
  177. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDevice.h +1122 -0
  178. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDeviceCertification.h +29 -0
  179. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDrawable.h +36 -0
  180. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDynamicLibrary.h +81 -0
  181. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLEvent.h +79 -0
  182. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFence.h +22 -0
  183. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionConstantValues.h +30 -0
  184. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionDescriptor.h +95 -0
  185. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionHandle.h +29 -0
  186. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionLog.h +37 -0
  187. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionStitching.h +131 -0
  188. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLGPUAddress.h +19 -0
  189. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLHeap.h +284 -0
  190. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIOCommandBuffer.h +10 -0
  191. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIOCommandQueue.h +11 -0
  192. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIOCompressor.h +10 -0
  193. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIndirectCommandBuffer.h +157 -0
  194. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIndirectCommandEncoder.h +110 -0
  195. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIntersectionFunctionTable.h +186 -0
  196. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLLibrary.h +549 -0
  197. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLLinkedFunctions.h +57 -0
  198. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLLogState.h +65 -0
  199. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLParallelRenderCommandEncoder.h +77 -0
  200. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLPipeline.h +57 -0
  201. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLPixelFormat.h +342 -0
  202. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLRasterizationRate.h +323 -0
  203. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLRenderCommandEncoder.h +1068 -0
  204. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLRenderPass.h +411 -0
  205. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLRenderPipeline.h +788 -0
  206. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResidencySet.h +141 -0
  207. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResource.h +307 -0
  208. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResourceStateCommandEncoder.h +125 -0
  209. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResourceStatePass.h +85 -0
  210. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResourceViewPool.h +22 -0
  211. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLSampler.h +252 -0
  212. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLStageInputOutputDescriptor.h +158 -0
  213. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLTensor.h +17 -0
  214. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLTexture.h +460 -0
  215. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLTextureViewPool.h +18 -0
  216. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLTypes.h +125 -0
  217. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLVertexDescriptor.h +153 -0
  218. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLVisibleFunctionTable.h +45 -0
  219. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/Metal.h +94 -0
  220. package/sdk/ios/System/Library/Frameworks/Metal.framework/Modules/module.modulemap +6 -0
  221. package/sdk/ios/System/Library/Frameworks/UniformTypeIdentifiers.framework/Headers/UTDefines.h +35 -0
  222. package/sdk/ios/System/Library/Frameworks/UniformTypeIdentifiers.framework/Headers/UTTagClass.h +33 -0
  223. package/sdk/ios/System/Library/Frameworks/UniformTypeIdentifiers.framework/Headers/UTType.h +504 -0
  224. package/sdk/ios/System/Library/Frameworks/_LocationEssentials.framework/Headers/CLEssentialsAvailability.h +14 -0
  225. package/sdk/ios/System/Library/Frameworks/_LocationEssentials.framework/Headers/CLLocationEssentials.h +444 -0
  226. package/sdk/ios/System/Library/Frameworks/_LocationEssentials.framework/Headers/LocationEssentials.h +14 -0
  227. package/sdk/ios/System/Library/Frameworks/_LocationEssentials.framework/Modules/module.modulemap +14 -0
  228. package/sdk/ios/usr/include/complex.h +167 -0
  229. package/sdk/ios/usr/include/dispatch/dispatch.h +5 -0
  230. package/sdk/ios/usr/include/mach/mach_types.h +1 -0
  231. package/sdk/ios/usr/include/math.h +835 -2
  232. package/sdk/ios/usr/include/sys/cdefs.h +0 -1
  233. package/src/generated/swift-c-predefines.json +1988 -0
  234. package/src/nitro-bundle.ts +1 -0
  235. package/src/nitro-compile.ts +4 -0
  236. package/src/nitroContract.ts +18 -2
  237. package/src/swift-compile.ts +446 -49
  238. package/src/swift-coverage/package.ts +3 -1
  239. package/src/swift-coverage/xcode-assets.ts +62 -2
  240. package/src/swift-coverage/xcode-packages.ts +11 -6
  241. package/src/swift-host.ts +333 -57
  242. package/src/swift-objc-compile.ts +20 -5
  243. package/src/swift-objc-standin.ts +21 -11
  244. package/src/swift-package-manifest.ts +151 -28
  245. package/src/swift-package.ts +134 -58
  246. package/src/swift-packages.ts +141 -44
  247. package/src/swift-source-file.ts +10 -15
  248. package/src/swift-standins.ts +87 -13
  249. package/src/swift-submit.ts +5 -0
  250. package/src/swiftContract.ts +160 -75
  251. package/src/target-matcher.ts +15 -2
  252. package/src/worklet-executable.ts +7 -3
  253. package/src/xcode-json-project.ts +14 -2
  254. package/src/xcode-project.ts +154 -59
@@ -0,0 +1,877 @@
1
+ /*
2
+ * CLLocationManager.h
3
+ * CoreLocation
4
+ *
5
+ * Copyright (c) 2008-2010 Apple Inc. All rights reserved.
6
+ *
7
+ */
8
+
9
+ #import <Foundation/Foundation.h>
10
+ #import <CoreLocation/CLAvailability.h>
11
+ #import <CoreLocation/CLLocation.h>
12
+ #import <CoreLocation/CLRegion.h>
13
+ #import <CoreLocation/CLLocationUpdater.h>
14
+ #import <CoreLocation/CLMonitor.h>
15
+ #import <CoreLocation/CLMonitoringEvent.h>
16
+
17
+
18
+ NS_ASSUME_NONNULL_BEGIN
19
+
20
+ /*
21
+ * CLDeviceOrientation
22
+ *
23
+ * Discussion:
24
+ * Specifies a physical device orientation, equivalent to UIDeviceOrientation.
25
+ *
26
+ */
27
+ typedef NS_ENUM(int, CLDeviceOrientation) {
28
+ CLDeviceOrientationUnknown = 0,
29
+ CLDeviceOrientationPortrait,
30
+ CLDeviceOrientationPortraitUpsideDown,
31
+ CLDeviceOrientationLandscapeLeft,
32
+ CLDeviceOrientationLandscapeRight,
33
+ CLDeviceOrientationFaceUp,
34
+ CLDeviceOrientationFaceDown
35
+ };
36
+
37
+ /*
38
+ * CLAuthorizationStatus
39
+ *
40
+ * Discussion:
41
+ * Represents the current authorization state of the application.
42
+ *
43
+ */
44
+ typedef NS_ENUM(int, CLAuthorizationStatus) {
45
+ // User has not yet made a choice with regards to this application
46
+ kCLAuthorizationStatusNotDetermined = 0,
47
+
48
+ // This application is not authorized to use location services. Due
49
+ // to active restrictions on location services, the user cannot change
50
+ // this status, and may not have personally denied authorization
51
+ kCLAuthorizationStatusRestricted,
52
+
53
+ // User has explicitly denied authorization for this application, or
54
+ // location services are disabled in Settings.
55
+ kCLAuthorizationStatusDenied,
56
+
57
+ // User has granted authorization to use their location at any
58
+ // time. Your app may be launched into the background by
59
+ // monitoring APIs such as visit monitoring, region monitoring,
60
+ // and significant location change monitoring.
61
+ //
62
+ // This value should be used on iOS, tvOS and watchOS. It is available on
63
+ // MacOS, but kCLAuthorizationStatusAuthorized is synonymous and preferred.
64
+ kCLAuthorizationStatusAuthorizedAlways API_AVAILABLE(macos(10.12), ios(8.0)) API_UNAVAILABLE(visionos),
65
+
66
+ // User has granted authorization to use their location only while
67
+ // they are using your app. Note: You can reflect the user's
68
+ // continued engagement with your app using
69
+ // -allowsBackgroundLocationUpdates.
70
+ //
71
+ // This value is not available on MacOS. It should be used on iOS, tvOS and
72
+ // watchOS.
73
+ kCLAuthorizationStatusAuthorizedWhenInUse API_AVAILABLE(ios(8.0)) API_UNAVAILABLE(macos),
74
+
75
+ // User has authorized this application to use location services.
76
+ //
77
+ // This value is deprecated or prohibited on iOS, tvOS and watchOS.
78
+ // It should be used on MacOS.
79
+ kCLAuthorizationStatusAuthorized API_DEPRECATED("Use kCLAuthorizationStatusAuthorizedAlways", ios(2.0, 8.0)) API_AVAILABLE(macos(10.6)) API_UNAVAILABLE(watchos, tvos, visionos) = kCLAuthorizationStatusAuthorizedAlways
80
+ };
81
+
82
+ typedef NS_ENUM(NSInteger, CLAccuracyAuthorization) {
83
+ // This application has the user's permission to receive accurate location information.
84
+ CLAccuracyAuthorizationFullAccuracy,
85
+
86
+ // The user has chosen to grant this application access to location information with reduced accuracy.
87
+ // Region monitoring and beacon ranging are not available to the application. Other CoreLocation APIs
88
+ // are available with reduced accuracy.
89
+
90
+ // Location estimates will have a horizontalAccuracy on the order of about 5km. To achieve the
91
+ // reduction in accuracy, CoreLocation will snap location estimates to a nearby point which represents
92
+ // the region the device is in. Furthermore, CoreLocation will reduce the rate at which location
93
+ // estimates are produced. Applications should be prepared to receive locations that are up to 20
94
+ // minutes old.
95
+ CLAccuracyAuthorizationReducedAccuracy,
96
+ };
97
+
98
+ /*
99
+ * CLActivityType
100
+ *
101
+ * Discussion:
102
+ * Expected user activity for the lifetime of the corresponding CLLocationManager instance.
103
+ * Used to optimize the positioning experience delivered to this CLLocationManager instance
104
+ * for the expected activity.
105
+ */
106
+ typedef NS_ENUM(NSInteger, CLActivityType) {
107
+ CLActivityTypeOther = 1, // positioning in activities that are not covered by one of
108
+ // the other activity types. Includes activities without a
109
+ // specific user intention; for example, positioning while
110
+ // the user sits on a bench interacting with the device
111
+
112
+ CLActivityTypeAutomotiveNavigation, // positioning in an automobile following a road network
113
+
114
+ CLActivityTypeFitness, // positioning in dedicated fitness sessions, e.g. walking
115
+ // workouts, running workouts, cycling workouts, etc.
116
+
117
+ CLActivityTypeOtherNavigation, // positioning for transportation that does not or may not
118
+ // adhere to roads such as cycling, scooters, trains, boats
119
+ // and off-road vehicles; also for positioning indoors and
120
+ // outdoors that isn’t tied to a dedicated fitness session,
121
+ // e.g. walking
122
+
123
+ CLActivityTypeAirborne API_AVAILABLE(ios(12.0), macos(10.14), tvos(12.0), watchos(5.0)),
124
+ // positioning for activities in the air, e.g. flying in an
125
+ // airplane or helicopter, paragliding, flying on a drone,
126
+ // skydiving, etc. Also includes runway taxiing
127
+
128
+ CLActivityTypeMaritime API_AVAILABLE(ios(27.0), macos(27.0), tvos(27.0), watchos(27.0), visionos(27.0)),
129
+ // positioning for vehicular activities on the water, e.g. boating,
130
+ // sailing, etc.
131
+ };
132
+
133
+ @class CLLocation;
134
+ @class CLHeading;
135
+ @class CLBeaconRegion;
136
+ @class CLBeaconIdentityConstraint;
137
+ @class CLMonitorConfiguration;
138
+ @class CLBackgroundActivitySession;
139
+ @protocol CLLocationManagerDelegate;
140
+ @protocol CLBodyIdentifiable;
141
+
142
+ /*
143
+ * CLLocationManager
144
+ *
145
+ * Discussion:
146
+ * The CLLocationManager object is your entry point to the location service.
147
+ */
148
+ CL_EXTERN
149
+ API_AVAILABLE(macos(10.6), ios(2.0))
150
+ @interface CLLocationManager : NSObject
151
+ {
152
+ @private
153
+ id _internal;
154
+ }
155
+
156
+ /*
157
+ * locationServicesEnabled
158
+ *
159
+ * Discussion:
160
+ * Determines whether the user has location services enabled.
161
+ * If NO, and you proceed to call other CoreLocation API, user will be prompted with the warning
162
+ * dialog. You may want to check this property and use location services only when explicitly requested by the user.
163
+ */
164
+ + (BOOL)locationServicesEnabled API_AVAILABLE(ios(4.0), macos(10.7));
165
+
166
+ /*
167
+ * headingAvailable
168
+ *
169
+ * Discussion:
170
+ * Returns YES if the device supports the heading service, otherwise NO.
171
+ */
172
+ + (BOOL)headingAvailable API_AVAILABLE(ios(4.0), macos(10.7), watchos(2.0)) API_UNAVAILABLE(tvos);
173
+
174
+ /*
175
+ * significantLocationChangeMonitoringAvailable
176
+ *
177
+ * Discussion:
178
+ * Returns YES if the device supports significant location change monitoring, otherwise NO.
179
+ */
180
+ + (BOOL)significantLocationChangeMonitoringAvailable API_AVAILABLE(ios(4.0), macos(10.7)) API_UNAVAILABLE(watchos, tvos);
181
+
182
+ /*
183
+ * isMonitoringAvailableForClass:
184
+ *
185
+ * Discussion:
186
+ * Determines whether the device supports monitoring for the specified type of region.
187
+ * If NO, all attempts to monitor the specified type of region will fail.
188
+ */
189
+ + (BOOL)isMonitoringAvailableForClass:(Class)regionClass API_AVAILABLE(ios(7.0), macos(10.10)) API_UNAVAILABLE(watchos, tvos);
190
+
191
+ /*
192
+ * regionMonitoringAvailable
193
+ *
194
+ * Discussion:
195
+ * Deprecated. Use +isMonitoringAvailableForClass: instead.
196
+ */
197
+ + (BOOL)regionMonitoringAvailable API_DEPRECATED_WITH_REPLACEMENT("+isMonitoringAvailableForClass:", ios(4.0, 7.0), macos(10.8, 10.10)) API_UNAVAILABLE(watchos, tvos);
198
+
199
+ /*
200
+ * regionMonitoringEnabled
201
+ *
202
+ * Discussion:
203
+ * Deprecated. Use +isMonitoringAvailableForClass: and -authorizationStatus instead.
204
+ */
205
+ + (BOOL)regionMonitoringEnabled API_DEPRECATED("Use +isMonitoringAvailableForClass: and -authorizationStatus instead", ios(4.0, 6.0), macos(10.8, 10.10)) API_UNAVAILABLE(watchos, tvos);
206
+
207
+ /*
208
+ * isRangingAvailable
209
+ *
210
+ * Discussion:
211
+ * Determines whether the device supports ranging.
212
+ * If NO, all attempts to range beacons will fail.
213
+ */
214
+ + (BOOL)isRangingAvailable API_AVAILABLE(ios(7.0), macos(10.15)) API_UNAVAILABLE(watchos, tvos);
215
+
216
+ /*
217
+ * authorizationStatus
218
+ *
219
+ * Discussion:
220
+ * Returns the current authorization status of the calling application.
221
+ */
222
+ @property (nonatomic, readonly) CLAuthorizationStatus authorizationStatus API_AVAILABLE(ios(14.0), macos(11.0), watchos(7.0), tvos(14.0));
223
+ /*
224
+ * authorizationStatus
225
+ *
226
+ * Discussion:
227
+ * Deprecated. Use the instance property authorizationStatus instead.
228
+ */
229
+ + (CLAuthorizationStatus)authorizationStatus API_DEPRECATED_WITH_REPLACEMENT("-authorizationStatus", ios(4.2, 14.0), macos(10.7, 11.0), watchos(1.0, 7.0), tvos(9.0, 14.0));
230
+
231
+ /*
232
+ * accuracyAuthorization
233
+ *
234
+ * Discussion:
235
+ * Returns information about the calling application's access to accurate location. See the
236
+ * documentation for CLAccuracyAuthorization for information about how to interpret the return value.
237
+ *
238
+ * Note that this property should generally be interpreted in the context of the authorizationStatus
239
+ * property. For example, if authorizationStatus == kCLAuthorizationStatusNotDetermined then accurate
240
+ * location information cannot be received even when accuracyAuthorization is
241
+ * CLAccuracyAuthorizationFullAccuracy.
242
+ */
243
+ @property (nonatomic, readonly) CLAccuracyAuthorization accuracyAuthorization API_AVAILABLE(ios(14.0), macos(11.0), watchos(7.0), tvos(14.0));
244
+
245
+ /*
246
+ * authorizedForWidgetUpdates
247
+ *
248
+ * Discussion:
249
+ * Returns true if widgets of the calling application may be eligible to receive location updates.
250
+ *
251
+ * If the calling application has authorizationStatus == kCLAuthorizationStatusAuthorizedWhenInUse,
252
+ * and authorizedForWidgetUpdates == YES, then widgets will be able to get location updates if called upon
253
+ * to refresh within a few minutes of having been seen.
254
+ *
255
+ * If the calling application has authorizationStatus == kCLAuthorizationStatusAuthorizedAlways,
256
+ * then authorizedForWidgetUpdates will always be YES.
257
+ */
258
+ @property (nonatomic, readonly, getter=isAuthorizedForWidgetUpdates) BOOL authorizedForWidgetUpdates API_AVAILABLE(ios(14.0), macos(11.0)) API_UNAVAILABLE(watchos, tvos);
259
+
260
+ @property(weak, nonatomic, nullable) id<CLLocationManagerDelegate> delegate;
261
+
262
+ /*
263
+ * locationServicesEnabled
264
+ *
265
+ * Discussion:
266
+ * Deprecated. Use +locationServicesEnabled instead.
267
+ */
268
+ @property(readonly, nonatomic) BOOL locationServicesEnabled API_DEPRECATED_WITH_REPLACEMENT("+locationServicesEnabled", ios(2.0, 4.0), macos(10.15, 10.15)) API_UNAVAILABLE(watchos, tvos, visionos);
269
+
270
+ /*
271
+ * purpose
272
+ *
273
+ * Discussion:
274
+ * Allows the application to specify what location will be used for in their app. This
275
+ * will be displayed along with the standard Location permissions dialogs. This property will need to be
276
+ * set prior to calling startUpdatingLocation.
277
+ *
278
+ * Deprecated. Set the purpose string in Info.plist using key NSLocationUsageDescription.
279
+ */
280
+ @property(copy, nonatomic, nullable) NSString *purpose API_DEPRECATED("Set the purpose string in Info.plist using key NSLocationUsageDescription", ios(3.2, 6.0), macos(10.7, 11.0)) API_UNAVAILABLE(watchos, tvos, visionos);
281
+
282
+ /*
283
+ * activityType
284
+ *
285
+ * Discussion:
286
+ * Specifies the type of user activity. Currently affects behavior such as
287
+ * the determination of when location updates may be automatically paused.
288
+ * By default, CLActivityTypeOther is used.
289
+ */
290
+ @property(assign, nonatomic) CLActivityType activityType API_AVAILABLE(ios(6.0), macos(10.15), watchos(4.0)) API_UNAVAILABLE(tvos);
291
+
292
+ /*
293
+ * distanceFilter
294
+ *
295
+ * Discussion:
296
+ * Specifies the minimum update distance in meters. Client will not be notified of movements of less
297
+ * than the stated value, unless the accuracy has improved. Pass in kCLDistanceFilterNone to be
298
+ * notified of all movements. By default, kCLDistanceFilterNone is used.
299
+ */
300
+ @property(assign, nonatomic) CLLocationDistance distanceFilter;
301
+
302
+ /*
303
+ * desiredAccuracy
304
+ *
305
+ * Discussion:
306
+ * The desired location accuracy. The location service will try its best to achieve
307
+ * your desired accuracy. However, it is not guaranteed. To optimize
308
+ * power performance, be sure to specify an appropriate accuracy for your usage scenario (eg,
309
+ * use a large accuracy value when only a coarse location is needed). Use kCLLocationAccuracyBest to
310
+ * achieve the best possible accuracy. Use kCLLocationAccuracyBestForNavigation for navigation.
311
+ * The default value varies by platform.
312
+ */
313
+ @property(assign, nonatomic) CLLocationAccuracy desiredAccuracy;
314
+
315
+ /*
316
+ * pausesLocationUpdatesAutomatically
317
+ *
318
+ * Discussion:
319
+ * Specifies that location updates may automatically be paused when possible.
320
+ * By default, this is YES for applications linked against iOS 6.0 or later.
321
+ */
322
+ @property(assign, nonatomic) BOOL pausesLocationUpdatesAutomatically API_AVAILABLE(ios(6.0), macos(10.15)) API_UNAVAILABLE(watchos, tvos);
323
+
324
+ /*
325
+ * allowsBackgroundLocationUpdates
326
+ *
327
+ * Discussion:
328
+ * By default, this is NO for applications linked against iOS 9.0 or later,
329
+ * regardless of minimum deployment target.
330
+ *
331
+ * With UIBackgroundModes set to include "location" in Info.plist, you must
332
+ * also set this property to YES at runtime whenever calling
333
+ * -startUpdatingLocation with the intent to continue in the background.
334
+ *
335
+ * Setting this property to YES when UIBackgroundModes does not include
336
+ * "location" is a fatal error.
337
+ *
338
+ * Resetting this property to NO is equivalent to omitting "location" from
339
+ * the UIBackgroundModes value. Access to location is still permitted
340
+ * whenever the application is running (ie not suspended), and has
341
+ * sufficient authorization (ie it has WhenInUse authorization and is in
342
+ * use, or it has Always authorization). However, the app will still be
343
+ * subject to the usual task suspension rules.
344
+ *
345
+ * See -requestWhenInUseAuthorization and -requestAlwaysAuthorization for
346
+ * more details on possible authorization values.
347
+ */
348
+ @property(assign, nonatomic) BOOL allowsBackgroundLocationUpdates API_AVAILABLE(ios(9.0), macos(10.15), watchos(4.0)) API_UNAVAILABLE(tvos, visionos);
349
+
350
+ /*
351
+ * showsBackgroundLocationIndicator
352
+ *
353
+ * Discussion:
354
+ * Specifies that an indicator be shown when the app makes use of continuous
355
+ * background location updates. Starting continuous background location
356
+ * updates requires the app to set UIBackgroundModes to include "location"
357
+ * and to set the property allowsBackgroundLocationUpdates to YES before
358
+ * calling -startUpdatingLocation with the intent to continue in the
359
+ * background.
360
+ *
361
+ * Note that this property only applies to apps with Always authorization.
362
+ * For apps with WhenInUse authorization, the indicator is always shown when
363
+ * using continuous background location updates in order to maintain user
364
+ * visibility and that the app is still in use.
365
+ *
366
+ * The default value of this property is NO.
367
+ */
368
+ @property(assign, nonatomic) BOOL showsBackgroundLocationIndicator API_AVAILABLE(ios(11.0)) API_UNAVAILABLE(watchos, tvos, macos);
369
+
370
+ /*
371
+ * location
372
+ *
373
+ * Discussion:
374
+ * The last location received. Will be nil until a location has been received.
375
+ */
376
+ @property(readonly, nonatomic, copy, nullable) CLLocation *location;
377
+
378
+ /*
379
+ * headingAvailable
380
+ *
381
+ * Discussion:
382
+ * Deprecated. Use +headingAvailable instead.
383
+ */
384
+ @property(readonly, nonatomic) BOOL headingAvailable API_DEPRECATED_WITH_REPLACEMENT("+headingAvailable", ios(3.0, 4.0), macos(10.15, 10.15), visionos(1.0, 1.0)) API_UNAVAILABLE(watchos, tvos);
385
+ /*
386
+ * headingFilter
387
+ *
388
+ * Discussion:
389
+ * Specifies the minimum amount of change in degrees needed for a heading service update. Client will not
390
+ * be notified of updates less than the stated filter value. Pass in kCLHeadingFilterNone to be
391
+ * notified of all updates. By default, 1 degree is used.
392
+ */
393
+ @property(assign, nonatomic) CLLocationDegrees headingFilter API_AVAILABLE(ios(3.0), macos(10.15), watchos(2.0)) API_UNAVAILABLE(tvos, visionos);
394
+ /*
395
+ * headingOrientation
396
+ *
397
+ * Discussion:
398
+ * Specifies a physical device orientation from which heading calculation should be referenced. By default,
399
+ * CLDeviceOrientationPortrait is used. CLDeviceOrientationUnknown, CLDeviceOrientationFaceUp, and
400
+ * CLDeviceOrientationFaceDown are ignored.
401
+ *
402
+ */
403
+ @property(assign, nonatomic) CLDeviceOrientation headingOrientation API_DEPRECATED_WITH_REPLACEMENT("headingBody", ios(4.0, 27.0), macos(10.15, 27.0), watchos(2.0, 27.0)) API_UNAVAILABLE(tvos, visionos);
404
+ /*
405
+ * headingBody
406
+ *
407
+ * Discussion:
408
+ * Specifies a body from which heading calculation should be referenced.
409
+ *
410
+ */
411
+ @property(retain, nonatomic, nullable) id<CLBodyIdentifiable> headingBody API_AVAILABLE(ios(27.0), macos(27.0), watchos(27.0)) API_UNAVAILABLE(tvos, visionos);
412
+ /*
413
+ * heading
414
+ *
415
+ * Discussion:
416
+ * Returns the latest heading update received, or nil if none is available.
417
+ */
418
+ @property(readonly, nonatomic, copy, nullable) CLHeading *heading API_AVAILABLE(ios(4.0), macos(10.15), watchos(2.0)) API_UNAVAILABLE(tvos, visionos);
419
+ /*
420
+ * maximumRegionMonitoringDistance
421
+ *
422
+ * Discussion:
423
+ * the maximum region size, in terms of a distance from a central point, that the framework can support.
424
+ * Attempts to register a region larger than this will generate a kCLErrorRegionMonitoringFailure.
425
+ * This value may vary based on the hardware features of the device, as well as on dynamically changing resource constraints.
426
+ */
427
+ @property (readonly, nonatomic) CLLocationDistance maximumRegionMonitoringDistance API_AVAILABLE(ios(4.0), macos(10.8)) API_UNAVAILABLE(watchos, tvos, visionos);
428
+
429
+ /*
430
+ * monitoredRegions
431
+ *
432
+ * Discussion:
433
+ * Retrieve a set of objects for the regions that are currently being monitored. If any location manager
434
+ * has been instructed to monitor a region, during this or previous launches of your application, it will
435
+ * be present in this set.
436
+ */
437
+ @property (readonly, nonatomic, copy) NSSet<__kindof CLRegion *> *monitoredRegions API_AVAILABLE(ios(4.0), macos(10.8)) API_UNAVAILABLE(watchos, tvos, visionos);
438
+
439
+ /*
440
+ * rangedRegions
441
+ *
442
+ * Discussion:
443
+ * Retrieve a set of objects representing the regions for which this location manager is actively providing ranging.
444
+ */
445
+ @property (readonly, nonatomic, copy) NSSet<__kindof CLRegion *> *rangedRegions API_DEPRECATED("Use -rangedBeaconConstraints", ios(7.0, 13.0), macos(10.15, 10.15), macCatalyst(14.0, 14.0)) API_UNAVAILABLE(watchos, tvos, visionos);
446
+
447
+ /*
448
+ * rangedBeaconConstraints
449
+ *
450
+ * Discussion:
451
+ * Retrieve a set of beacon constraints for which this location manager is actively providing ranging.
452
+ */
453
+ @property (readonly, nonatomic, copy) NSSet<CLBeaconIdentityConstraint *> *rangedBeaconConstraints API_AVAILABLE(ios(13.0), macos(10.15)) API_UNAVAILABLE(watchos, tvos, visionos);
454
+
455
+ /*
456
+ * requestWhenInUseAuthorization
457
+ *
458
+ * Discussion:
459
+ * When -authorizationStatus == kCLAuthorizationStatusNotDetermined,
460
+ * calling this method will trigger a prompt to request "when-in-use"
461
+ * authorization from the user. Any authorization change as a result of
462
+ * the prompt will be reflected via the usual delegate callback:
463
+ * -locationManager:didChangeAuthorizationStatus:.
464
+ *
465
+ * If possible, perform this call in response to direct user request for a
466
+ * location-based service so that the reason for the prompt will be clear,
467
+ * and the utility of a one-time grant is maximized.
468
+ *
469
+ * If received, "when-in-use" authorization grants access to the user's
470
+ * location via any CoreLocation API as long as your app is being actively
471
+ * used by the user. Typically this means your app must be in the
472
+ * foreground. If you start a Continuous Background Location session (see
473
+ * -allowsBackgroundLocationUpdates), then CoreLocation will maintain
474
+ * visibility for your app as it enters the background. This will enable
475
+ * your app to continue receiving location information even as another app
476
+ * enters the foreground. Your app will remain visible in this way until
477
+ * location updates are stopped or your app is killed by the user.
478
+ *
479
+ * When -authorizationStatus != kCLAuthorizationStatusNotDetermined, (ie
480
+ * generally after the first call) this method will do nothing.
481
+ *
482
+ * If your app is not currently in use, this method will do nothing.
483
+ *
484
+ * The NSLocationWhenInUseUsageDescription key must be specified in your
485
+ * Info.plist; otherwise, this method will do nothing, as your app will be
486
+ * assumed not to support WhenInUse authorization.
487
+ */
488
+ - (void)requestWhenInUseAuthorization API_AVAILABLE(ios(8.0), macos(10.15));
489
+
490
+ /*
491
+ * requestAlwaysAuthorization
492
+ *
493
+ * Discussion:
494
+ * When -authorizationStatus == kCLAuthorizationStatusNotDetermined,
495
+ * calling this method will start the process of requesting "always"
496
+ * authorization from the user. Any authorization change as a result of
497
+ * the prompt will be reflected via the usual delegate callback:
498
+ * -locationManager:didChangeAuthorizationStatus:.
499
+ *
500
+ * If possible, perform this call in response to direct user request for a
501
+ * location-based service so that the reason for the prompt will be clear,
502
+ * and the utility of a one-time grant is maximized.
503
+ *
504
+ * If received, "always" authorization grants access to the user's location
505
+ * via any CLLocationManager API. In addition, monitoring APIs may launch
506
+ * your app into the background when they detect an event. Even if killed by
507
+ * the user, launch events triggered by monitoring APIs will cause a
508
+ * relaunch.
509
+ *
510
+ * "Always" authorization presents a significant risk to user privacy, and
511
+ * as such requesting it is discouraged unless background launch behavior
512
+ * is genuinely required. Do not call +requestAlwaysAuthorization unless
513
+ * you think users will thank you for doing so.
514
+ *
515
+ * An application which currently has "when-in-use" authorization and has
516
+ * never before requested "always" authorization may use this method to
517
+ * request "always" authorization one time only. Otherwise, if
518
+ * -authorizationStatus != kCLAuthorizationStatusNotDetermined, (ie
519
+ * generally after the first call) this method will do nothing.
520
+ *
521
+ * If your app is not currently in use, this method will do nothing.
522
+ *
523
+ * Both the NSLocationAlwaysAndWhenInUseUsageDescription and
524
+ * NSLocationWhenInUseUsageDescription keys must be specified in your
525
+ * Info.plist; otherwise, this method will do nothing, as your app will be
526
+ * assumed not to support Always authorization.
527
+ */
528
+ - (void)requestAlwaysAuthorization API_AVAILABLE(ios(8.0), macos(10.15)) API_UNAVAILABLE(tvos, visionos);
529
+
530
+ /*
531
+ * requestTemporaryFullAccuracyAuthorizationWithPurposeKey:completion:
532
+ *
533
+ * Discussion:
534
+ * If your app doesn't have permission to access accurate location (see
535
+ * -accuracyAuthorization), you can use this method to request temporary access
536
+ * to accurate location. This access will expire automatically, but it won't expire
537
+ * while the user is still engaged with your app. So, for example, while your app
538
+ * is in the foreground your app will retain the temporary access it was granted.
539
+ * Similarly, if your app starts a Continuous Background Location session with the
540
+ * background location indicator enabled (see -showsBackgroundLocationIndicator),
541
+ * your access to accurate location will remain as long as the background location
542
+ * indicator remains enabled. This allows your app to provide session-oriented
543
+ * experiences which require accurate location (e.g. fitness or navigation), even if
544
+ * the user has decided not to grant your app persistent access to accurate location.
545
+ *
546
+ * When CoreLocation prepares the prompt for display, it will look at the
547
+ * NSLocationTemporaryUsageDescriptionDictionary key in your Info.plist. The value
548
+ * should be a dictionary containing usage descriptions. The purposeKey you provide
549
+ * to this method must correspond to an entry in that dictionary. To retrieve a
550
+ * localized string, CoreLocation will load your InfoPlist.strings file and try to
551
+ * look up a string using the purposeKey you provided. If that fails, CoreLocation
552
+ * will use the content provided in your Info.plist. For example, suppose your
553
+ * Info.plist contains the following.
554
+ *
555
+ * <key>NSLocationTemporaryUsageDescriptionDictionary</key>
556
+ * <dict>
557
+ * <key>ExampleUsageDescription</key>
558
+ * <string>This app needs accurate location so it can verify that you're in a supported region.</string>
559
+ * <key>AnotherUsageDescription</key>
560
+ * <string>This app needs accurate location so it can show you relevant results.</string>
561
+ * </dict>
562
+ *
563
+ * In this case, you would be able to provide either "ExampleUsageDescription" or
564
+ * "AnotherUsageDescription" for the purposeKey argument. Passing any other string
565
+ * would result in the prompt not being displayed. To localize these usage
566
+ * descriptions, you would add entries for "ExampleUsageDescription" and
567
+ * "AnotherUsageDescription" to your InfoPlist.strings file.
568
+ *
569
+ * CoreLocation may decide against showing the user a prompt. For example, if your
570
+ * app already has access to accurate location or it is currently in the background.
571
+ * When that happens, your completion block will be called with an appropriate
572
+ * NSError. If the user responded to the prompt, your completion block will be
573
+ * called with a nil error. At that point, you may query the state of your
574
+ * CLLocationManager to see if you have been granted accurate access.
575
+ *
576
+ * The completion block will be called in the same threading context where delegate
577
+ * callbacks occur. That is, it will be called on the runloop where the
578
+ * CLLocationManager was originally initialized.
579
+ */
580
+ - (void)requestTemporaryFullAccuracyAuthorizationWithPurposeKey:(NSString *)purposeKey completion:(void(^ _Nullable)(NSError * _Nullable))completion API_AVAILABLE(ios(14.0), macos(11.0), watchos(7.0), tvos(14.0));
581
+
582
+ /*
583
+ * requestTemporaryFullAccuracyAuthorizationWithPurposeKey:
584
+ *
585
+ * Discussion:
586
+ * This is a variant of requestTemporaryAccurateLocationAuthorizationWithPurposeKey:completion:
587
+ * which doesn't take a completion block. This is equivalent to passing in a nil
588
+ * completion block.
589
+ */
590
+ - (void)requestTemporaryFullAccuracyAuthorizationWithPurposeKey:(NSString *)purposeKey API_AVAILABLE(ios(14.0), macos(11.0), watchos(7.0), tvos(14.0));
591
+
592
+ /*
593
+ * startUpdatingLocation
594
+ *
595
+ * Discussion:
596
+ * Start updating locations.
597
+ */
598
+ - (void)startUpdatingLocation API_AVAILABLE(watchos(3.0)) API_UNAVAILABLE(tvos);
599
+
600
+ /*
601
+ * stopUpdatingLocation
602
+ *
603
+ * Discussion:
604
+ * Stop updating locations.
605
+ */
606
+ - (void)stopUpdatingLocation;
607
+
608
+ /*
609
+ * requestLocation
610
+ *
611
+ * Discussion:
612
+ * Request a single location update.
613
+ *
614
+ * The service will attempt to determine location with accuracy according
615
+ * to the desiredAccuracy property. The location update will be delivered
616
+ * via the standard delegate callback, i.e. locationManager:didUpdateLocations:
617
+ *
618
+ * If the best available location has lower accuracy, then it will be
619
+ * delivered via the standard delegate callback after timeout.
620
+ *
621
+ * If no location can be determined, the locationManager:didFailWithError:
622
+ * delegate callback will be delivered with error location unknown.
623
+ *
624
+ * There can only be one outstanding location request and this method can
625
+ * not be used concurrently with startUpdatingLocation or
626
+ * allowDeferredLocationUpdates. Calling either of those methods will
627
+ * immediately cancel the location request. The method
628
+ * stopUpdatingLocation can be used to explicitly cancel the request.
629
+ */
630
+ - (void)requestLocation API_AVAILABLE(ios(9.0), macos(10.14));
631
+
632
+ /*
633
+ * startUpdatingHeading
634
+ *
635
+ * Discussion:
636
+ * Start updating heading.
637
+ */
638
+ - (void)startUpdatingHeading API_AVAILABLE(ios(3.0), macos(10.15), watchos(2.0)) API_UNAVAILABLE(tvos, visionos);
639
+
640
+ /*
641
+ * stopUpdatingHeading
642
+ *
643
+ * Discussion:
644
+ * Stop updating heading.
645
+ */
646
+ - (void)stopUpdatingHeading API_AVAILABLE(ios(3.0), watchos(2.0)) API_UNAVAILABLE(tvos, macos, visionos);
647
+
648
+ /*
649
+ * dismissHeadingCalibrationDisplay
650
+ *
651
+ * Discussion:
652
+ * Dismiss the heading calibration immediately.
653
+ */
654
+ - (void)dismissHeadingCalibrationDisplay API_AVAILABLE(ios(3.0), macos(10.15), watchos(2.0)) API_UNAVAILABLE(tvos, visionos);
655
+
656
+ /*
657
+ * startMonitoringSignificantLocationChanges
658
+ *
659
+ * Discussion:
660
+ * Start monitoring significant location changes. The behavior of this service is not affected by the desiredAccuracy
661
+ * or distanceFilter properties. Locations will be delivered through the same delegate callback as the standard
662
+ * location service.
663
+ *
664
+ */
665
+ - (void)startMonitoringSignificantLocationChanges API_AVAILABLE(ios(4.0), macos(10.7)) API_UNAVAILABLE(watchos, tvos, visionos);
666
+
667
+ /*
668
+ * stopMonitoringSignificantLocationChanges
669
+ *
670
+ * Discussion:
671
+ * Stop monitoring significant location changes.
672
+ *
673
+ */
674
+ - (void)stopMonitoringSignificantLocationChanges API_AVAILABLE(ios(4.0), macos(10.7)) API_UNAVAILABLE(watchos, tvos, visionos);
675
+
676
+ /*
677
+ * startMonitoringLocationPushes
678
+ *
679
+ * Discussion:
680
+ * Request an Apple Push Notification service token to be used to send location pushes. Incoming location pushes launch the app's Location Push Service Extension. Requires the com.apple.developer.location.push entitlement.
681
+ *
682
+ */
683
+ - (void)startMonitoringLocationPushesWithCompletion:(void(^ _Nullable)(NSData * _Nullable token, NSError * _Nullable))completion API_AVAILABLE(ios(15.0)) API_UNAVAILABLE(macos, macCatalyst, tvos, watchos, visionos);
684
+
685
+ /*
686
+ * stopMonitoringLocationPushes
687
+ *
688
+ * Discussion:
689
+ * Stop monitoring for location pushes.
690
+ *
691
+ */
692
+ - (void)stopMonitoringLocationPushes API_AVAILABLE(ios(15.0)) API_UNAVAILABLE(macos, macCatalyst, tvos, watchos, visionos);
693
+
694
+ /*
695
+ * startMonitoringForRegion:desiredAccuracy:
696
+ *
697
+ * Discussion:
698
+ * Start monitoring the specified region. desiredAccuracy represents the distance past the border of the region at
699
+ * which the application would like to be notified that the region border has been crossed. This is useful to prevent
700
+ * repeated notifications when the user is on the border of the region. This value will be honored on a best-effort basis,
701
+ * and may not be respected if desiredAccuracy is large with respect to the size of the region, or if the device is not
702
+ * capable of providing the precision desired.
703
+ *
704
+ * If a region of the same type with the same identifier is already being monitored for this application, it will be
705
+ * removed from monitoring.
706
+ *
707
+ * This is done asynchronously and may not be immediately reflected in monitoredRegions.
708
+ */
709
+ - (void)startMonitoringForRegion:(CLRegion *)region
710
+ desiredAccuracy:(CLLocationAccuracy)accuracy API_DEPRECATED_WITH_REPLACEMENT("-startMonitoringForRegion:", ios(4.0, 6.0), macos(10.15, 10.15)) API_UNAVAILABLE(watchos, tvos, visionos);
711
+
712
+ /*
713
+ * stopMonitoringForRegion:
714
+ *
715
+ * Discussion:
716
+ * Stop monitoring the specified region. It is valid to call stopMonitoringForRegion: for a region that was registered
717
+ * for monitoring with a different location manager object, during this or previous launches of your application.
718
+ *
719
+ * This is done asynchronously and may not be immediately reflected in monitoredRegions.
720
+ */
721
+ - (void)stopMonitoringForRegion:(CLRegion *)region API_DEPRECATED_WITH_REPLACEMENT("Use CLMonitor to start or stop monitoring constraint", ios(5.0, API_TO_BE_DEPRECATED), macos(10.8, API_TO_BE_DEPRECATED)) API_UNAVAILABLE(watchos, tvos, visionos);
722
+
723
+ /*
724
+ * startMonitoringForRegion:
725
+ *
726
+ * Discussion:
727
+ * Start monitoring the specified region.
728
+ *
729
+ * If a region of the same type with the same identifier is already being monitored for this application,
730
+ * it will be removed from monitoring. For circular regions, the region monitoring service will prioritize
731
+ * regions by their size, favoring smaller regions over larger regions.
732
+ *
733
+ * This is done asynchronously and may not be immediately reflected in monitoredRegions.
734
+ */
735
+ - (void)startMonitoringForRegion:(CLRegion *)region API_DEPRECATED_WITH_REPLACEMENT("Use CLMonitor to start or stop monitoring constraint", ios(5.0, API_TO_BE_DEPRECATED), macos(10.8, API_TO_BE_DEPRECATED)) API_UNAVAILABLE(watchos, tvos, visionos);
736
+
737
+ /*
738
+ * requestStateForRegion:
739
+ *
740
+ * Discussion:
741
+ * Asynchronously retrieve the cached state of the specified region. The state is returned to the delegate via
742
+ * locationManager:didDetermineState:forRegion:.
743
+ */
744
+ - (void)requestStateForRegion:(CLRegion *)region API_DEPRECATED_WITH_REPLACEMENT("Use CLMonitor to track and query the state for monitored constraints", ios(5.0, API_TO_BE_DEPRECATED), macos(10.8, API_TO_BE_DEPRECATED)) API_UNAVAILABLE(watchos, tvos, visionos);
745
+
746
+ /*
747
+ * startRangingBeaconsInRegion:
748
+ *
749
+ * Discussion:
750
+ * Start calculating ranges for beacons in the specified region.
751
+ */
752
+ - (void)startRangingBeaconsInRegion:(CLBeaconRegion *)region API_DEPRECATED("Use -startRangingBeaconsSatisfyingConstraint:", ios(7.0, 13.0), macos(11.0, 11.0), macCatalyst(14.0, 14.0)) API_UNAVAILABLE(watchos, tvos, visionos);
753
+
754
+ /*
755
+ * stopRangingBeaconsInRegion:
756
+ *
757
+ * Discussion:
758
+ * Stop calculating ranges for the specified region.
759
+ */
760
+ - (void)stopRangingBeaconsInRegion:(CLBeaconRegion *)region API_DEPRECATED("Use -stopRangingBeaconsSatisfyingConstraint:", ios(7.0, 13.0), macos(11.0, 11.0), macCatalyst(14.0, 14.0)) API_UNAVAILABLE(watchos, tvos, visionos);
761
+
762
+ /*
763
+ * startRangingBeaconsSatisfyingConstraint:
764
+ *
765
+ * Discussion:
766
+ * Start producing ranging measurements for beacons that satisfy
767
+ * the provided constraint. Ranging will continue until you pass
768
+ * an equivalent constraint to stopRangingBeaconsSatisfyingConstraint:.
769
+ */
770
+ - (void)startRangingBeaconsSatisfyingConstraint:(CLBeaconIdentityConstraint *)constraint API_AVAILABLE(ios(13.0), macos(10.15)) API_UNAVAILABLE(watchos, tvos, visionos);
771
+
772
+ /*
773
+ * stopRangingBeaconsSatisfyingConstraint:
774
+ *
775
+ * Discussion:
776
+ * Stop an earlier beacon ranging request. See startRangingBeaconsSatisfyingConstraint:.
777
+ */
778
+ - (void)stopRangingBeaconsSatisfyingConstraint:(CLBeaconIdentityConstraint *)constraint API_AVAILABLE(ios(13.0), macos(10.15)) API_UNAVAILABLE(watchos, tvos, visionos);
779
+
780
+ /*
781
+ * allowDeferredLocationUpdatesUntilTraveled:timeout:
782
+ *
783
+ * Discussion:
784
+ * Indicate that the application will allow the location manager to defer
785
+ * location updates until an exit criterion is met. This may allow the
786
+ * device to enter a low-power state in which updates are held for later
787
+ * delivery. Once an exit condition is met, the location manager will
788
+ * continue normal updates until this method is invoked again.
789
+ *
790
+ * Exit conditions, distance and timeout, can be specified using the constants
791
+ * CLLocationDistanceMax and CLTimeIntervalMax, respectively, if you are
792
+ * trying to achieve an unlimited distance or timeout.
793
+ *
794
+ * The CLLocationManagerDelegate will continue to receive normal updates as
795
+ * long as the application remains in the foreground. While the process is
796
+ * in the background, the device may be able to enter a low-power state for
797
+ * portions of the specified distance and time interval. While in this
798
+ * state, locations will be coalesced for later delivery.
799
+ *
800
+ * Location updates will be deferred as much as is reasonable to save
801
+ * power. If another process is using location, the device may not enter a
802
+ * low-power state and instead updates will continue normally. Deferred
803
+ * updates may be interspersed with normal updates if the device exits and
804
+ * re-enters a low-power state.
805
+ *
806
+ * All location updates, including deferred updates, will be delivered via
807
+ * the delegate callback locationManager:didUpdateLocations:
808
+ *
809
+ * When deferred updates have ended, the manager will invoke the delegate
810
+ * callback locationManagerDidFinishDeferredUpdates:withError:. An error
811
+ * will be returned if the manager will not defer updates and the exit
812
+ * criteria have not been met.
813
+ */
814
+ - (void)allowDeferredLocationUpdatesUntilTraveled:(CLLocationDistance)distance
815
+ timeout:(NSTimeInterval)timeout API_DEPRECATED("You can remove calls to this method", ios(6.0, 13.0), macos(10.15, 10.15)) API_UNAVAILABLE(watchos, tvos, visionos);
816
+
817
+ /*
818
+ * disallowDeferredLocationUpdates
819
+ *
820
+ * Discussion:
821
+ * Disallow deferred location updates if previously enabled. Any outstanding
822
+ * updates will be sent and regular location updates will resume.
823
+ */
824
+ - (void)disallowDeferredLocationUpdates API_DEPRECATED("You can remove calls to this method", ios(6.0, 13.0), macos(10.15, 10.15)) API_UNAVAILABLE(watchos, tvos, visionos);
825
+
826
+ /*
827
+ * deferredLocationUpdatesAvailable
828
+ *
829
+ * Discussion:
830
+ * Returns YES if the device supports deferred location updates, otherwise NO.
831
+ */
832
+ + (BOOL)deferredLocationUpdatesAvailable API_DEPRECATED("You can remove calls to this method", ios(6.0, 13.0), macos(10.9, 10.15)) API_UNAVAILABLE(watchos, tvos, visionos);
833
+
834
+ /*
835
+ * requestHistoricalLocationsWithPurposeKey:sampleCount:completionHandler:
836
+ *
837
+ * Discussion:
838
+ * Request asynchronous delivery of historical location information.
839
+ *
840
+ * If the app is currently configured correctly, historical locations are
841
+ * available, and this request is approved by the user via prompt,
842
+ * then the historical locations will be delivered to the completion handler.
843
+ * Otherwise, the completion handler will be invoked with an empty array.
844
+ *
845
+ * Historical location availability is subject to privacy limits and should never
846
+ * be assumed available. If historic location is not available, no prompt will be
847
+ * presented to the user, and the empty array will be returned.
848
+ *
849
+ * The sampleCount parameter may be used to limit the number of returned
850
+ * locations by decimation.
851
+ *
852
+ * Correct configuration requires the App to:
853
+ * - Have effective authorization to receive the user's current location.
854
+ * - Carry the required entitlement:
855
+ * com.apple.developer.corelocation.wilderness-safety
856
+ * - Have a NSLocationWildernessSafetyUsageDescriptionDictionary in its
857
+ * info.plist and related localized resources
858
+ * - Pass a key identifying a usage description string in that dictionary to be
859
+ * included in the prompt to the user if one is shown.
860
+ *
861
+ * The completion handler will receive a non-nil error object in the event of misconfiguration.
862
+ *
863
+ * Requires the com.apple.developer.corelocation.wilderness-safety entitlement.
864
+ *
865
+ */
866
+ - (void)requestHistoricalLocationsWithPurposeKey:(NSString *)purposeKey
867
+ sampleCount:(NSInteger)sampleCount
868
+ completionHandler:(void(^)(NSArray<CLLocation *> *, NSError *_Nullable))handler
869
+ API_AVAILABLE(watchos(9.0)) API_UNAVAILABLE(ios) API_UNAVAILABLE(macos, tvos)
870
+ NS_SWIFT_NAME(requestHistoricalLocations(purposeKey:sampleCount:completionHandler:))
871
+ #ifdef NS_SWIFT_ASYNC_NAME
872
+ NS_SWIFT_ASYNC_NAME(historicalLocations(purposeKey:sampleCount:))
873
+ #endif
874
+ ;
875
+ @end
876
+
877
+ NS_ASSUME_NONNULL_END