示例#1
0
        public override bool Equals(object obj)
        {
            var point = obj as MapPoint;

            if (point == null)
            {
                return(false);
            }

            return(Lat.CompareTo(point.Lat) == 0 && Lon.CompareTo(point.Lon) == 0);
        }
        public int CompareTo(LatLong other)
        {
            var res = Lat.CompareTo(other.Lat);

            if (res != 0)
            {
                return(res);
            }

            return(Lon.CompareTo(other.Lon));
        }
示例#3
0
        public int CompareTo(Waypoint other)
        {
            int x = ID.CompareTo(other.ID);

            if (x == 0)
            {
                int y = Lat.CompareTo(other.Lat);
                if (y == 0)
                {
                    return(Lon.CompareTo(other.Lon));
                }
                return(y);
            }

            return(x);
        }