Package world.mappable.mapkit.location
Class Location
java.lang.Object
↳ world.mappable.mapkit.location.Location
class Location implements Serializable
The geographical position of the object.
Summary
Constructors
Signature and Description |
Location(@NonNull Point position, |
Location() |
Methods
Type and modifiers |
Method and Description |
getPosition() |
|
java.lang.Double |
getAccuracy() |
java.lang.Double |
getAltitude() |
java.lang.Double |
getAltitudeAccuracy() |
java.lang.Double |
getHeading() |
java.lang.Double |
getSpeed() |
long |
getAbsoluteTimestamp() |
long |
getRelativeTimestamp() |
void |
serialize(world.mappable.runtime.bindings.Archive archive) |
Constuctors
Location
Location(@NonNull Point position, |
Location
Location() |
Use constructor with parameters in your code.
This one is for bindings only!
Methods
getPosition
@NonNull |
The geographical position.
getAccuracy
@Nullable |
Location accuracy in meters.
Optional field, can be null.
getAltitude
@Nullable |
The altitude of the location in meters.
Optional field, can be null.
getAltitudeAccuracy
@Nullable |
The accuracy of the altitude in meters.
Optional field, can be null.
getHeading
@Nullable |
The current heading in degrees relative to true north, clockwise.
Optional field, can be null.
getSpeed
@Nullable |
The speed in meters per second.
Optional field, can be null.
getAbsoluteTimestamp
long getAbsoluteTimestamp() |
Absolute timestamp, in milliseconds since January 1, 1970.
getRelativeTimestamp
long getRelativeTimestamp() |
Relative timestamp, number of milliseconds passed on steady clock.
Use for interval calculation.
serialize
@Override |