Projection class abstract
An abstract class that defines the interface for a map projection.
A projection is responsible for converting between geographical coordinates (latitude and longitude) and tile coordinates. This class also provides utility methods for distance calculations and other geo-related operations.
- Implementers
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
latitudeToTileY(
double latitude) → int - Converts a latitude coordinate to a tile Y number.
-
longitudeToTileX(
double longitude) → int - Converts a longitude coordinate to a tile X number.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
tileXToLongitude(
int tileX) → double - Converts a tile X number to a longitude coordinate.
-
tileYToLatitude(
int tileY) → double - ////////////////////////////////////////////////////////////////////////// Converts a tile Y number to a latitude coordinate.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- BOUNDINGBOX_MAX → BoundingBox
-
final
- EARTH_CIRCUMFERENCE → double
-
The circumference of the earth at the equator in meters.
final
- EQUATORIAL_RADIUS → double
-
The equatorial radius as defined by the WGS84
ellipsoid. WGS84 is the reference coordinate system used by the Global Positioning System.
final
- INVERSE_FLATTENING → double
-
The flattening factor of the earth's ellipsoid is required for distance computation.
final
- LATITUDE_MAX → double
-
Maximum possible latitude coordinate of the map.
final
- LATITUDE_MIN → double
-
Minimum possible latitude coordinate of the map.
final
- LONGITUDE_MAX → double
-
Polar radius in meter (WGS84 ellipsoid)
final
- LONGITUDE_MIN → double
-
final
- POLAR_RADIUS → double
-
Polar radius of earth is required for distance computation.
final
Static Methods
-
degToRadian(
double deg) → double - Converts an angle from degrees to radians.
-
destinationPoint(
ILatLong start, double distance, double bearing) → ILatLong - Calculates a destination point from a given starting point, distance, and bearing.
-
distance(
ILatLong p1, ILatLong p2) → double - Calculates the great-circle distance in meters between two points using the Haversine formula.
-
latitudeDistance(
int meters) → double - Calculates the latitude difference in degrees for a given distance in meters.
-
longitudeDistance(
int meters, double latitude) → double -
Calculates the longitude difference in degrees for a given distance in meters
at a specific
latitude. -
normalizeRotation(
double rotation) → double - Normalizes an angle to the range [0, 360).
-
offset(
ILatLong from, double distanceInMeter, double bearing) → ILatLong - Calculates a destination point from a given starting point, distance, and bearing.
-
radianToDeg(
double rad) → double - Converts an angle from radians to degrees.
-
startBearing(
ILatLong p1, ILatLong p2) → double -
Calculates the initial bearing in degrees from point
p1to pointp2. -
vincentyDistance(
ILatLong latLong1, ILatLong latLong2) → double - Calculates the geodetic distance in meters between two points using the Vincenty inverse formula for ellipsoids.