static NSString *carrierPListSymLinkPath = @"/var/mobile/Library/Preferences/com.apple.carrier.plist";
static NSString *operatorPListSymLinkPath = @"/var/mobile/Library/Preferences/com.apple.operator.plist";
- (BOOL)isRoaming
{
NSFileManager *fm = [NSFileManager defaultManager];
NSError *error;
NSString *carrierPListPath = [fm destinationOfSymbolicLinkAtPath:carrierPListSymLinkPath error:&error];
NSString *operatorPListPath = [fm destinationOfSymbolicLinkAtPath:operatorPListSymLinkPath error:&error];
return ([operatorPListPath isEqualToString:carrierPListPath]);
}
这里我试图阅读carrier.plist和operator.plist。它工作正常。
现在我的问题是,苹果将接受此代码或不用于应用商店发布,我不知道。
任何人都可以帮助我吗?
感谢。