Why is getNetworkOperator not reliable for CDMA?

僤鯓⒐⒋嵵緔 提交于 2019-12-07 07:05:38

问题


Can anyone say why the documentation for the getNetworkOperator function of TelephonyManager states that this can return unreliable result for CDMA ?

getNetworkOperator documentation

Availability: Only when user is registered to a network. Result may be unreliable on CDMA networks (use getPhoneType() to determine if on a CDMA network).

What kind of results are you getting when calling this method on a CDMA device ? and if it's not reliable, How can I get the MCC for a CDMA device ?


回答1:


I know this is an old question, but maybe is useful to other people.

I don't know what returns from some CDMA networks, but i believe will be a "null" for sure.

You can get the MCC from getSimOperator().

Hope this helps.




回答2:


It is unreliable because it can be kind-of spoofed on cdma networks. You can get actual operator names like Verizon Wireless but you may also get strings like HOME, CRICKET, SCHOOL etc.



来源:https://stackoverflow.com/questions/8006403/why-is-getnetworkoperator-not-reliable-for-cdma

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!