public TriCircle(GeoTriangle Triangle) { this.Triangle = Triangle; this.Circle = new GeoCircle(Triangle.P1, Triangle.P2, Triangle.P3); this.Neighbors = new List <TriCircle>(); }
/// <summary> /// Compares two instances of this object. /// </summary> /// <param name="ITriangle">An object to compare with.</param> public Int32 CompareTo(GeoTriangle ITriangle) { if ((Object)ITriangle == null) { throw new ArgumentNullException("The given triangle must not be null!"); } // Compare the x-coordinate of the circumcenter var _Result = CircumCenter.Longitude.CompareTo(ITriangle.CircumCenter.Longitude); // If equal: Compare the y-coordinate of the circumcenter if (_Result == 0) { _Result = this.CircumCenter.Latitude.CompareTo(ITriangle.CircumCenter.Latitude); } return(_Result); }
/// <summary> /// Compares two triangles for equality. /// </summary> /// <param name="ITriangle">A triangle to compare with.</param> /// <returns>True if both match; False otherwise.</returns> public Boolean Equals(GeoTriangle ITriangle) { if ((Object)ITriangle == null) { return(false); } return((this.P1.Equals(ITriangle.P1) && this.P2.Equals(ITriangle.P2) && this.P3.Equals(ITriangle.P3)) || (this.P1.Equals(ITriangle.P2) && this.P2.Equals(ITriangle.P3) && this.P3.Equals(ITriangle.P1)) || (this.P1.Equals(ITriangle.P3) && this.P2.Equals(ITriangle.P1) && this.P3.Equals(ITriangle.P2))); }
/// <summary> /// Compares two triangles for equality. /// </summary> /// <param name="ITriangle">A triangle to compare with.</param> /// <returns>True if both match; False otherwise.</returns> public Boolean Equals(GeoTriangle ITriangle) { if ((Object)ITriangle == null) return false; return (this.P1.Equals(ITriangle.P1) && this.P2.Equals(ITriangle.P2) && this.P3.Equals(ITriangle.P3)) || (this.P1.Equals(ITriangle.P2) && this.P2.Equals(ITriangle.P3) && this.P3.Equals(ITriangle.P1)) || (this.P1.Equals(ITriangle.P3) && this.P2.Equals(ITriangle.P1) && this.P3.Equals(ITriangle.P2)); }
/// <summary> /// Compares two instances of this object. /// </summary> /// <param name="ITriangle">An object to compare with.</param> public Int32 CompareTo(GeoTriangle ITriangle) { if ((Object)ITriangle == null) throw new ArgumentNullException("The given triangle must not be null!"); // Compare the x-coordinate of the circumcenter var _Result = CircumCenter.Longitude.CompareTo(ITriangle.CircumCenter.Longitude); // If equal: Compare the y-coordinate of the circumcenter if (_Result == 0) _Result = this.CircumCenter.Latitude.CompareTo(ITriangle.CircumCenter.Latitude); return _Result; }
public TriCircle(GeoTriangle Triangle) { this.Triangle = Triangle; this.Circle = new GeoCircle(Triangle.P1, Triangle.P2, Triangle.P3); this.Neighbors = new List<TriCircle>(); }
public TriCircle(GeoTriangle Triangle, GeoCircle Circle) { this.Triangle = Triangle; this.Circle = Circle; this.Neighbors = new List<TriCircle>(); }
public TriCircle(GeoTriangle Triangle, GeoCircle Circle) { this.Triangle = Triangle; this.Circle = Circle; this.Neighbors = new List <TriCircle>(); }