Пример #1
0
        /// <summary>
        /// Determines whether the specified object as a <see cref="BoundingBox" /> is equal to this instance.
        /// </summary>
        /// <param name="other">The <see cref="BoundingBox" /> object to compare with this instance.</param>
        /// <returns><c>true</c> if the specified box is equal to this instance; otherwise, <c>false</c>.</returns>
        public override bool Equals(object other)
        {
            bool result;

            if (!(other is BoundingBox))
            {
                result = false;
            }
            else
            {
                BoundingBox box = (BoundingBox)other;
                result = (Center.Equals(box.Center) && Extents.Equals(box.Extents));
            }
            return(result);
        }
Пример #2
0
 public bool Equals(EntityInfo other)
 {
     if (Object.ReferenceEquals(other, null))
     {
         return(false);
     }
     if (Object.ReferenceEquals(this, other))
     {
         return(true);
     }
     return(Extents.Equals(other.Extents) &&
            ClassId.Equals(other.ClassId) &&
            Color.Equals(other.Color) &&
            Layer.Equals(other.Layer) &&
            Linetype.Equals(other.Linetype) &&
            Lineweight.Equals(other.Lineweight));
 }
Пример #3
0
        public bool Equals(EntityInfo other)
        {
            if (ReferenceEquals(this, other))
            {
                return(true);
            }
            if (other is null)
            {
                return(false);
            }
            var res = Extents.Equals(other.Extents) &&
                      ClassId.Equals(other.ClassId) &&
                      Color.Equals(other.Color) &&
                      Layer.Equals(other.Layer) &&
                      Linetype.Equals(other.Linetype) &&
                      Lineweight.Equals(other.Lineweight);

#if DEBUG
            if (!res)
            {
            }
#endif
            return(res);
        }
Пример #4
0
 public bool Equals(SimpleBounds other)
 {
     return(Center.Equals(other.Center) && Extents.Equals(other.Extents));
 }