public final class MccTable extends Object
Constructor and Description |
---|
MccTable() |
Modifier and Type | Method and Description |
---|---|
static String |
countryCodeForMcc(int mcc)
Given a GSM Mobile Country Code, returns
an ISO two-character country code if available.
|
static String |
defaultLanguageForMcc(int mcc)
Given a GSM Mobile Country Code, returns
an ISO 2-3 character language code if available.
|
static String |
defaultTimeZoneForMcc(int mcc)
Returns a default time zone ID for the given MCC.
|
static Locale |
getLocaleFromMcc(Context context,
int mcc,
String simLanguage)
Get Locale based on the MCC of the SIM.
|
static int |
smallestDigitsMccForMnc(int mcc)
Given a GSM Mobile Country Code, returns
the smallest number of digits that M if available.
|
static void |
updateMccMncConfiguration(Context context,
String mccmnc,
boolean fromServiceState)
Updates MCC and MNC device configuration information for application retrieving
correct version of resources.
|
public static String defaultTimeZoneForMcc(int mcc)
mcc
- Mobile Country Codepublic static String countryCodeForMcc(int mcc)
public static String defaultLanguageForMcc(int mcc)
public static int smallestDigitsMccForMnc(int mcc)
public static void updateMccMncConfiguration(Context context, String mccmnc, boolean fromServiceState)
context
- Context to act on.mccmnc
- truncated imsi with just the MCC and MNC - MNC assumed to be from 4th to endfromServiceState
- true if coming from the radio service state, false if from SIMpublic static Locale getLocaleFromMcc(Context context, int mcc, String simLanguage)
context
- Context to act on.mcc
- Mobile Country Code of the SIM or SIM-like entity (build prop on CDMA)simLanguage
- (nullable) the language from the SIM records (if present).