public class Location extends Object
Modifier and Type | Field and Description |
---|---|
static int |
ALTITUDE_INDEX |
static int |
LATITUDE_INDEX |
static int |
LONGITUDE_INDEX |
Constructor and Description |
---|
Location(double latitude,
double longitude,
Double speed,
Double bearing,
Double altitude,
Double accuracy,
String recordedAt) |
Location(List<Double> coordinates,
String recordedAt) |
Modifier and Type | Method and Description |
---|---|
Double |
getAccuracy() |
Double |
getAltitude() |
Double |
getBearing() |
double |
getLatitude() |
double |
getLongitude() |
Date |
getRecordDate() |
String |
getRecordedAt() |
Double |
getSpeed() |
boolean |
isObsolete() |
String |
toString() |
Location |
updateBearing(Location lastKnownLocation) |
public static final int ALTITUDE_INDEX
public static final int LATITUDE_INDEX
public static final int LONGITUDE_INDEX
public Location(double latitude, double longitude, Double speed, Double bearing, Double altitude, Double accuracy, String recordedAt)
public Location(List<Double> coordinates, String recordedAt) throws IllegalArgumentException
IllegalArgumentException
public double getLatitude()
public double getLongitude()
public String getRecordedAt()
getRecordDate()
public Date getRecordDate()
getRecordedAt()
public Double getAltitude()
public Double getSpeed()
public Double getBearing()
public Double getAccuracy()
getAltitude()
}
usually have less precise accuracy.public boolean isObsolete()