@transistorsoft/capacitor-background-geolocation 7.0.5 → 7.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/TransistorsoftCapacitorBackgroundGeolocation.podspec +4 -4
- package/android/libs/com/transistorsoft/tslocationmanager/maven-metadata.xml +1 -1
- package/android/libs/com/transistorsoft/tslocationmanager-v21/maven-metadata.xml +1 -1
- package/package.json +4 -3
- package/ios/Resources/PrivacyInfo.xcprivacy +0 -35
- package/ios/TSLocationManager.xcframework/Info.plist +0 -61
- package/ios/TSLocationManager.xcframework/_CodeSignature/CodeDirectory +0 -0
- package/ios/TSLocationManager.xcframework/_CodeSignature/CodeRequirements +0 -0
- package/ios/TSLocationManager.xcframework/_CodeSignature/CodeRequirements-1 +0 -0
- package/ios/TSLocationManager.xcframework/_CodeSignature/CodeResources +0 -2033
- package/ios/TSLocationManager.xcframework/_CodeSignature/CodeSignature +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/AtomicBoolean.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/ConfigModule.h +0 -21
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/HttpRequest.h +0 -21
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/HttpResponse.h +0 -29
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/LocationManager.h +0 -55
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/LogQuery.h +0 -13
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/SOMotionDetector.h +0 -141
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/SQLQuery.h +0 -34
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSActivityChangeEvent.h +0 -16
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSAuthorization.h +0 -38
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSAuthorizationEvent.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSCallback.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSConfig.h +0 -310
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSConnectivityChangeEvent.h +0 -17
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSCurrentPositionRequest.h +0 -43
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSDeviceInfo.h +0 -24
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSEnabledChangeEvent.h +0 -15
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSGeofence.h +0 -54
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSGeofenceEvent.h +0 -64
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSGeofenceManager.h +0 -54
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSGeofencesChangeEvent.h +0 -17
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSHeartbeatEvent.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSHttpEvent.h +0 -19
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSHttpService.h +0 -58
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSLocation.h +0 -105
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSLocationManager.h +0 -315
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSPowerSaveChangeEvent.h +0 -14
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSProviderChangeEvent.h +0 -20
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSReachability.h +0 -106
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSSchedule.h +0 -40
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSScheduleEvent.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TSWatchPositionRequest.h +0 -41
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Headers/TransistorAuthorizationToken.h +0 -31
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Info.plist +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Miniball/Miniball.hpp +0 -525
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/Modules/module.modulemap +0 -6
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/PrivacyInfo.xcprivacy +0 -36
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/TSLocationManager +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/_CodeSignature/CodeDirectory +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/_CodeSignature/CodeRequirements +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/_CodeSignature/CodeRequirements-1 +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/_CodeSignature/CodeResources +0 -642
- package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/_CodeSignature/CodeSignature +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/AtomicBoolean.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/ConfigModule.h +0 -21
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/HttpRequest.h +0 -21
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/HttpResponse.h +0 -29
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/LocationManager.h +0 -55
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/LogQuery.h +0 -13
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/SOMotionDetector.h +0 -141
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/SQLQuery.h +0 -34
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSActivityChangeEvent.h +0 -16
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSAuthorization.h +0 -38
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSAuthorizationEvent.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSCallback.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSConfig.h +0 -310
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSConnectivityChangeEvent.h +0 -17
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSCurrentPositionRequest.h +0 -43
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSDeviceInfo.h +0 -24
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSEnabledChangeEvent.h +0 -15
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSGeofence.h +0 -54
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSGeofenceEvent.h +0 -64
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSGeofenceManager.h +0 -54
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSGeofencesChangeEvent.h +0 -17
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSHeartbeatEvent.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSHttpEvent.h +0 -19
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSHttpService.h +0 -58
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSLocation.h +0 -105
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSLocationManager.h +0 -315
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSPowerSaveChangeEvent.h +0 -14
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSProviderChangeEvent.h +0 -20
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSReachability.h +0 -106
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSSchedule.h +0 -40
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSScheduleEvent.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TSWatchPositionRequest.h +0 -41
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Headers/TransistorAuthorizationToken.h +0 -31
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Modules/module.modulemap +0 -6
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Resources/Info.plist +0 -50
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Resources/Miniball/Miniball.hpp +0 -525
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/Resources/PrivacyInfo.xcprivacy +0 -36
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/TSLocationManager +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/_CodeSignature/CodeDirectory +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/_CodeSignature/CodeRequirements +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/_CodeSignature/CodeRequirements-1 +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/_CodeSignature/CodeResources +0 -536
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-maccatalyst/TSLocationManager.framework/_CodeSignature/CodeSignature +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/AtomicBoolean.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/ConfigModule.h +0 -21
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/HttpRequest.h +0 -21
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/HttpResponse.h +0 -29
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/LocationManager.h +0 -55
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/LogQuery.h +0 -13
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/SOMotionDetector.h +0 -141
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/SQLQuery.h +0 -34
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSActivityChangeEvent.h +0 -16
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSAuthorization.h +0 -38
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSAuthorizationEvent.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSCallback.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSConfig.h +0 -310
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSConnectivityChangeEvent.h +0 -17
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSCurrentPositionRequest.h +0 -43
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSDeviceInfo.h +0 -24
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSEnabledChangeEvent.h +0 -15
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSGeofence.h +0 -54
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSGeofenceEvent.h +0 -64
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSGeofenceManager.h +0 -54
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSGeofencesChangeEvent.h +0 -17
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSHeartbeatEvent.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSHttpEvent.h +0 -19
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSHttpService.h +0 -58
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSLocation.h +0 -105
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSLocationManager.h +0 -315
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSPowerSaveChangeEvent.h +0 -14
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSProviderChangeEvent.h +0 -20
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSReachability.h +0 -106
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSSchedule.h +0 -40
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSScheduleEvent.h +0 -18
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TSWatchPositionRequest.h +0 -41
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Headers/TransistorAuthorizationToken.h +0 -31
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Info.plist +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Miniball/Miniball.hpp +0 -525
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/Modules/module.modulemap +0 -6
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/PrivacyInfo.xcprivacy +0 -36
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/TSLocationManager +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeDirectory +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeRequirements +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeRequirements-1 +0 -0
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeResources +0 -642
- package/ios/TSLocationManager.xcframework/ios-arm64_x86_64-simulator/TSLocationManager.framework/_CodeSignature/CodeSignature +0 -0
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// TSWatchPositionRequest.h
|
|
3
|
-
// TSLocationManager
|
|
4
|
-
//
|
|
5
|
-
// Created by Christopher Scott on 2018-02-12.
|
|
6
|
-
// Copyright © 2018 Transistor Software. All rights reserved.
|
|
7
|
-
//
|
|
8
|
-
#import "TSLocation.h"
|
|
9
|
-
|
|
10
|
-
@interface TSWatchPositionRequest : NSObject
|
|
11
|
-
|
|
12
|
-
@property (nonatomic) double interval;
|
|
13
|
-
@property (atomic) CLLocationAccuracy desiredAccuracy;
|
|
14
|
-
@property (atomic) BOOL persist;
|
|
15
|
-
@property (atomic) NSDictionary* extras;
|
|
16
|
-
@property (atomic) double timeout;
|
|
17
|
-
@property (atomic, copy) void (^success)(TSLocation*);
|
|
18
|
-
@property (atomic, copy) void (^failure)(NSError*);
|
|
19
|
-
|
|
20
|
-
-(instancetype) init;
|
|
21
|
-
-(instancetype) initWithSuccess:(void (^)(TSLocation*))success failure:(void (^)(NSError*))failure;
|
|
22
|
-
|
|
23
|
-
-(instancetype) initWithInterval:(double)interval
|
|
24
|
-
success:(void (^)(TSLocation*))success
|
|
25
|
-
failure:(void (^)(NSError*))failure;
|
|
26
|
-
|
|
27
|
-
-(instancetype) initWithInterval:(double)interval
|
|
28
|
-
persist:(BOOL)persist
|
|
29
|
-
success:(void (^)(TSLocation*))success
|
|
30
|
-
failure:(void (^)(NSError*))failure;
|
|
31
|
-
|
|
32
|
-
-(instancetype) initWithInterval:(double)interval
|
|
33
|
-
persist:(BOOL)persist
|
|
34
|
-
desiredAccuracy:(CLLocationAccuracy)desiredAccuracy
|
|
35
|
-
extras:(NSDictionary*)extras
|
|
36
|
-
timeout:(double)timeout
|
|
37
|
-
success:(void (^)(TSLocation*))success
|
|
38
|
-
failure:(void (^)(NSError*))failure;
|
|
39
|
-
|
|
40
|
-
@end
|
|
41
|
-
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// TransistorAuthorizationToken.h
|
|
3
|
-
// TSLocationManager
|
|
4
|
-
//
|
|
5
|
-
// Created by Christopher Scott on 2019-11-21.
|
|
6
|
-
// Copyright © 2019 Christopher Scott. All rights reserved.
|
|
7
|
-
//
|
|
8
|
-
#import <Foundation/Foundation.h>
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* TransistorAuthorizationToken for demo server tracker.transistorsoft.com
|
|
12
|
-
*/
|
|
13
|
-
@interface TransistorAuthorizationToken:NSObject
|
|
14
|
-
|
|
15
|
-
@property (nonatomic) NSString* accessToken;
|
|
16
|
-
@property (nonatomic) NSString* refreshToken;
|
|
17
|
-
@property (nonatomic) long expires;
|
|
18
|
-
|
|
19
|
-
+ (void) findOrCreateWithOrg:(NSString*)orgname username:(NSString*)username url:(NSString*)apiUrl framework:(NSString*)framework success:(void(^)(TransistorAuthorizationToken*))success failure:(void(^)(NSError*))error;
|
|
20
|
-
+ (void) destroyWithUrl:(NSString*)url;
|
|
21
|
-
+ (BOOL) hasTokenForHost:(NSString*)host;
|
|
22
|
-
|
|
23
|
-
- (instancetype) initWithAccessToken:(NSString*)accessToken refreshToken:(NSString*)refreshToken expires:(long)expires;
|
|
24
|
-
- (instancetype) initWithDictionary:(NSDictionary*)data;
|
|
25
|
-
|
|
26
|
-
-(NSDictionary*) toDictionary;
|
|
27
|
-
|
|
28
|
-
@end
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
Binary file
|
|
@@ -1,525 +0,0 @@
|
|
|
1
|
-
// Copright (C) 1999-2021, Bernd Gaertner
|
|
2
|
-
// November 12, 2021
|
|
3
|
-
//
|
|
4
|
-
// This program is free software: you can redistribute it and/or modify
|
|
5
|
-
// it under the terms of the GNU General Public License as published by
|
|
6
|
-
// the Free Software Foundation, either version 3 of the License, or
|
|
7
|
-
// (at your option) any later version.
|
|
8
|
-
|
|
9
|
-
// This program is distributed in the hope that it will be useful,
|
|
10
|
-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
11
|
-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
12
|
-
// GNU General Public License for more details.
|
|
13
|
-
|
|
14
|
-
// You should have received a copy of the GNU General Public License
|
|
15
|
-
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
16
|
-
//
|
|
17
|
-
// Contact:
|
|
18
|
-
// --------
|
|
19
|
-
// Bernd Gaertner
|
|
20
|
-
// Institute of Theoretical Computer Science
|
|
21
|
-
// ETH Zuerich
|
|
22
|
-
// CAB G31.1
|
|
23
|
-
// CH-8092 Zuerich, Switzerland
|
|
24
|
-
// http://www.inf.ethz.ch/personal/gaertner
|
|
25
|
-
|
|
26
|
-
#include <cassert>
|
|
27
|
-
#include <algorithm>
|
|
28
|
-
#include <list>
|
|
29
|
-
#include <ctime>
|
|
30
|
-
#include <limits>
|
|
31
|
-
|
|
32
|
-
namespace Miniball {
|
|
33
|
-
|
|
34
|
-
// Global Functions
|
|
35
|
-
// ================
|
|
36
|
-
template <typename NT>
|
|
37
|
-
inline NT mb_sqr (NT r) {return r*r;}
|
|
38
|
-
|
|
39
|
-
// Functors
|
|
40
|
-
// ========
|
|
41
|
-
|
|
42
|
-
// functor to map a point iterator to the corresponding coordinate iterator;
|
|
43
|
-
// generic version for points whose coordinate containers have begin()
|
|
44
|
-
template < typename Pit_, typename Cit_ >
|
|
45
|
-
struct CoordAccessor {
|
|
46
|
-
typedef Pit_ Pit;
|
|
47
|
-
typedef Cit_ Cit;
|
|
48
|
-
inline Cit operator() (Pit it) const { return (*it).begin(); }
|
|
49
|
-
};
|
|
50
|
-
|
|
51
|
-
// partial specialization for points whose coordinate containers are arrays
|
|
52
|
-
template < typename Pit_, typename Cit_ >
|
|
53
|
-
struct CoordAccessor<Pit_, Cit_*> {
|
|
54
|
-
typedef Pit_ Pit;
|
|
55
|
-
typedef Cit_* Cit;
|
|
56
|
-
inline Cit operator() (Pit it) const { return *it; }
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
// Class Declaration
|
|
60
|
-
// =================
|
|
61
|
-
|
|
62
|
-
template <typename CoordAccessor>
|
|
63
|
-
class Miniball {
|
|
64
|
-
private:
|
|
65
|
-
// types
|
|
66
|
-
// The iterator type to go through the input points
|
|
67
|
-
typedef typename CoordAccessor::Pit Pit;
|
|
68
|
-
// The iterator type to go through the coordinates of a single point.
|
|
69
|
-
typedef typename CoordAccessor::Cit Cit;
|
|
70
|
-
// The coordinate type
|
|
71
|
-
typedef typename std::iterator_traits<Cit>::value_type NT;
|
|
72
|
-
// The iterator to go through the support points
|
|
73
|
-
typedef typename std::list<Pit>::iterator Sit;
|
|
74
|
-
|
|
75
|
-
// data members...
|
|
76
|
-
const int d; // dimension
|
|
77
|
-
Pit points_begin;
|
|
78
|
-
Pit points_end;
|
|
79
|
-
CoordAccessor coord_accessor;
|
|
80
|
-
double time;
|
|
81
|
-
const NT nt0; // NT(0)
|
|
82
|
-
|
|
83
|
-
//...for the algorithms
|
|
84
|
-
std::list<Pit> L;
|
|
85
|
-
Sit support_end;
|
|
86
|
-
int fsize; // number of forced points
|
|
87
|
-
int ssize; // number of support points
|
|
88
|
-
|
|
89
|
-
// ...for the ball updates
|
|
90
|
-
NT* current_c;
|
|
91
|
-
NT current_sqr_r;
|
|
92
|
-
NT** c;
|
|
93
|
-
NT* sqr_r;
|
|
94
|
-
|
|
95
|
-
// helper arrays
|
|
96
|
-
NT* q0;
|
|
97
|
-
NT* z;
|
|
98
|
-
NT* f;
|
|
99
|
-
NT** v;
|
|
100
|
-
NT** a;
|
|
101
|
-
|
|
102
|
-
// by how much do we allow points outside?
|
|
103
|
-
NT default_tol;
|
|
104
|
-
|
|
105
|
-
public:
|
|
106
|
-
// The iterator type to go through the support points
|
|
107
|
-
typedef typename std::list<Pit>::const_iterator SupportPointIterator;
|
|
108
|
-
|
|
109
|
-
// PRE: [begin, end) is a nonempty range
|
|
110
|
-
// POST: computes the smallest enclosing ball of the points in the range
|
|
111
|
-
// [begin, end); the functor a maps a point iterator to an iterator
|
|
112
|
-
// through the d coordinates of the point
|
|
113
|
-
Miniball (int d_, Pit begin, Pit end, CoordAccessor ca = CoordAccessor());
|
|
114
|
-
|
|
115
|
-
// POST: returns a pointer to the first element of an array that holds
|
|
116
|
-
// the d coordinates of the center of the computed ball
|
|
117
|
-
const NT* center () const;
|
|
118
|
-
|
|
119
|
-
// POST: returns the squared radius of the computed ball
|
|
120
|
-
NT squared_radius () const;
|
|
121
|
-
|
|
122
|
-
// POST: returns the number of support points of the computed ball;
|
|
123
|
-
// the support points form a minimal set with the same smallest
|
|
124
|
-
// enclosing ball as the input set; in particular, the support
|
|
125
|
-
// points are on the boundary of the computed ball, and their
|
|
126
|
-
// number is at most d+1
|
|
127
|
-
int nr_support_points () const;
|
|
128
|
-
|
|
129
|
-
// POST: returns an iterator to the first support point
|
|
130
|
-
SupportPointIterator support_points_begin () const;
|
|
131
|
-
|
|
132
|
-
// POST: returns a past-the-end iterator for the range of support points
|
|
133
|
-
SupportPointIterator support_points_end () const;
|
|
134
|
-
|
|
135
|
-
// POST: returns the maximum excess of any input point w.r.t. the computed
|
|
136
|
-
// ball, divided by the squared radius of the computed ball. The
|
|
137
|
-
// excess of a point is the difference between its squared distance
|
|
138
|
-
// from the center and the squared radius; Ideally, the return value
|
|
139
|
-
// is 0. subopt is set to the absolute value of the most negative
|
|
140
|
-
// coefficient in the affine combination of the support points that
|
|
141
|
-
// yields the center. Ideally, this is a convex combination, and there
|
|
142
|
-
// is no negative coefficient in which case subopt is set to 0.
|
|
143
|
-
NT relative_error (NT& subopt) const;
|
|
144
|
-
|
|
145
|
-
// POST: return true if the relative error is at most tol, and the
|
|
146
|
-
// suboptimality is 0; the default tolerance is 10 times the
|
|
147
|
-
// coordinate type's machine epsilon
|
|
148
|
-
bool is_valid () const;
|
|
149
|
-
|
|
150
|
-
// POST: returns the time in seconds taken by the constructor call for
|
|
151
|
-
// computing the smallest enclosing ball
|
|
152
|
-
double get_time() const;
|
|
153
|
-
|
|
154
|
-
// POST: deletes dynamically allocated arrays
|
|
155
|
-
~Miniball();
|
|
156
|
-
|
|
157
|
-
private:
|
|
158
|
-
void mtf_mb (Sit n);
|
|
159
|
-
void mtf_move_to_front (Sit j);
|
|
160
|
-
void pivot_mb (Pit n);
|
|
161
|
-
void pivot_move_to_front (Pit j);
|
|
162
|
-
NT excess (Pit pit) const;
|
|
163
|
-
void pop ();
|
|
164
|
-
bool push (Pit pit);
|
|
165
|
-
NT suboptimality () const;
|
|
166
|
-
void create_arrays();
|
|
167
|
-
void delete_arrays();
|
|
168
|
-
};
|
|
169
|
-
|
|
170
|
-
// Class Definition
|
|
171
|
-
// ================
|
|
172
|
-
template <typename CoordAccessor>
|
|
173
|
-
Miniball<CoordAccessor>::Miniball (int d_, Pit begin, Pit end,
|
|
174
|
-
CoordAccessor ca)
|
|
175
|
-
: d (d_),
|
|
176
|
-
points_begin (begin),
|
|
177
|
-
points_end (end),
|
|
178
|
-
coord_accessor (ca),
|
|
179
|
-
time (clock()),
|
|
180
|
-
nt0 (NT(0)),
|
|
181
|
-
L(),
|
|
182
|
-
support_end (L.begin()),
|
|
183
|
-
fsize(0),
|
|
184
|
-
ssize(0),
|
|
185
|
-
current_c (NULL),
|
|
186
|
-
current_sqr_r (NT(-1)),
|
|
187
|
-
c (NULL),
|
|
188
|
-
sqr_r (NULL),
|
|
189
|
-
q0 (NULL),
|
|
190
|
-
z (NULL),
|
|
191
|
-
f (NULL),
|
|
192
|
-
v (NULL),
|
|
193
|
-
a (NULL),
|
|
194
|
-
default_tol (NT(10) * std::numeric_limits<NT>::epsilon())
|
|
195
|
-
{
|
|
196
|
-
assert (points_begin != points_end);
|
|
197
|
-
create_arrays();
|
|
198
|
-
|
|
199
|
-
// set initial center
|
|
200
|
-
for (int j=0; j<d; ++j) c[0][j] = nt0;
|
|
201
|
-
current_c = c[0];
|
|
202
|
-
|
|
203
|
-
// compute miniball
|
|
204
|
-
pivot_mb (points_end);
|
|
205
|
-
|
|
206
|
-
// update time
|
|
207
|
-
time = (clock() - time) / CLOCKS_PER_SEC;
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
template <typename CoordAccessor>
|
|
211
|
-
Miniball<CoordAccessor>::~Miniball()
|
|
212
|
-
{
|
|
213
|
-
delete_arrays();
|
|
214
|
-
}
|
|
215
|
-
|
|
216
|
-
template <typename CoordAccessor>
|
|
217
|
-
void Miniball<CoordAccessor>::create_arrays()
|
|
218
|
-
{
|
|
219
|
-
c = new NT*[d+1];
|
|
220
|
-
v = new NT*[d+1];
|
|
221
|
-
a = new NT*[d+1];
|
|
222
|
-
for (int i=0; i<d+1; ++i) {
|
|
223
|
-
c[i] = new NT[d];
|
|
224
|
-
v[i] = new NT[d];
|
|
225
|
-
a[i] = new NT[d];
|
|
226
|
-
}
|
|
227
|
-
sqr_r = new NT[d+1];
|
|
228
|
-
q0 = new NT[d];
|
|
229
|
-
z = new NT[d+1];
|
|
230
|
-
f = new NT[d+1];
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
template <typename CoordAccessor>
|
|
234
|
-
void Miniball<CoordAccessor>::delete_arrays()
|
|
235
|
-
{
|
|
236
|
-
delete[] f;
|
|
237
|
-
delete[] z;
|
|
238
|
-
delete[] q0;
|
|
239
|
-
delete[] sqr_r;
|
|
240
|
-
for (int i=0; i<d+1; ++i) {
|
|
241
|
-
delete[] a[i];
|
|
242
|
-
delete[] v[i];
|
|
243
|
-
delete[] c[i];
|
|
244
|
-
}
|
|
245
|
-
delete[] a;
|
|
246
|
-
delete[] v;
|
|
247
|
-
delete[] c;
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
template <typename CoordAccessor>
|
|
251
|
-
const typename Miniball<CoordAccessor>::NT*
|
|
252
|
-
Miniball<CoordAccessor>::center () const
|
|
253
|
-
{
|
|
254
|
-
return current_c;
|
|
255
|
-
}
|
|
256
|
-
|
|
257
|
-
template <typename CoordAccessor>
|
|
258
|
-
typename Miniball<CoordAccessor>::NT
|
|
259
|
-
Miniball<CoordAccessor>::squared_radius () const
|
|
260
|
-
{
|
|
261
|
-
return current_sqr_r;
|
|
262
|
-
}
|
|
263
|
-
|
|
264
|
-
template <typename CoordAccessor>
|
|
265
|
-
int Miniball<CoordAccessor>::nr_support_points () const
|
|
266
|
-
{
|
|
267
|
-
assert (ssize < d+2);
|
|
268
|
-
return ssize;
|
|
269
|
-
}
|
|
270
|
-
|
|
271
|
-
template <typename CoordAccessor>
|
|
272
|
-
typename Miniball<CoordAccessor>::SupportPointIterator
|
|
273
|
-
Miniball<CoordAccessor>::support_points_begin () const
|
|
274
|
-
{
|
|
275
|
-
return L.begin();
|
|
276
|
-
}
|
|
277
|
-
|
|
278
|
-
template <typename CoordAccessor>
|
|
279
|
-
typename Miniball<CoordAccessor>::SupportPointIterator
|
|
280
|
-
Miniball<CoordAccessor>::support_points_end () const
|
|
281
|
-
{
|
|
282
|
-
return support_end;
|
|
283
|
-
}
|
|
284
|
-
|
|
285
|
-
template <typename CoordAccessor>
|
|
286
|
-
typename Miniball<CoordAccessor>::NT
|
|
287
|
-
Miniball<CoordAccessor>::relative_error (NT& subopt) const
|
|
288
|
-
{
|
|
289
|
-
NT e, max_e = nt0;
|
|
290
|
-
// compute maximum absolute excess of support points
|
|
291
|
-
for (SupportPointIterator it = support_points_begin();
|
|
292
|
-
it != support_points_end(); ++it) {
|
|
293
|
-
e = excess (*it);
|
|
294
|
-
if (e < nt0) e = -e;
|
|
295
|
-
if (e > max_e) {
|
|
296
|
-
max_e = e;
|
|
297
|
-
}
|
|
298
|
-
}
|
|
299
|
-
// compute maximum excess of any point
|
|
300
|
-
for (Pit i = points_begin; i != points_end; ++i)
|
|
301
|
-
if ((e = excess (i)) > max_e)
|
|
302
|
-
max_e = e;
|
|
303
|
-
|
|
304
|
-
subopt = suboptimality();
|
|
305
|
-
assert (current_sqr_r > nt0 || max_e == nt0);
|
|
306
|
-
return (current_sqr_r == nt0 ? nt0 : max_e / current_sqr_r);
|
|
307
|
-
}
|
|
308
|
-
|
|
309
|
-
template <typename CoordAccessor>
|
|
310
|
-
bool Miniball<CoordAccessor>::is_valid () const
|
|
311
|
-
{
|
|
312
|
-
NT suboptimality;
|
|
313
|
-
return ( (relative_error (suboptimality) <= default_tol) && (suboptimality == 0) );
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
template <typename CoordAccessor>
|
|
317
|
-
double Miniball<CoordAccessor>::get_time() const
|
|
318
|
-
{
|
|
319
|
-
return time;
|
|
320
|
-
}
|
|
321
|
-
|
|
322
|
-
template <typename CoordAccessor>
|
|
323
|
-
void Miniball<CoordAccessor>::mtf_mb (Sit n)
|
|
324
|
-
{
|
|
325
|
-
// Algorithm 1: mtf_mb (L_{n-1}, B), where L_{n-1} = [L.begin, n)
|
|
326
|
-
// B: the set of forced points, defining the current ball
|
|
327
|
-
// S: the superset of support points computed by the algorithm
|
|
328
|
-
// --------------------------------------------------------------
|
|
329
|
-
// from B. Gaertner, Fast and Robust Smallest Enclosing Balls, ESA 1999,
|
|
330
|
-
// http://www.inf.ethz.ch/personal/gaertner/texts/own_work/esa99_final.pdf
|
|
331
|
-
|
|
332
|
-
// PRE: B = S
|
|
333
|
-
assert (fsize == ssize);
|
|
334
|
-
|
|
335
|
-
support_end = L.begin();
|
|
336
|
-
if ((fsize) == d+1) return;
|
|
337
|
-
|
|
338
|
-
// incremental construction
|
|
339
|
-
for (Sit i = L.begin(); i != n;)
|
|
340
|
-
{
|
|
341
|
-
// INV: (support_end - L.begin() == |S|-|B|)
|
|
342
|
-
assert (std::distance (L.begin(), support_end) == ssize - fsize);
|
|
343
|
-
|
|
344
|
-
Sit j = i++;
|
|
345
|
-
if (excess(*j) > nt0)
|
|
346
|
-
if (push(*j)) { // B := B + p_i
|
|
347
|
-
mtf_mb (j); // mtf_mb (L_{i-1}, B + p_i)
|
|
348
|
-
pop(); // B := B - p_i
|
|
349
|
-
mtf_move_to_front(j);
|
|
350
|
-
}
|
|
351
|
-
}
|
|
352
|
-
// POST: the range [L.begin(), support_end) stores the set S\B
|
|
353
|
-
}
|
|
354
|
-
|
|
355
|
-
template <typename CoordAccessor>
|
|
356
|
-
void Miniball<CoordAccessor>::mtf_move_to_front (Sit j)
|
|
357
|
-
{
|
|
358
|
-
if (support_end == j)
|
|
359
|
-
support_end++;
|
|
360
|
-
L.splice (L.begin(), L, j);
|
|
361
|
-
}
|
|
362
|
-
|
|
363
|
-
template <typename CoordAccessor>
|
|
364
|
-
void Miniball<CoordAccessor>::pivot_mb (Pit n)
|
|
365
|
-
{
|
|
366
|
-
// Algorithm 2: pivot_mb (L_{n-1}), where L_{n-1} = [L.begin, n)
|
|
367
|
-
// --------------------------------------------------------------
|
|
368
|
-
// from B. Gaertner, Fast and Robust Smallest Enclosing Balls, ESA 1999,
|
|
369
|
-
// http://www.inf.ethz.ch/personal/gaertner/texts/own_work/esa99_final.pdf
|
|
370
|
-
const NT* c;
|
|
371
|
-
Pit pivot, k;
|
|
372
|
-
NT e, max_e, sqr_r;
|
|
373
|
-
Cit p;
|
|
374
|
-
unsigned int loops_without_progress = 0;
|
|
375
|
-
NT best_sqr_r = current_sqr_r;
|
|
376
|
-
do {
|
|
377
|
-
sqr_r = current_sqr_r;
|
|
378
|
-
|
|
379
|
-
pivot = points_begin;
|
|
380
|
-
max_e = nt0;
|
|
381
|
-
for (k = points_begin; k != n; ++k) {
|
|
382
|
-
p = coord_accessor(k);
|
|
383
|
-
e = -sqr_r;
|
|
384
|
-
c = current_c;
|
|
385
|
-
for (int j=0; j<d; ++j)
|
|
386
|
-
e += mb_sqr<NT>(*p++-*c++);
|
|
387
|
-
if (e > max_e) {
|
|
388
|
-
max_e = e;
|
|
389
|
-
pivot = k;
|
|
390
|
-
}
|
|
391
|
-
}
|
|
392
|
-
|
|
393
|
-
if (sqr_r < nt0 || max_e > nt0) {
|
|
394
|
-
// check if the pivot is already contained in the support set
|
|
395
|
-
if (std::find(L.begin(), support_end, pivot) == support_end) {
|
|
396
|
-
assert (fsize == 0);
|
|
397
|
-
if (push (pivot)) {
|
|
398
|
-
mtf_mb(support_end);
|
|
399
|
-
pop();
|
|
400
|
-
pivot_move_to_front(pivot);
|
|
401
|
-
}
|
|
402
|
-
}
|
|
403
|
-
}
|
|
404
|
-
if (best_sqr_r < current_sqr_r) {
|
|
405
|
-
best_sqr_r = current_sqr_r;
|
|
406
|
-
loops_without_progress = 0;
|
|
407
|
-
}
|
|
408
|
-
else
|
|
409
|
-
++loops_without_progress;
|
|
410
|
-
} while (loops_without_progress < 2);
|
|
411
|
-
}
|
|
412
|
-
|
|
413
|
-
template <typename CoordAccessor>
|
|
414
|
-
void Miniball<CoordAccessor>::pivot_move_to_front (Pit j)
|
|
415
|
-
{
|
|
416
|
-
L.push_front(j);
|
|
417
|
-
if (std::distance(L.begin(), support_end) == d+2)
|
|
418
|
-
support_end--;
|
|
419
|
-
}
|
|
420
|
-
|
|
421
|
-
template <typename CoordAccessor>
|
|
422
|
-
inline typename Miniball<CoordAccessor>::NT
|
|
423
|
-
Miniball<CoordAccessor>::excess (Pit pit) const
|
|
424
|
-
{
|
|
425
|
-
Cit p = coord_accessor(pit);
|
|
426
|
-
NT e = -current_sqr_r;
|
|
427
|
-
NT* c = current_c;
|
|
428
|
-
for (int k=0; k<d; ++k){
|
|
429
|
-
e += mb_sqr<NT>(*p++-*c++);
|
|
430
|
-
}
|
|
431
|
-
return e;
|
|
432
|
-
}
|
|
433
|
-
|
|
434
|
-
template <typename CoordAccessor>
|
|
435
|
-
void Miniball<CoordAccessor>::pop ()
|
|
436
|
-
{
|
|
437
|
-
--fsize;
|
|
438
|
-
}
|
|
439
|
-
|
|
440
|
-
template <typename CoordAccessor>
|
|
441
|
-
bool Miniball<CoordAccessor>::push (Pit pit)
|
|
442
|
-
{
|
|
443
|
-
int i, j;
|
|
444
|
-
NT eps = mb_sqr<NT>(std::numeric_limits<NT>::epsilon());
|
|
445
|
-
|
|
446
|
-
Cit cit = coord_accessor(pit);
|
|
447
|
-
Cit p = cit;
|
|
448
|
-
|
|
449
|
-
if (fsize==0) {
|
|
450
|
-
for (i=0; i<d; ++i)
|
|
451
|
-
q0[i] = *p++;
|
|
452
|
-
for (i=0; i<d; ++i)
|
|
453
|
-
c[0][i] = q0[i];
|
|
454
|
-
sqr_r[0] = nt0;
|
|
455
|
-
}
|
|
456
|
-
else {
|
|
457
|
-
// set v_fsize to Q_fsize
|
|
458
|
-
for (i=0; i<d; ++i)
|
|
459
|
-
//v[fsize][i] = p[i]-q0[i];
|
|
460
|
-
v[fsize][i] = *p++-q0[i];
|
|
461
|
-
|
|
462
|
-
// compute the a_{fsize,i}, i< fsize
|
|
463
|
-
for (i=1; i<fsize; ++i) {
|
|
464
|
-
a[fsize][i] = nt0;
|
|
465
|
-
for (j=0; j<d; ++j)
|
|
466
|
-
a[fsize][i] += v[i][j] * v[fsize][j];
|
|
467
|
-
a[fsize][i]*=(2/z[i]);
|
|
468
|
-
}
|
|
469
|
-
|
|
470
|
-
// update v_fsize to Q_fsize-\bar{Q}_fsize
|
|
471
|
-
for (i=1; i<fsize; ++i) {
|
|
472
|
-
for (j=0; j<d; ++j)
|
|
473
|
-
v[fsize][j] -= a[fsize][i]*v[i][j];
|
|
474
|
-
}
|
|
475
|
-
|
|
476
|
-
// compute z_fsize
|
|
477
|
-
z[fsize]=nt0;
|
|
478
|
-
for (j=0; j<d; ++j)
|
|
479
|
-
z[fsize] += mb_sqr<NT>(v[fsize][j]);
|
|
480
|
-
z[fsize]*=2;
|
|
481
|
-
|
|
482
|
-
// reject push if z_fsize too small
|
|
483
|
-
if (z[fsize]<eps*current_sqr_r) {
|
|
484
|
-
return false;
|
|
485
|
-
}
|
|
486
|
-
|
|
487
|
-
// update c, sqr_r
|
|
488
|
-
p=cit;
|
|
489
|
-
NT e = -sqr_r[fsize-1];
|
|
490
|
-
for (i=0; i<d; ++i)
|
|
491
|
-
e += mb_sqr<NT>(*p++-c[fsize-1][i]);
|
|
492
|
-
f[fsize]=e/z[fsize];
|
|
493
|
-
|
|
494
|
-
for (i=0; i<d; ++i)
|
|
495
|
-
c[fsize][i] = c[fsize-1][i]+f[fsize]*v[fsize][i];
|
|
496
|
-
sqr_r[fsize] = sqr_r[fsize-1] + e*f[fsize]/2;
|
|
497
|
-
}
|
|
498
|
-
current_c = c[fsize];
|
|
499
|
-
current_sqr_r = sqr_r[fsize];
|
|
500
|
-
ssize = ++fsize;
|
|
501
|
-
return true;
|
|
502
|
-
}
|
|
503
|
-
|
|
504
|
-
template <typename CoordAccessor>
|
|
505
|
-
typename Miniball<CoordAccessor>::NT
|
|
506
|
-
Miniball<CoordAccessor>::suboptimality () const
|
|
507
|
-
{
|
|
508
|
-
NT* l = new NT[d+1];
|
|
509
|
-
NT min_l = nt0;
|
|
510
|
-
l[0] = NT(1);
|
|
511
|
-
for (int i=ssize-1; i>0; --i) {
|
|
512
|
-
l[i] = f[i];
|
|
513
|
-
for (int k=ssize-1; k>i; --k)
|
|
514
|
-
l[i]-=a[k][i]*l[k];
|
|
515
|
-
if (l[i] < min_l) min_l = l[i];
|
|
516
|
-
l[0] -= l[i];
|
|
517
|
-
}
|
|
518
|
-
if (l[0] < min_l) min_l = l[0];
|
|
519
|
-
delete[] l;
|
|
520
|
-
if (min_l < nt0)
|
|
521
|
-
return -min_l;
|
|
522
|
-
return nt0;
|
|
523
|
-
}
|
|
524
|
-
|
|
525
|
-
} // end Namespace Miniball
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
3
|
-
<!--
|
|
4
|
-
PrivacyInfo.xcprivacy
|
|
5
|
-
TSLocationManager
|
|
6
|
-
|
|
7
|
-
Created by Christopher Scott on 2024-03-20.
|
|
8
|
-
Copyright (c) 2024 Christopher Scott. All rights reserved.
|
|
9
|
-
-->
|
|
10
|
-
<plist version="1.0">
|
|
11
|
-
<dict>
|
|
12
|
-
<key>NSPrivacyTrackingDomains</key>
|
|
13
|
-
<array/>
|
|
14
|
-
|
|
15
|
-
<key>NSPrivacyAccessedAPITypes</key>
|
|
16
|
-
<array>
|
|
17
|
-
<dict>
|
|
18
|
-
<key>NSPrivacyAccessedAPIType</key>
|
|
19
|
-
<string>NSPrivacyAccessedAPICategoryUserDefaults</string>
|
|
20
|
-
|
|
21
|
-
<key>NSPrivacyAccessedAPITypeReasons</key>
|
|
22
|
-
<array>
|
|
23
|
-
<string>CA92.1</string>
|
|
24
|
-
<string>1C8F.1</string>
|
|
25
|
-
</array>
|
|
26
|
-
</dict>
|
|
27
|
-
</array>
|
|
28
|
-
|
|
29
|
-
<key>NSPrivacyCollectedDataTypes</key>
|
|
30
|
-
<array/>
|
|
31
|
-
|
|
32
|
-
<key>NSPrivacyTracking</key>
|
|
33
|
-
<false/>
|
|
34
|
-
</dict>
|
|
35
|
-
</plist>
|
|
36
|
-
|
package/ios/TSLocationManager.xcframework/ios-arm64/TSLocationManager.framework/TSLocationManager
DELETED
|
Binary file
|
|
Binary file
|
|
Binary file
|