Changeset View
Changeset View
Standalone View
Standalone View
src/it/reyboz/bustorino/util/LocationCriteria.java
Show All 11 Lines | BusTO (util) | ||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||||
GNU General Public License for more details. | GNU General Public License for more details. | ||||
You should have received a copy of the GNU General Public License | You should have received a copy of the GNU General Public License | ||||
along with this program. If not, see <http://www.gnu.org/licenses/>. | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||||
*/ | */ | ||||
package it.reyboz.bustorino.util; | package it.reyboz.bustorino.util; | ||||
import android.location.Criteria; | |||||
/** | /** | ||||
* Own Location Criteria, because it's fun | * Own Location Criteria, because it's fun | ||||
* | |||||
*/ | */ | ||||
public class LocationCriteria { | public class LocationCriteria extends Criteria { | ||||
private final float minAccuracy; | private final float minAccuracy; | ||||
private final int timeInterval; | private final int timeInterval; | ||||
/** | |||||
* Constructor | |||||
* @param minAccuracy in meters | |||||
* @param timeInterval in milliseconds | |||||
*/ | |||||
public LocationCriteria(float minAccuracy,int timeInterval){ | public LocationCriteria(float minAccuracy,int timeInterval){ | ||||
this.minAccuracy = minAccuracy; | this.minAccuracy = minAccuracy; | ||||
this.timeInterval = timeInterval; | this.timeInterval = timeInterval; | ||||
} | } | ||||
public float getMinAccuracy() { | public float getMinAccuracy() { | ||||
return minAccuracy; | return minAccuracy; | ||||
} | } | ||||
public int getTimeInterval() { | public int getTimeInterval() { | ||||
return timeInterval; | return timeInterval; | ||||
} | } | ||||
} | } |
Public contents are in Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) or GNU Free Documentation License (at your option) unless otherwise noted. · Contact / Register