如何获取诺基亚 E71 的手机 ID、MCC、LAC ?
我正在使用下面的代码,但找不到单元格,MCC,LAC值。
我尝试通过j2me代码找到这个值。
请帮我找到这个值
获取单元格 ID 的代码:
public static String getCellId() { 字符串输出 = "; 尝试 {
(out == null || out.equals("out = System.getProperty("Cell-ID"); // if (out == null || out.equals("null") || out.equals("")) { // out = System.getProperty("CellID"); // } // if
null") || out.equals(")) {//
System.getProperty("phone.cid");// }if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("com.nokia.mid.cellid"); } } catch (Exception e) { return out == null ? "" : out; } return out == null ? "" : out; }
获取 LAC 的代码:
public static String getLAC() { String out = ""; try { if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("com.nokia.mid.lac"); } } catch (Exception e) { return out == null ? "" : out; } return out == null ? "" : out; }
获取 IMSI 的代码:
public static String getIMSI() { String out = ""; try { out = System.getProperty("IMSI"); if (out == null || out.equals("null") || out.equals("")) { System.getProperty("phone.cid"); } if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("com.nokia.mid.mobinfo.IMSI"); } if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("com.nokia.mid.imsi"); } } catch (Exception e) { return out == null ? "" : out; } return out == null ? "" : out; }
获取 MCC 的代码:
public static String getMCC() { String out = ""; try { if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("phone.mcc"); } if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("com.nokia.mid.mobinfo.IMSI"); } if (out == null || out.equals("null") || out.equals("")) { out = getIMSI().equals("") ? "" : getIMSI().substring(0, 3); } if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("com.siemens.imei"); } if (out == null || out.equals("null") || out.equals(""))//getMNC() { if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("mcc"); } } } catch (Exception e) { return out == null ? "" : out; } return out == null ? "" : out; }
获得跨国公司的代码:
public static String getMNC() { String out = ""; try { if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("phone.mnc"); } if (out == null || out.equals("null") || out.equals("")) { out = getIMSI().equals("") ? "" : getIMSI().substring(3, 5); } if (out == null || out.equals("null") || out.equals("")) { out = getIMSI().equals("") ? "" : getIMSI().substring(3, 5); } if (out == null || out.equals("null") || out.equals(""))//getMNC() { if (out == null || out.equals("null") || out.equals("")) { out = System.getProperty("mnc"); } } } catch (Exception e) { return out == null ? "" : out; } return out == null ? "" : out; }
你是否使用我的代码
诺基亚而言,您需要让运营商对您的应用程序进行签名,以便您能够访问这些详细信息。