LocationData class

Represents location data with coordinates and metadata

Constructors

LocationData({required double latitude, required double longitude, required double accuracy, double? altitude, double? speed, double? speedAccuracy, double? heading, required DateTime timestamp, bool isMocked = false})
LocationData.fromJson(Map<String, dynamic> json)
Create from JSON
factory

Properties

accuracy → double
Accuracy in meters
final
altitude → double?
Altitude in meters
final
hashCode → int
The hash code for this object.
no setteroverride
heading → double?
Heading in degrees
final
isMocked → bool
Whether the location is mocked
final
latitude → double
Latitude in degrees
final
longitude → double
Longitude in degrees
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
speed → double?
Speed in meters per second
final
speedAccuracy → double?
Speed accuracy in meters per second
final
timestamp → DateTime
Timestamp when the location was captured
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, dynamic>
Convert to JSON
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
override