首页 > 代码库 > iPhone判断运营商
iPhone判断运营商
- (NSString *)getCarrier { NSString *strCarrier = nil; CTTelephonyNetworkInfo *networkInfo = [[CTTelephonyNetworkInfo alloc] init]; CTCarrier *carrier = [networkInfo subscriberCellularProvider]; if (carrier == nil) { [networkInfo release]; return strCarrier; } NSString *code = [carrier mobileNetworkCode]; if (code == nil) { [networkInfo release]; return strCarrier; } // 根据mobileNetworkCode判断运营商 if ([code isEqualToString:@"00"] || [code isEqualToString:@"02"] || [code isEqualToString:@"07"]) strCarrier = @"中国移动"; else if ([code isEqualToString:@"01"] || [code isEqualToString:@"06"]) strCarrier = @"中国联通"; else if ([code isEqualToString:@"03"] || [code isEqualToString:@"05"]) strCarrier = @"中国电信"; else if ([code isEqualToString:@"20"]) strCarrier = @"中国铁通"; else strCarrier = nil; [networkInfo release]; return strCarrier; }
China - CN
MCC | MNC | Brand | Operator | Status | Bands (MHz) | References and notes |
---|---|---|---|---|---|---|
460 | 00 | China Mobile | China Mobile | Operational | GSM 900 / GSM 1800 / TD-SCDMA 1880 / TD-SCDMA 2010 | |
460 | 01 | China Unicom | China Unicom | Operational | GSM 900 / GSM 1800 / UMTS 2100 | CDMA network sold to China Telecom, WCDMA commercial trial started in May 2009 and in full commercial operation as of October 2009. |
460 | 02 | China Mobile | China Mobile | Operational | GSM 900 / GSM 1800 / TD-SCDMA 1880 / TD-SCDMA 2010 | |
460 | 03 | China Telecom | China Telecom | Operational | CDMA2000 800 / CDMA2000 2100 | EV-DO |
460 | 05 | China Telecom | China Telecom | Operational | ||
460 | 06 | China Unicom | China Unicom | Operational | GSM 900 / GSM 1800 / UMTS 2100 | |
460 | 07 | China Mobile | China Mobile | Operational | GSM 900 / GSM 1800 / TD-SCDMA 1880 / TD-SCDMA 2010 | |
460 | 20 | China Tietong | China Tietong | Operational | GSM-R |
文章转自:http://blog.csdn.net/jiayou8809/article/details/8657974
详细参考:http://en.wikipedia.org/wiki/Mobile_Network_Code
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。