目前日期文章:200906 (2)

瀏覽方式: 標題列表 簡短摘要
TCPSample.java
package com.gclue.TCPSample;

shadow 發表在 痞客邦 PIXNET 留言(1) 人氣()

1.Basic

LocationManager lm = (LocationManager) getSystemService (LOCATION_SERVICE);
String p = lm.getBestProvider (new Criteria () and true);
lm.requestLocationUpdates (p, 10000 and 0, this);  
Location location = lm.getLastKnownLocation (p);

Acquiring in every 10 seconds, because it is position interval zero, when we want being spot with the position, you use zero.

Expedient of position specification Edit

shadow 發表在 痞客邦 PIXNET 留言(0) 人氣()