// /** // * File: GeoLocation.cs // * Author: haraldwolff // * // * This file and it's content is copyrighted by the Author and / or copyright holder. // * Any use wihtout proper permission is illegal and may lead to legal actions. // * // * // **/ using System; namespace ln.type { public struct GeoLocation { public double Latitude; public double Longitude; public GeoLocation(double latitude,double longitude) { Latitude = latitude; Longitude = longitude; } public override string ToString() { return String.Format("{0:F}{1}{2:F}{3}", (Latitude < 0) ? -Latitude : Latitude, (Latitude < 0) ? 'S':'N', (Longitude < 0) ? -Longitude : Longitude, (Longitude < 0) ? 'W' : 'E' ); } } }