Location class - core library - Dart API
Location
Location class
Describes a location in the world at a given time.
Constructors
- Location.withCoordinates(GeoCoordinates coordinates)
-
Creates a new Location instance from the provided GeoCoordinates value.
timestamp is initialized with
January 1, 1970, 00:00:00 GMTvalue. The rest of the fields will be initialized to null.
Properties
- bearingAccuracyInDegrees ↔ double?
-
Estimated bearing accuracy for this location, in degrees.
If it cannot be determined, the value is
null.getter/setter pair - bearingInDegrees ↔ double?
-
Bearing (also known as course) is the device's horizontal direction of travel.
Starts at 0 in the geographical north and rotates around the compass in a clockwise
direction. This means for going north it is equal to 0, for northeast it is 45,
for east it is 90 and so on. Note that this may be different from the orientation of
the device. If it cannot be determined, the value is
null. Otherwise, it is guaranteed to be in the range [0, 360).getter/setter pair - coordinates ↔ GeoCoordinates
-
The geographic coordinates of the location.
getter/setter pair
- gnssTime ↔ Duration?
-
Optional gnss time at which the location was determined.
It is a time interval from the Unix time epoch in milliseconds.
If it cannot be determined, the value is
null.getter/setter pair - hashCode → int
-
The hash code for this object.
no setter
- horizontalAccuracyInMeters ↔ double?
-
The estimated horizontal accuracy. The actual location will lie within this radius of uncertainty.
getter/setter pair
- locationTechnology ↔ LocationTechnology?
-
Optional technology or provider of this location.
If it cannot be determined, the value is
null.getter/setter pair - pitchInDegrees ↔ double?
-
Pitch of this location, in degrees.
If it cannot be determined, the value is
null.getter/setter pair - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- source ↔ LocationSource?
-
Optional source of this location.
If it cannot be determined, the value is
null.getter/setter pair - speedAccuracyInMetersPerSecond ↔ double?
-
Estimated speed accuracy of this location, in meters per second.
If it cannot be determined, the value is
null.getter/setter pair - speedInMetersPerSecond ↔ double?
-
Current speed of the device. If it cannot be determined, the value is
null.getter/setter pair - time ↔ DateTime?
-
The time at which the location was determined.
getter/setter pair
- timestampSinceBoot ↔ Duration?
-
The time at which the location was determined, relative to device
boot time. This time is monotonic and not affected by leap time or other system
time adjustments, so this is the recommended basis for general purpose interval timing
between location updates.
If it cannot be determined, the value is
null.getter/setter pair - verticalAccuracyInMeters ↔ double?
-
Estimated vertical accuracy.
Given that the received Location contains the altitude, the real value of the altitude
is estimated to lie within the following range:
[altitude - vertical accuracy, altitude + vertical accuracy].
For example, when the altitude is equal to 50 and the vertical accuracy
is 8, then the actual value is most likely in the range [42, 58].
getter/setter pair
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool - The equality operator.