react-native-background-geolocation 4.3.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/.github/stale.yml +41 -0
- package/CHANGELOG.md +1131 -0
- package/LICENSE +22 -0
- package/README.md +292 -0
- package/RNBackgroundGeolocation.podspec +27 -0
- package/android/.idea/compiler.xml +22 -0
- package/android/.idea/copyright/profiles_settings.xml +3 -0
- package/android/.idea/encodings.xml +6 -0
- package/android/.idea/gradle.xml +12 -0
- package/android/.idea/misc.xml +4 -0
- package/android/.idea/modules.xml +8 -0
- package/android/.idea/runConfigurations.xml +12 -0
- package/android/RNBackgroundGeolocation.iml +119 -0
- package/android/android.iml +20 -0
- package/android/app.gradle +22 -0
- package/android/build.gradle +62 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.aar +0 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.aar.md5 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.aar.sha1 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.aar.sha256 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.aar.sha512 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.pom +9 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.pom.md5 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.pom.sha1 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.pom.sha256 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager/3.1.33/tslocationmanager-3.1.33.pom.sha512 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager/maven-metadata.xml +14 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.aar +0 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.aar.md5 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.aar.sha1 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.aar.sha256 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.aar.sha512 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.pom +9 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.pom.md5 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.pom.sha1 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.pom.sha256 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/3.1.33/tslocationmanager-reverse-3.1.33.pom.sha512 +1 -0
- package/android/libs/com/transistorsoft/tslocationmanager-reverse/maven-metadata.xml +14 -0
- package/android/proguard-rules.pro +30 -0
- package/android/react-native-background-geolocation-android.iml +229 -0
- package/android/src/main/AndroidManifest.xml +6 -0
- package/android/src/main/java/com/transistorsoft/rnbackgroundgeolocation/HeadlessTask.java +171 -0
- package/android/src/main/java/com/transistorsoft/rnbackgroundgeolocation/RNBackgroundGeolocation.java +33 -0
- package/android/src/main/java/com/transistorsoft/rnbackgroundgeolocation/RNBackgroundGeolocationModule.java +1261 -0
- package/android/src/main/res/values/strings.xml +3 -0
- package/ios/RNBackgroundGeolocation/RNBackgroundGeolocation.h +22 -0
- package/ios/RNBackgroundGeolocation/RNBackgroundGeolocation.m +754 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/Info.plist +57 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/AtomicBoolean.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/ConfigModule.h +21 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/HttpRequest.h +21 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/HttpResponse.h +29 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/LocationManager.h +55 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/LogQuery.h +13 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/SOMotionDetector.h +140 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/SQLQuery.h +34 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSActivityChangeEvent.h +16 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSAuthorization.h +37 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSAuthorizationEvent.h +17 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSCallback.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSConfig.h +304 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSConnectivityChangeEvent.h +17 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSCurrentPositionRequest.h +43 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSDeviceInfo.h +24 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSEnabledChangeEvent.h +15 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSGeofence.h +50 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSGeofenceEvent.h +60 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSGeofenceManager.h +50 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSGeofencesChangeEvent.h +17 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSHeartbeatEvent.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSHttpEvent.h +19 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSHttpService.h +58 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSLocation.h +101 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSLocationManager.h +312 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSPowerSaveChangeEvent.h +14 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSProviderChangeEvent.h +20 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSReachability.h +106 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSSchedule.h +40 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSScheduleEvent.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TSWatchPositionRequest.h +41 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Headers/TransistorAuthorizationToken.h +31 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Info.plist +0 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/Modules/module.modulemap +6 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_armv7/TSLocationManager.framework/TSLocationManager +0 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/AtomicBoolean.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/ConfigModule.h +21 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/HttpRequest.h +21 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/HttpResponse.h +29 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/LocationManager.h +55 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/LogQuery.h +13 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/SOMotionDetector.h +140 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/SQLQuery.h +34 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSActivityChangeEvent.h +16 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSAuthorization.h +37 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSAuthorizationEvent.h +17 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSCallback.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSConfig.h +304 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSConnectivityChangeEvent.h +17 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSCurrentPositionRequest.h +43 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSDeviceInfo.h +24 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSEnabledChangeEvent.h +15 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSGeofence.h +50 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSGeofenceEvent.h +60 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSGeofenceManager.h +50 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSGeofencesChangeEvent.h +17 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSHeartbeatEvent.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSHttpEvent.h +19 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSHttpService.h +58 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSLocation.h +101 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSLocationManager.h +312 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSPowerSaveChangeEvent.h +14 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSProviderChangeEvent.h +20 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSReachability.h +106 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSSchedule.h +40 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSScheduleEvent.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TSWatchPositionRequest.h +41 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Headers/TransistorAuthorizationToken.h +31 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Info.plist +0 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/Modules/module.modulemap +6 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/TSLocationManager +0 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeDirectory +0 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeRequirements +0 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeRequirements-1 +0 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeResources +612 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_i386_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeSignature +0 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/AtomicBoolean.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/ConfigModule.h +21 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/HttpRequest.h +21 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/HttpResponse.h +29 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/LocationManager.h +55 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/LogQuery.h +13 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/SOMotionDetector.h +140 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/SQLQuery.h +34 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSActivityChangeEvent.h +16 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSAuthorization.h +37 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSAuthorizationEvent.h +17 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSCallback.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSConfig.h +304 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSConnectivityChangeEvent.h +17 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSCurrentPositionRequest.h +43 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSDeviceInfo.h +24 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSEnabledChangeEvent.h +15 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSGeofence.h +50 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSGeofenceEvent.h +60 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSGeofenceManager.h +50 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSGeofencesChangeEvent.h +17 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSHeartbeatEvent.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSHttpEvent.h +19 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSHttpService.h +58 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSLocation.h +101 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSLocationManager.h +312 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSPowerSaveChangeEvent.h +14 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSProviderChangeEvent.h +20 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSReachability.h +106 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSSchedule.h +40 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSScheduleEvent.h +18 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSWatchPositionRequest.h +41 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TransistorAuthorizationToken.h +31 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Modules/module.modulemap +6 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Resources/Info.plist +50 -0
- package/ios/RNBackgroundGeolocation/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/TSLocationManager +0 -0
- package/ios/RNBackgroundGeolocation.xcodeproj/project.pbxproj +341 -0
- package/ios/RNBackgroundGeolocation.xcodeproj/project.xcworkspace/contents.xcworkspacedata +7 -0
- package/ios/RNBackgroundGeolocation.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +8 -0
- package/ios/RNBackgroundGeolocation.xcodeproj/project.xcworkspace/xcshareddata/RNBackgroundGeolocation.xccheckout +41 -0
- package/ios/RNBackgroundGeolocation.xcodeproj/project.xcworkspace/xcuserdata/chris.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
- package/ios/RNBackgroundGeolocation.xcodeproj/xcuserdata/chris.xcuserdatad/xcschemes/Build.xcscheme +80 -0
- package/ios/RNBackgroundGeolocation.xcodeproj/xcuserdata/chris.xcuserdatad/xcschemes/RNBackgroundGeolocation.xcscheme +113 -0
- package/ios/RNBackgroundGeolocation.xcodeproj/xcuserdata/chris.xcuserdatad/xcschemes/xcschememanagement.plist +37 -0
- package/ios/RNBackgroundGeolocationTests/Info.plist +24 -0
- package/package.json +54 -0
- package/react-native.config.js +20 -0
- package/scripts/cp-declarations +53 -0
- package/scripts/declare-module +3 -0
- package/scripts/docs-index.html +4 -0
- package/scripts/generate-docs +23 -0
- package/scripts/postlink.js +146 -0
- package/scripts/postunlink.js +128 -0
- package/scripts/tsconfig.json +21 -0
- package/scripts/xcode-helpers.js +171 -0
- package/src/DeviceSettings.js +52 -0
- package/src/Events.js +17 -0
- package/src/Logger.js +90 -0
- package/src/NativeModule.js +528 -0
- package/src/TransistorAuthorizationToken.js +73 -0
- package/src/declarations/BackgroundGeolocation.d.ts +1601 -0
- package/src/declarations/interfaces/Authorization.d.ts +156 -0
- package/src/declarations/interfaces/AuthorizationEvent.d.ts +30 -0
- package/src/declarations/interfaces/Config.d.ts +2437 -0
- package/src/declarations/interfaces/ConnectivityChangeEvent.d.ts +18 -0
- package/src/declarations/interfaces/CurrentPositionRequest.d.ts +45 -0
- package/src/declarations/interfaces/DeviceInfo.d.ts +33 -0
- package/src/declarations/interfaces/DeviceSettings.d.ts +223 -0
- package/src/declarations/interfaces/Geofence.d.ts +255 -0
- package/src/declarations/interfaces/GeofenceEvent.d.ts +30 -0
- package/src/declarations/interfaces/GeofencesChangeEvent.d.ts +22 -0
- package/src/declarations/interfaces/HeartbeatEvent.d.ts +20 -0
- package/src/declarations/interfaces/HttpEvent.d.ts +313 -0
- package/src/declarations/interfaces/Location.d.ts +216 -0
- package/src/declarations/interfaces/LocationAuthorizationAlert.d.ts +41 -0
- package/src/declarations/interfaces/Logger.d.ts +359 -0
- package/src/declarations/interfaces/MotionActivityEvent.d.ts +31 -0
- package/src/declarations/interfaces/MotionChangeEvent.d.ts +15 -0
- package/src/declarations/interfaces/Notification.d.ts +484 -0
- package/src/declarations/interfaces/PermissionRationale.d.ts +31 -0
- package/src/declarations/interfaces/ProviderChangeEvent.d.ts +74 -0
- package/src/declarations/interfaces/SQLQuery.d.ts +60 -0
- package/src/declarations/interfaces/Sensors.d.ts +31 -0
- package/src/declarations/interfaces/State.d.ts +51 -0
- package/src/declarations/interfaces/TransistorAuthorizationToken.d.ts +63 -0
- package/src/declarations/interfaces/WatchPositionRequest.d.ts +45 -0
- package/src/declarations/types.d.ts +170 -0
- package/src/index.d.ts +1 -0
- package/src/index.js +822 -0
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/// <reference path="../types.d.ts" />
|
|
2
|
+
///
|
|
3
|
+
declare module "react-native-background-geolocation" {
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* __[Android only]__ Configuration for showing an android dialog prior to forwarding the user to a permission settings-screen.
|
|
7
|
+
*
|
|
8
|
+
*/
|
|
9
|
+
interface PermissionRationale {
|
|
10
|
+
/**
|
|
11
|
+
* The title of the dialog window.
|
|
12
|
+
*/
|
|
13
|
+
title?: string;
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* The body text of the dialog.
|
|
17
|
+
* Provide an explanation of why you need this permission, similar in purpose to iOS' __`NSLocationAlwaysAndWhenInUseUsageDescription`__.
|
|
18
|
+
*/
|
|
19
|
+
message?: string;
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* The text to display on the *positive action* button.
|
|
23
|
+
*/
|
|
24
|
+
positiveAction?: string;
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* The text to display on the *negative action* button (eg: *Cancel*)
|
|
28
|
+
*/
|
|
29
|
+
negativeAction?: string;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/// <reference path="../types.d.ts" />
|
|
2
|
+
|
|
3
|
+
declare module "react-native-background-geolocation" {
|
|
4
|
+
/**
|
|
5
|
+
* The event-object provided to [[BackgroundGeolocation.onProviderChange]]
|
|
6
|
+
*
|
|
7
|
+
* @example
|
|
8
|
+
* ```typescript
|
|
9
|
+
* BackgroundGeolocation.onProviderChange(providerChangeEvent => {
|
|
10
|
+
* console.log("[providerchange] ", provider.enabled, provider.status, provider.network, provider.gps);
|
|
11
|
+
* });
|
|
12
|
+
* ```
|
|
13
|
+
*/
|
|
14
|
+
interface ProviderChangeEvent {
|
|
15
|
+
/**
|
|
16
|
+
* `true` When device location-services are enabled.
|
|
17
|
+
*/
|
|
18
|
+
enabled: boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Authorization status of location-services. For iOS, this will tell you if the user has enabled "Always" or "When in Use" authorization.
|
|
21
|
+
*
|
|
22
|
+
* | Name | Platform |
|
|
23
|
+
* |-----------------------------------------|---------------|
|
|
24
|
+
* | [[AUTHORIZATION_STATUS_NOT_DETERMINED]] | iOS only |
|
|
25
|
+
* | [[AUTHORIZATION_STATUS_RESTRICTED]] | iOS only |
|
|
26
|
+
* | [[AUTHORIZATION_STATUS_DENIED]] | iOS & Android |
|
|
27
|
+
* | [[AUTHORIZATION_STATUS_ALWAYS]] | iOS & Android |
|
|
28
|
+
* | [[AUTHORIZATION_STATUS_WHEN_IN_USE]] | iOS only |
|
|
29
|
+
*
|
|
30
|
+
* ### ℹ️ Note:
|
|
31
|
+
* - When Android location permission is **granted**, `status` == [[AUTHORIZATION_STATUS_ALWAYS]], otherwise [[AUTHORIZATION_STATUS_DENIED]].
|
|
32
|
+
*/
|
|
33
|
+
status: AuthorizationStatus;
|
|
34
|
+
/**
|
|
35
|
+
* `true` if network geolocation provider is available.
|
|
36
|
+
*/
|
|
37
|
+
network: boolean;
|
|
38
|
+
/**
|
|
39
|
+
* `true` if GPS geolocation provider is available.
|
|
40
|
+
*/
|
|
41
|
+
gps: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* __`[iOS 14+]`__ iOS 14 has introduced a new __`[Precise: On]`__ switch on the location authorization dialog allowing users to disable high-accuracy location.
|
|
44
|
+
*
|
|
45
|
+
* This attribute shows the state of that switch:
|
|
46
|
+
* - Enabled: [[BackgroundGeolocation.ACCURACY_AUTHORIZATION_FULL]].
|
|
47
|
+
* - Disabled, [[BackgroundGeolocation.ACCURACY_AUTHORIZATION_REDUCED]].
|
|
48
|
+
*
|
|
49
|
+
* 
|
|
50
|
+
*
|
|
51
|
+
* @example
|
|
52
|
+
*
|
|
53
|
+
* ```javascript
|
|
54
|
+
* BackgroundGeolocation.onProviderChange((event) => {
|
|
55
|
+
* let authorizationStatus = event.authorizationStatus;
|
|
56
|
+
* if (authorizationStatus == BackgroundGeolocation.ACCURACY_AUTHORIZATION_REDUCED) {
|
|
57
|
+
* // Supply "Purpose" key from Info.plist as 1st argument.
|
|
58
|
+
* BackgroundGeolocaiton.requestTemporaryFullAccuracy("Delivery").then((accuracyAuthorization) => {
|
|
59
|
+
* console.log("[requestTemporaryFullAccuracy]: ", accuracyAuthorization);
|
|
60
|
+
* }).catch((error) => {
|
|
61
|
+
* console.warn("[requestTemporaryFullAccuracy] ERROR:", error);
|
|
62
|
+
* });
|
|
63
|
+
* }
|
|
64
|
+
* });
|
|
65
|
+
* ```
|
|
66
|
+
*
|
|
67
|
+
* __See also:__
|
|
68
|
+
* - [[BackgroundGeolocation.requestTemporaryFullAccuracy]]
|
|
69
|
+
* - [What's new in iOS 14 `CoreLocation`](https://levelup.gitconnected.com/whats-new-with-corelocation-in-ios-14-bd28421c95c4)
|
|
70
|
+
*
|
|
71
|
+
*/
|
|
72
|
+
accuracyAuthorization: AccuracyAuthorization;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
declare module "react-native-background-geolocation" {
|
|
2
|
+
/**
|
|
3
|
+
* Used for selecting a range of records from the SDK"s database.
|
|
4
|
+
* Used with the methods:
|
|
5
|
+
* - [[Logger.getLog]]
|
|
6
|
+
* - [[Logger.emailLog]]
|
|
7
|
+
* - [[Logger.uploadLog]]
|
|
8
|
+
*
|
|
9
|
+
* ```typescript
|
|
10
|
+
* // Constrain results between optionl start/end dates using a SQLQuery
|
|
11
|
+
* let log = await BackgroundGeolocation.logger.getLog({
|
|
12
|
+
* start: Date.parse("2019-10-21 13:00"), // <-- optional HH:mm:ss
|
|
13
|
+
* end: Date.parse("2019-10-22")
|
|
14
|
+
* });
|
|
15
|
+
*
|
|
16
|
+
* // Or just a start date
|
|
17
|
+
* let log = await BackgroundGeolocation.logger.getLog({
|
|
18
|
+
* start: Date.parse("2019-10-21 13:00")
|
|
19
|
+
* });
|
|
20
|
+
*
|
|
21
|
+
* // Or just an end date
|
|
22
|
+
* BackgroundGeolocation.logger.uploadLog("http://my.server.com/users/123/logs", {
|
|
23
|
+
* end: Date.parse("2019-10-21")
|
|
24
|
+
* ));
|
|
25
|
+
*
|
|
26
|
+
* // Select first 100 records from log
|
|
27
|
+
* let Logger = BackgroundGeolocation.logger;
|
|
28
|
+
* Logger.emailLog("foo@bar.com", {
|
|
29
|
+
* order: Logger.ORDER_ASC,
|
|
30
|
+
* limit: 100
|
|
31
|
+
* ));
|
|
32
|
+
*
|
|
33
|
+
* // Select most recent 100 records from log
|
|
34
|
+
* let Logger = BackgroundGeolocation.logger;
|
|
35
|
+
* Logger.emailLog("foo@bar.com", {
|
|
36
|
+
* order: Logger.ORDER_DESC,
|
|
37
|
+
* limit: 100
|
|
38
|
+
* ));
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
interface SQLQuery {
|
|
42
|
+
/**
|
|
43
|
+
* Start date of logs to select (unix timestamp)
|
|
44
|
+
*/
|
|
45
|
+
start?:number;
|
|
46
|
+
/**
|
|
47
|
+
* End date of logs to select (unix timestamp)
|
|
48
|
+
*/
|
|
49
|
+
end?:number;
|
|
50
|
+
/**
|
|
51
|
+
* Limit number of records returned.
|
|
52
|
+
*/
|
|
53
|
+
limit?:number;
|
|
54
|
+
/**
|
|
55
|
+
* Order of results [[Logger.ORDER_ASC]] or [[Logger.ORDER_DESC]].
|
|
56
|
+
* `1` = `ASC`; `-1` = `DESC`.
|
|
57
|
+
*/
|
|
58
|
+
order?:SQLQueryOrder;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
declare module "react-native-background-geolocation" {
|
|
2
|
+
/**
|
|
3
|
+
* Detected device sensors related to motion-detection.
|
|
4
|
+
*/
|
|
5
|
+
interface Sensors {
|
|
6
|
+
/**
|
|
7
|
+
* `ios` | `android`
|
|
8
|
+
*/
|
|
9
|
+
platform: string;
|
|
10
|
+
/**
|
|
11
|
+
* `true` when the device has an accelerometer.
|
|
12
|
+
*/
|
|
13
|
+
accelerometer: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* `true` when the device has a magnetometer (compass).
|
|
16
|
+
*/
|
|
17
|
+
magnetometer: boolean;
|
|
18
|
+
/**
|
|
19
|
+
* `true` when the device has a gyroscope.
|
|
20
|
+
*/
|
|
21
|
+
gyroscope: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* __[Android only]__ `true` when the Android device has significant motion hardware.
|
|
24
|
+
*/
|
|
25
|
+
significant_motion?: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* __[iOS only]__ `true` when the device has an __M7__ motion co-processor (iPhone 5S and up).
|
|
28
|
+
*/
|
|
29
|
+
motion_hardware?: boolean;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/// <reference path="./Config.d.ts" />
|
|
2
|
+
|
|
3
|
+
declare module "react-native-background-geolocation" {
|
|
4
|
+
/**
|
|
5
|
+
* This `State` object contains all the provided [[Config]] options in addition to:
|
|
6
|
+
* - [[enabled]].
|
|
7
|
+
* - [[schedulerEnabled]].
|
|
8
|
+
* - [[trackingMode]].
|
|
9
|
+
* - [[odometer]].
|
|
10
|
+
* - [[didLaunchInBackground]].
|
|
11
|
+
* - [[didDeviceReboot]]
|
|
12
|
+
*/
|
|
13
|
+
interface State extends Config {
|
|
14
|
+
/**
|
|
15
|
+
* `true` when the SDK has been enabled via methods [[start]] or [[startGeofences]]. When `false`, the
|
|
16
|
+
* SDK is completely __OFF__. No tracking of any kind will occur. The SDK will consume no energy.
|
|
17
|
+
*/
|
|
18
|
+
enabled: boolean;
|
|
19
|
+
/**
|
|
20
|
+
* `true` when the SDK is currently configured with a [[schedule]] and [[startSchedule]] has been executed.
|
|
21
|
+
* [[stopSchedule]] will set this to `false`.
|
|
22
|
+
*/
|
|
23
|
+
schedulerEnabled: boolean;
|
|
24
|
+
/**
|
|
25
|
+
| Value | Description |
|
|
26
|
+
|------------|-----------------------------------|
|
|
27
|
+
| __`0`__ | Monitoring geofences only |
|
|
28
|
+
| __`1`__ | Monitoring location + geofences |
|
|
29
|
+
*/
|
|
30
|
+
trackingMode: TrackingMode;
|
|
31
|
+
/**
|
|
32
|
+
* The current distance-traveled.
|
|
33
|
+
* ### ℹ️ See also:
|
|
34
|
+
* - [[resetOdometer]], [[setOdometer]]
|
|
35
|
+
* - [[getOdometer]]
|
|
36
|
+
*/
|
|
37
|
+
odometer: number;
|
|
38
|
+
/**
|
|
39
|
+
* `true` when the iOS app was launched in the background. Always `false` for Android.
|
|
40
|
+
* iOS apps can be launched in the background due to a background-fetch event, geofence events or exiting the [[Config.stationaryRadius]].
|
|
41
|
+
*
|
|
42
|
+
* One might use this flag to choose to load only minimal resources until the iOS app is determined to have launched into the foreground.
|
|
43
|
+
*
|
|
44
|
+
*/
|
|
45
|
+
didLaunchInBackground: boolean;
|
|
46
|
+
/**
|
|
47
|
+
* Indicates if the app was launched after the device was rebooted.
|
|
48
|
+
*/
|
|
49
|
+
didDeviceReboot: boolean;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
declare module "react-native-background-geolocation" {
|
|
2
|
+
/**
|
|
3
|
+
* Response object returned by [[BackgroundGeolocation.findOrCreateTransistorAuthorizationToken]] for configuring the SDK's [[Authorization]] with Transistor Software's Demo Server at [http://tracker.transistorsoft.com](http://tracker.transistorsoft.com).
|
|
4
|
+
*
|
|
5
|
+
* You may also run your own instance of Demo Server locally. See [background-geolocation-console](https://github.com/transistorsoft/background-geolocation-console)
|
|
6
|
+
*
|
|
7
|
+
* The test server is a great way to debug location problems or evalute the SDK's behaviour, since the results can easily be shared with *Transistor Software* when requesting support.
|
|
8
|
+
*
|
|
9
|
+
* 
|
|
10
|
+
*
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```typescript
|
|
14
|
+
* // Url to demo server.
|
|
15
|
+
* let url = "http://tracker.transistorsoft.com";
|
|
16
|
+
* let orgname = "my-company-name";
|
|
17
|
+
* let username = "my-username";
|
|
18
|
+
*
|
|
19
|
+
* // Fetch an authoriztion token from server. The SDK will cache the received token.
|
|
20
|
+
* let token = await
|
|
21
|
+
* BackgroundGeolocation.findOrCreateTransistorAuthorizationToken(orgname, username, url);
|
|
22
|
+
*
|
|
23
|
+
* BackgroundGeolocation.ready({
|
|
24
|
+
* transistorAuthorizationToken: token
|
|
25
|
+
* })
|
|
26
|
+
* ```
|
|
27
|
+
*
|
|
28
|
+
* ## Viewing Your Tracking Results
|
|
29
|
+
*
|
|
30
|
+
* To *view* your tracking results in the browser, use your configured "Organization Name" and visit:
|
|
31
|
+
*
|
|
32
|
+
* http://tracker.transistorsoft.com/my-organization-name
|
|
33
|
+
*
|
|
34
|
+
*/
|
|
35
|
+
interface TransistorAuthorizationToken {
|
|
36
|
+
/**
|
|
37
|
+
* The authorization token to provide to [[Authorization.accessToken]]
|
|
38
|
+
*
|
|
39
|
+
* @example
|
|
40
|
+
* ```typescript
|
|
41
|
+
* BackgroundGeolocation.ready({
|
|
42
|
+
* authorization: {
|
|
43
|
+
* accessToken:
|
|
44
|
+
* }
|
|
45
|
+
* });
|
|
46
|
+
* ```
|
|
47
|
+
*/
|
|
48
|
+
accessToken:string;
|
|
49
|
+
/**
|
|
50
|
+
* The token used to request to provide to [[Authorization.refreshToken]]
|
|
51
|
+
*/
|
|
52
|
+
refreshToken:string;
|
|
53
|
+
/**
|
|
54
|
+
* The expiry time of the [[Authorization.accessToken]]
|
|
55
|
+
*/
|
|
56
|
+
expires:number;
|
|
57
|
+
/**
|
|
58
|
+
* The url to the Transistor Demo server where this token came from.
|
|
59
|
+
* __Read only__
|
|
60
|
+
*/
|
|
61
|
+
url?: string;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
declare module "react-native-background-geolocation" {
|
|
2
|
+
/**
|
|
3
|
+
* Options provided to [[BackgroundGeolocation.watchPosition]].
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* ```typescript
|
|
7
|
+
* BackgroundGeolocation.watchPosition((location) => {
|
|
8
|
+
* console.log("[watchPosition] -", location);
|
|
9
|
+
* }, (errorCode) => {
|
|
10
|
+
* console.log("[watchPosition] ERROR -", errorCode);
|
|
11
|
+
* }, {
|
|
12
|
+
* interval: 1000,
|
|
13
|
+
* desiredAccuracy: BackgroundGeolocation.DESIRED_ACCURACY_HIGH,
|
|
14
|
+
* persist: true,
|
|
15
|
+
* extras: {foo: "bar"},
|
|
16
|
+
* timeout: 60000
|
|
17
|
+
* });
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
interface WatchPositionRequest {
|
|
21
|
+
/**
|
|
22
|
+
* Location update interval in `milliseconds`. Defaults to `1000`.
|
|
23
|
+
*/
|
|
24
|
+
interval?: number;
|
|
25
|
+
/**
|
|
26
|
+
* Specifies the accuracy required. See [[Config.desiredAccuracy]]. Only [[BackgroundGeolocation.DESIRED_ACCURACY_HIGH]] uses GPS.
|
|
27
|
+
* Defaults to [[DESIRED_ACCURACY_HIGH]].
|
|
28
|
+
*/
|
|
29
|
+
desiredAccuracy?: LocationAccuracy;
|
|
30
|
+
/**
|
|
31
|
+
* Set `true` to persist each recorded location to the plugin's database.
|
|
32
|
+
* Defaults to `true` when [[State.enabled]], `false` otherwise.
|
|
33
|
+
*/
|
|
34
|
+
persist?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* Arbitrary key/values to append to each recorded location.
|
|
37
|
+
*/
|
|
38
|
+
extras?: Extras;
|
|
39
|
+
/**
|
|
40
|
+
* Time in `milliseconds` to wait before firing error callback when location fails to arrive.
|
|
41
|
+
* Defaults to `60000`.
|
|
42
|
+
*/
|
|
43
|
+
timeout?: number;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
declare module "react-native-background-geolocation" {
|
|
2
|
+
/**
|
|
3
|
+
* Recognized event names available as constants upon the [[BackgroundGeolocation]] class.
|
|
4
|
+
*
|
|
5
|
+
* ```javascript
|
|
6
|
+
* // eg
|
|
7
|
+
* BackgroundGeolocation.EVENT_LOCATION)
|
|
8
|
+
* > "location"
|
|
9
|
+
*
|
|
10
|
+
* BackgoundGeolocation.EVENT_MOTIONCHANGE;
|
|
11
|
+
* > "motionchange"
|
|
12
|
+
*
|
|
13
|
+
* ```
|
|
14
|
+
*
|
|
15
|
+
* | Name | Value |
|
|
16
|
+
* |-------------------------------------|-----------|
|
|
17
|
+
* | [[EVENT_BOOT]] | `boot` |
|
|
18
|
+
* | [[EVENT_TERMINATE]] | `terminate` |
|
|
19
|
+
* | [[EVENT_LOCATION]] | `location` |
|
|
20
|
+
* | [[EVENT_MOTIONCHANGE]] | `motionchange` |
|
|
21
|
+
* | [[EVENT_HTTP]] | `http` |
|
|
22
|
+
* | [[EVENT_HEARTBEAT]] | `heartbeat` |
|
|
23
|
+
* | [[EVENT_PROVIDERCHANGE]] | `providerchange` |
|
|
24
|
+
* | [[EVENT_ACTIVITYCHANGE]] | `activitychange` |
|
|
25
|
+
* | [[EVENT_GEOFENCE]] | `geofence` |
|
|
26
|
+
* | [[EVENT_GEOFENCESCHANGE]] | `geofenceschange` |
|
|
27
|
+
* | [[EVENT_ENABLEDCHANGE]] | `enabledchange` |
|
|
28
|
+
* | [[EVENT_CONNECTIVITYCHANGE]] | `connectivitychange` |
|
|
29
|
+
* | [[EVENT_SCHEDULE]] | `schedule` |
|
|
30
|
+
* | [[EVENT_POWERSAVECHANGE]] | `powersavechange` |
|
|
31
|
+
* | [[EVENT_NOTIFICATIONACTION]] | `notificationaction` |
|
|
32
|
+
* | [[EVENT_AUTHORIZATION]] | `authorization` |
|
|
33
|
+
*/
|
|
34
|
+
export type Event = "boot"
|
|
35
|
+
| "terminate"
|
|
36
|
+
| "location"
|
|
37
|
+
| "motionchange"
|
|
38
|
+
| "http"
|
|
39
|
+
| "heartbeat"
|
|
40
|
+
| "providerchange"
|
|
41
|
+
| "activitychange"
|
|
42
|
+
| "geofence"
|
|
43
|
+
| "geofenceschange"
|
|
44
|
+
| "enabledchange"
|
|
45
|
+
| "connectvitychange"
|
|
46
|
+
| "schedule"
|
|
47
|
+
| "powersavechange"
|
|
48
|
+
| "notificationaction"
|
|
49
|
+
| "authorization";
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Controls the volume of [[Config.logLevel]] log-entries recorded to database.
|
|
53
|
+
*
|
|
54
|
+
* | Label |
|
|
55
|
+
* |----------------------------|
|
|
56
|
+
* | [[LOG_LEVEL_OFF]] |
|
|
57
|
+
* | [[LOG_LEVEL_ERROR]] |
|
|
58
|
+
* | [[LOG_LEVEL_WARNING]] |
|
|
59
|
+
* | [[LOG_LEVEL_INFO]] |
|
|
60
|
+
* | [[LOG_LEVEL_DEBUG]] |
|
|
61
|
+
* | [[LOG_LEVEL_VERBOSE]] |
|
|
62
|
+
*/
|
|
63
|
+
export type LogLevel = 0 | 1 | 2 | 3 | 4 | 5;
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Used for [[Config.desiredAccuracy]].
|
|
67
|
+
*
|
|
68
|
+
* | Name | Location Providers | Description |
|
|
69
|
+
* |--------------------------------------|------------------------------|-----------------------------------------|
|
|
70
|
+
* | [[DESIRED_ACCURACY_NAVIGATION]] | (**iOS only**) GPS + Wifi + Cellular | Highest power; highest accuracy.|
|
|
71
|
+
* | [[DESIRED_ACCURACY_HIGH]] | GPS + Wifi + Cellular | Highest power; highest accuracy. |
|
|
72
|
+
* | [[DESIRED_ACCURACY_MEDIUM]] | Wifi + Cellular | Medium power; Medium accuracy; |
|
|
73
|
+
* | [[DESIRED_ACCURACY_LOW]] | Wifi (low power) + Cellular | Lower power; No GPS. |
|
|
74
|
+
* | [[DESIRED_ACCURACY_VERY_LOW]] | Cellular only | Lowest power; lowest accuracy. |
|
|
75
|
+
* | [[DESIRED_ACCURACY_LOWEST]] | (**iOS only**) | Lowest power; lowest accuracy. |
|
|
76
|
+
*/
|
|
77
|
+
type LocationAccuracy = -2 | -1 | 0 | 10 | 100 | 1000 | 3000;
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* Used for [[Notification.priority]].
|
|
81
|
+
*
|
|
82
|
+
* | Value | Description |
|
|
83
|
+
* |-----------------------------------|--------------------------------------------------------------------------------------------------------|
|
|
84
|
+
* | [[NOTIFICATION_PRIORITY_DEFAULT]] | Notification weighted to top of list; notification-bar icon weighted left. |
|
|
85
|
+
* | [[NOTIFICATION_PRIORITY_HIGH]] | Notification **strongly** weighted to top of list; notification-bar icon **strongly** weighted to left.|
|
|
86
|
+
* | [[NOTIFICATION_PRIORITY_LOW]] | Notification weighted to bottom of list; notification-bar icon weighted right. |
|
|
87
|
+
* | [[NOTIFICATION_PRIORITY_MAX]] | Same as `NOTIFICATION_PRIORITY_HIGH`. |
|
|
88
|
+
* | [[NOTIFICATION_PRIORITY_MIN]] | Notification **strongly** weighted to bottom of list; notification-bar icon **hidden**. |
|
|
89
|
+
*/
|
|
90
|
+
type NotificationPriority = 0 | 1 | -1 | 2 | -2;
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* Used for [[Config.activityType]].
|
|
94
|
+
*
|
|
95
|
+
* | Name |
|
|
96
|
+
* |------------------------------------------|
|
|
97
|
+
* | [[ACTIVITY_TYPE_OTHER]] |
|
|
98
|
+
* | [[ACTIVITY_TYPE_AUTOMOTIVE_NAVIGATION]] |
|
|
99
|
+
* | [[ACTIVITY_TYPE_FITNESS]] |
|
|
100
|
+
* | [[ACTIVITY_TYPE_OTHER_NAVIGATION]] |
|
|
101
|
+
*
|
|
102
|
+
* ℹ️ For more information, see [Apple docs](https://developer.apple.com/reference/corelocation/cllocationmanager/1620567-activitytype?language=objc).
|
|
103
|
+
*/
|
|
104
|
+
type ActivityType = 1 | 2 | 3 | 4;
|
|
105
|
+
/**
|
|
106
|
+
* | Name | Platform |
|
|
107
|
+
* |-----------------------------------------|---------------|
|
|
108
|
+
* | [[AUTHORIZATION_STATUS_NOT_DETERMINED]] | iOS only |
|
|
109
|
+
* | [[AUTHORIZATION_STATUS_RESTRICTED]] | iOS only |
|
|
110
|
+
* | [[AUTHORIZATION_STATUS_DENIED]] | iOS & Android |
|
|
111
|
+
* | [[AUTHORIZATION_STATUS_ALWAYS]] | iOS & Android |
|
|
112
|
+
* | [[AUTHORIZATION_STATUS_WHEN_IN_USE]] | iOS only |
|
|
113
|
+
*/
|
|
114
|
+
type AuthorizationStatus = 0 | 1 | 2 | 3 | 4;
|
|
115
|
+
|
|
116
|
+
/**
|
|
117
|
+
* | Name | Value |
|
|
118
|
+
* |-----------------------------------------|-----------|
|
|
119
|
+
* | [[ACCURACY_AUTHORIZATION_FULL]] | 0 |
|
|
120
|
+
* | [[ACCURACY_AUTHORIZATION_REDUCED]] | 1 |
|
|
121
|
+
*/
|
|
122
|
+
type AccuracyAuthorization = 0 | 1;
|
|
123
|
+
|
|
124
|
+
/**
|
|
125
|
+
* | Value | Description |
|
|
126
|
+
* |----------|-----------------------------------------------------------------------|
|
|
127
|
+
* | `0` | Geofences-only monitoring ([[BackgroundGeolocation.startGeofences]]). |
|
|
128
|
+
* | `1` | Both location & Geofence monitoring. |
|
|
129
|
+
*/
|
|
130
|
+
type TrackingMode = 0 | 1;
|
|
131
|
+
|
|
132
|
+
/**
|
|
133
|
+
* When native location API fails to fetch a location, one of the following error-codes will be returned.
|
|
134
|
+
*
|
|
135
|
+
* | Code | Error |
|
|
136
|
+
* |-------|-----------------------------|
|
|
137
|
+
* | 0 | Location unknown |
|
|
138
|
+
* | 1 | Location permission denied |
|
|
139
|
+
* | 2 | Network error |
|
|
140
|
+
* | 408 | Location timeout |
|
|
141
|
+
* | 499 | Location request cancelled |
|
|
142
|
+
*/
|
|
143
|
+
type LocationError = 0 | 1 | 2 | 408 | 499;
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* iOS Location authorization request.
|
|
147
|
+
* This is used to express the location authorization you *expect* the user have enabled.
|
|
148
|
+
*/
|
|
149
|
+
type LocationAuthorizationRequest = "Always" | "WhenInUse" | "Any";
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* Desired HTTP method to use when uploading data to your configured [[Config.url]].
|
|
153
|
+
*/
|
|
154
|
+
type HttpMethod = "POST" | "PUT" | "OPTIONS";
|
|
155
|
+
|
|
156
|
+
type PersistMode = -1 | 0 | 1 | 2;
|
|
157
|
+
|
|
158
|
+
type Extras = {[key: string]: string|null|number|boolean|Extras|string[]|number[]|boolean[]|Extras[]};
|
|
159
|
+
|
|
160
|
+
/**
|
|
161
|
+
* Controls ordering of [[SQLQuery.order]]
|
|
162
|
+
*
|
|
163
|
+
* | Name | Value |
|
|
164
|
+
* |----------------------|-------|
|
|
165
|
+
* | [[Logger.ORDER_ASC]] | `1` |
|
|
166
|
+
* | [[Logger.ORDER_DESC]]| `-1` |
|
|
167
|
+
*/
|
|
168
|
+
type SQLQueryOrder = -1 | 1;
|
|
169
|
+
|
|
170
|
+
}
|