Coordinates class
- Inheritance
-
- Object
- Jsonable<
Coordinates> - Coordinates
Constructors
- Coordinates({double? latitude, double? longitude})
-
Coordinates.fromJson(Map<
String, dynamic> json) -
factory
- Coordinates.fromLocation(Location location)
-
factory
Properties
- asLocation → Location
-
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- isEmpty → bool
-
no setter
- isNotEmpty → bool
-
no setter
- latitude ↔ double
-
getter/setter pair
- longitude ↔ double
-
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
distanceTo(
{double? latitude, double? longitude, Coordinates? coordinates}) → double - Using Haversine formula
-
fastDistanceTo(
{double? latitude, double? longitude, Coordinates? coordinates}) → double - Using Euclidean formula
-
fromJsonList(
List? jsonList) → List< Coordinates> ? -
inherited
-
fromJsonMap(
Map< String, dynamic> ? json) → Coordinates? -
override
-
fromJsonString(
String? json) → Coordinates? -
inherited
-
fromJsonStringList(
String? jsonStringList) → List< Coordinates> ? -
inherited
-
isDifferentThan(
Coordinates? location) → bool -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
override
-
toJsonMap(
) → Map< String, dynamic> -
inherited
-
toJsonString(
) → String -
inherited
-
toString(
) → String -
This is just to suggest children to implement a named constructor to
support creating objects fromJson(...) and fromJsonString(...) as easy as
T.build().fromJson(...) or T.build().fromJsonString(...)
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited