SphericalGreatCircle class
Latitude/longitude points on a spherical model earth, and methods for calculating distances, bearings, destinations, etc on (orthodromic) great-circle paths.
- Annotations
-
- @immutable
Constructors
- SphericalGreatCircle(Geographic position)
-
Create an object calculating distances, bearings, destinations, etc on
(orthodromic) great-circle paths with
positionas the current position.const
Properties
- hashCode → int
-
The hash code for this object.
no setteroverride
- position → Geographic
-
The current geographic position for calculations.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
alongTrackDistanceTo(
{required Geographic start, required Geographic end, double radius = 6371000.0}) → double -
Returns how far the current
positionis along a path from thestartpoint, heading towards theendpoint. -
copyWith(
{Geographic? position}) → SphericalGreatCircle -
Copy this geodetic object with an optional
positionchanged. -
crossingParallels(
{required Geographic other, required double latitude}) → List< double> ? -
Returns the pair of meridians at which a great circle defined by two
points (the current
positionandotherposition) crosses the givenlatitude. -
crossTrackDistanceTo(
{required Geographic start, required Geographic end, double radius = 6371000.0}) → double -
Returns (signed) distance from the current
positionto great circle defined bystartandendpoints. -
destinationPoint(
{required double distance, required double bearing, double radius = 6371000.0}) → Geographic -
Returns the destination point from the current
positionhaving travelled the givendistanceon the given initialbearing(bearing normally varies around path followed). -
distanceTo(
Geographic destination, {double radius = 6371000.0}) → double -
Returns the distance along the surface of the earth from the current
positiontodestination. -
finalBearingTo(
Geographic destination) → double -
Returns the final bearing arriving at
destinationfrom the currentposition. -
initialBearingTo(
Geographic destination) → double -
Returns the initial bearing from the current
positiontodestination. -
intermediatePointTo(
Geographic destination, {required double fraction}) → Geographic -
Returns the intermediate point at the given fraction between the current
positionanddestination. -
intersectionWith(
{required double bearing, required Geographic other, required double otherBearing}) → Geographic? - Returns the point of intersection of two paths both defined by a position and a bearing.
-
maxLatitude(
{required double bearing}) → double -
Returns the maximum latitude reached when travelling on a great circle on
the given
bearingfrom the currentposition. -
midPointTo(
Geographic destination) → Geographic -
Returns the midpoint between the current
positionanddestination. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override