經過大量研究後我很喜歡LAC可以用於基於位置的應用程序來查找Location.i有幾個關於LAC1的問題我可以從中獲得哪些信息LAC? 2)我如何找到使用LAC的位置名稱? 3)是否有任何網站或數據庫知道我的位置LAC?
我不需要的代碼,我需要這些問題的答案,普萊舍幫助我如何獲得使用LAC的位置名稱
2
A
回答
1
這裏是讓小區發射塔信息代碼:
public static void getCellTowerInfo() {
TelephonyManager mTelephonyManager = (TelephonyManager) POContext.getContext().getSystemService(Context.TELEPHONY_SERVICE);
GsmCellLocation location = (GsmCellLocation) mTelephonyManager.getCellLocation();
if (location != null) {
// cell id of the
POGlobals.PhoneInfo.CellID = String.valueOf(location.getCid());
Log.i(POGlobals.TAG, "CellID of the Device-->" + POGlobals.PhoneInfo.CellID);
// get theLAC
POGlobals.PhoneInfo.LAC = String.valueOf(location.getLac());
Log.i(POGlobals.TAG, "LAC of the Device-->" + POGlobals.PhoneInfo.LAC);
}
if (mTelephonyManager != null) {
// get the combination of MNC+MCC for the GSM Networks only
if (mTelephonyManager.getNetworkOperator() != null && mTelephonyManager.getNetworkOperator().length() > 0) {
POGlobals.PhoneInfo.MCC = mTelephonyManager.getNetworkOperator().substring(0, 3);
POGlobals.PhoneInfo.MNC = mTelephonyManager.getNetworkOperator().substring(3);
mTelephonyManager.getNetworkType();
} else {
// Phone is in Airplane Mode situation
Logger.e(POGlobals.TAG, "TelephonyManager service is NULL");
}
}
}
請刪除記錄器的編譯錯誤和全局變量。
LAC是服務提供商提供的位置區域代碼,取決於您最近的塔樓。
1
您可以使用OpenCellID's API來獲取使用MCC,MNC,LAC和CellID的位置。
相關問題
- 1. 如何在Android中使用cell id和lac知道單元格位置名稱?
- 2. 如何獲取用戶位置名稱?
- 3. 如何在iphone中使用mapkit獲取位置名稱?
- 4. 如何獲得SearchResultEntry的用戶名稱
- 5. 獲取從獲取的座標位置名稱得到
- 6. 我如何獲取PDO以獲得第一個數組位置的列名稱?
- 7. 這裏地圖3.3。如何獲得當前用戶的位置街道名稱?
- 8. 如何獲得任何電話號碼的LAC和CID
- 9. JQuery使用名稱獲得textarea的值
- 10. 如何獲得谷歌地圖在地圖中心的位置(LatLng /名稱)
- 11. 如何獲得boost :: interprocess :: managed_shared_memory的名稱
- 12. 如何獲得網頁名稱的wordpress
- 13. 如何獲得有條件的名稱?
- 14. 如何獲得網格的x:名稱?
- 15. 如何獲得IAction的菜單名稱?
- 16. 我如何獲得Ruby類的名稱?
- 17. 如何獲得RavenDB文件的名稱
- 18. 如何獲得類的名稱
- 19. 如何獲得SPServer的機器名稱?
- 20. 如何獲得執行.exe的名稱?
- 21. 如何獲得裝配的強名稱?
- 22. 如何獲得約束的名稱?
- 23. 如何獲得使用該方法的類的名稱
- 24. 如何獲得使用相同名稱的ID的計數
- 25. 如何獲得Handlebars中名稱/值對的名稱?
- 26. 獲取當前位置使用網絡提供商的名稱
- 27. 如何獲得在UIImage中使用的圖像名稱?
- 28. 通過python使用硒如何獲得按鈕的名稱?
- 29. 如何使用C#中的Skype4COM API獲得重點組名稱
- 30. 如何獲得使用Linq to SQL的列名稱列表
謝謝you.but我怎麼能匹配這個位置名稱 – sajith
這個LAC會返回你的整數代碼。如果您想比較字符串的實際位置,則需要對緯度和經度進行反向地理編碼。所以你會得到的位置,直到steet名稱。 –