Click or drag to resize
LatLng Class
doogal.co.uk Home



Class to represent a latitude/longitude pair based on a particular datum.
Inheritance Hierarchy
SystemObject
  DotNetCoordsLatLng

Namespace:  DotNetCoords
Assembly:  DotNetCoords (in DotNetCoords.dll) Version: 1.0.0.22 (1.0.0.22)
Syntax
public sealed class LatLng

The LatLng type exposes the following members.

Constructors
  NameDescription
Public methodLatLng(LatLng)
Initializes a new instance of the LatLng class based on another LatLng instance.
Public methodLatLng(Double, Double)
Create a new LatLng object to represent a latitude/longitude pair using the WGS84 datum.
Public methodLatLng(Double, Double, Double)
Create a new LatLng object to represent a latitude/longitude pair using the WGS84 datum.
Public methodLatLng(Double, Double, Double, Datum)
Create a new LatLng object to represent a latitude/longitude pair using the specified datum.
Public methodLatLng(Int32, Int32, Double, NorthSouth, Int32, Int32, Double, EastWest)
Create a new LatLng object to represent a latitude/longitude pair using the WGS84 datum.
Public methodLatLng(Int32, Int32, Double, NorthSouth, Int32, Int32, Double, EastWest, Double)
Create a new LatLng object to represent a latitude/longitude pair using the WGS84 datum.
Public methodLatLng(Int32, Int32, Double, NorthSouth, Int32, Int32, Double, EastWest, Double, Datum)
Create a new LatLng object to represent a latitude/longitude pair using the specified datum.
Top
Properties
  NameDescription
Public propertyDatum
Gets the datum.
Public propertyHeight
Gets the height.
Public propertyLatitude
Gets the latitude in degrees.
Public propertyLatitudeDegrees
Gets the latitude degrees.
Public propertyLatitudeMinutes
Gets the latitude minutes.
Public propertyLatitudeSeconds
Gets the latitude seconds.
Public propertyLongitude
Gets the longitude in degrees.
Public propertyLongitudeDegrees
Gets the longitude degrees.
Public propertyLongitudeMinutes
Gets the longitude minutes.
Public propertyLongitudeSeconds
Gets the longitude seconds.
Top
Methods
  NameDescription
Public methodBearing
Gets the bearing in degrees between two LatLng objects
Public methodDistance
Calculate the surface distance in kilometres from this LatLng to the given LatLng.
Public methodDistanceMiles
Calculate the surface distance in miles from this LatLng to the given LatLng.
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodStatic memberIsValidLatitude
Determines whether the specified latitude is valid.
Public methodStatic memberIsValidLongitude
Determines whether the specified longitude is valid longitude.
Public methodToDatum
Converts this LatLng to another datum.
Public methodToDMSString
Return a String representation of this LatLng object in degrees-minutes-seconds format. The returned format will be like this: DD MM SS.SSS N DD MM SS.SSS E where DD is the number of degrees, MM is the number of minutes, SS.SSS is the number of seconds, N is either N or S to indicate north or south of the equator and E is either E or W to indicate east or west of the prime meridian.
Public methodToMGRSRef
Convert this latitude and longitude to an MGRS reference.
Public methodToOSGB36
Convert this LatLng to the OSGB36 datum using an approximate Helmert transformation. Equivalent to
ToDatum(OSGB36Datum.Instance)
Public methodToOSRef
Convert this latitude and longitude into an OSGB (Ordnance Survey of Great Britain) grid reference.
Public methodToString
Returns a String that represents the current LatLng object.
(Overrides ObjectToString.)
Public methodToUtmRef
Convert this latitude and longitude to a UTM reference.
Public methodToWGS84
Convert this LatLng to the WGS84 datum using an approximate Helmert transformation. Equivalent to
ToDatum(WGS84Datum.Instance)
Top
See Also