Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is getSimCountryIso returning 3 letters or 2 letters ISO code

Tags:

android

I was wondering, is getSimCountryIso returning 2 letters or 3 letters ISO code? As this is not being mentioned in the documentation. I tested with my Nexus phone, it is returning 2 letters. However, I'm not sure this is true for other phones.

like image 464
Cheok Yan Cheng Avatar asked May 19 '13 07:05

Cheok Yan Cheng


1 Answers

It returns whatever the OEM has configured for the gsm.sim.operator.iso-country property, which in my experience is a 2-character code. The codes I have seen match the Alpha-2 code from ISO 3166-1 (http://en.wikipedia.org/wiki/ISO_3166-1). This is based on my observation as I was unable to find this in any official documentation.

like image 197
Jim Vitek Avatar answered Oct 20 '22 04:10

Jim Vitek