Spatial4n.Core.Shapes.Impl.RectangleImpl.Equals C# (CSharp) Méthode

Equals() public static méthode

All {@link Rectangle} implementations should use this definition of {@link Object#equals(Object)}.
public static Equals ( Rectangle thiz, Object o ) : bool
thiz Rectangle
o Object
Résultat bool
        public static bool Equals(Rectangle thiz, Object o)
        {
            if (thiz == null)
                throw new ArgumentNullException("thiz");

            if (thiz == o) return true;

            var rectangle = o as Rectangle;
            if (rectangle == null) return false;

            return thiz.GetMaxX().Equals(rectangle.GetMaxX()) && thiz.GetMinX().Equals(rectangle.GetMinX()) &&
                   thiz.GetMaxY().Equals(rectangle.GetMaxY()) && thiz.GetMinY().Equals(rectangle.GetMinY());
        }

Same methods

RectangleImpl::Equals ( object obj ) : bool