DistanceHaversine class

Shortcut for final Distance distance = const Distance(calculator: const Haversine());

Inheritance

Constructors

DistanceHaversine({bool roundResult = true})
const
DistanceHaversine.withRadius(double radius, {bool roundResult = true})
Radius must be greater than 0.

Properties

calculator DistanceCalculator
Returns either Haversine oder Vincenty calculator
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
radius double
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

as(LengthUnit unit, LatLng p1, LatLng p2) double
Converts the distance to the given LengthUnit
inherited
bearing(LatLng p1, LatLng p2) double
Returns the great circle bearing (direction) in degrees to the next point (p2)
inherited
call(LatLng p1, LatLng p2) double
Shortcut for distance
inherited
distance(LatLng p1, LatLng p2) double
Computes the distance between two points.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
offset(LatLng from, num distanceInMeter, num bearing) LatLng
Returns a destination point based on the given distance and bearing
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited