startRangingBeaconsSatisfyingConstraint 多个信标
startRangingBeaconsSatisfyingConstraint multiple beacons
当我对不同区域使用startRangingBeaconsInRegion
时didRangeBeacons inRegion
可以确定我设置的所有信标,但是当我对startRangingBeaconsSatisfyingConstraint
做同样的事情时didRangeBeacons satisfyingConstraint
可以确定只有最后一个。是苹果虫吗?
startRangingBeaconsInRegion
for (NSString *uuidString in uuidsString) {
NSUUID *uuid = [[NSUUID alloc] initWithUUIDString:uuidString];
CLBeaconRegion *region = [[CLBeaconRegion alloc] initWithUUID:uuid identifier:uuidString];
[_locationManager startRangingBeaconsInRegion:region];
}
startRangingBeaconsSatisfyingConstraint
for (NSString *uuidString in uuidsString) {
NSUUID *uuid = [[NSUUID alloc] initWithUUIDString:uuidString];
CLBeaconIdentityConstraint *beaconIdentityConstraint = [[CLBeaconIdentityConstraint alloc] initWithUUID:uuid];
[_locationManager startRangingBeaconsSatisfyingConstraint:beaconIdentityConstraint];
}
这似乎是新 startRangingBeaconsSatisfyingConstraint
API CoreLocation 中最近引入的错误。
目前的解决方法是使用已弃用的 startRangingBeaconsInRegion
API.
在此处查看相关 post:
SWIFT: CoreLocation - Ranging Beacons using CLBeaconIdentityConstraint does not range multiple beacons
Apple 论坛 post 报告错误:
当我对不同区域使用startRangingBeaconsInRegion
时didRangeBeacons inRegion
可以确定我设置的所有信标,但是当我对startRangingBeaconsSatisfyingConstraint
做同样的事情时didRangeBeacons satisfyingConstraint
可以确定只有最后一个。是苹果虫吗?
startRangingBeaconsInRegion
for (NSString *uuidString in uuidsString) {
NSUUID *uuid = [[NSUUID alloc] initWithUUIDString:uuidString];
CLBeaconRegion *region = [[CLBeaconRegion alloc] initWithUUID:uuid identifier:uuidString];
[_locationManager startRangingBeaconsInRegion:region];
}
startRangingBeaconsSatisfyingConstraint
for (NSString *uuidString in uuidsString) {
NSUUID *uuid = [[NSUUID alloc] initWithUUIDString:uuidString];
CLBeaconIdentityConstraint *beaconIdentityConstraint = [[CLBeaconIdentityConstraint alloc] initWithUUID:uuid];
[_locationManager startRangingBeaconsSatisfyingConstraint:beaconIdentityConstraint];
}
这似乎是新 startRangingBeaconsSatisfyingConstraint
API CoreLocation 中最近引入的错误。
目前的解决方法是使用已弃用的 startRangingBeaconsInRegion
API.
在此处查看相关 post:
SWIFT: CoreLocation - Ranging Beacons using CLBeaconIdentityConstraint does not range multiple beacons
Apple 论坛 post 报告错误: