コード例 #1
0
 /// <inheritdoc />
 public override int GetHashCode()
 {
     unchecked // Overflow is fine, just wrap
     {
         var hashCode = 41;
         if (Symbol != null)
         {
             hashCode = hashCode * 59 + Symbol.GetHashCode();
         }
         if (SymbolArray != null)
         {
             hashCode = hashCode * 59 + SymbolArray.GetHashCode();
         }
         if (Opacity != null)
         {
             hashCode = hashCode * 59 + Opacity.GetHashCode();
         }
         if (OpacityArray != null)
         {
             hashCode = hashCode * 59 + OpacityArray.GetHashCode();
         }
         if (MaxDisplayed != null)
         {
             hashCode = hashCode * 59 + MaxDisplayed.GetHashCode();
         }
         if (Size != null)
         {
             hashCode = hashCode * 59 + Size.GetHashCode();
         }
         if (SizeArray != null)
         {
             hashCode = hashCode * 59 + SizeArray.GetHashCode();
         }
         if (SizeRef != null)
         {
             hashCode = hashCode * 59 + SizeRef.GetHashCode();
         }
         if (SizeMin != null)
         {
             hashCode = hashCode * 59 + SizeMin.GetHashCode();
         }
         if (SizeMode != null)
         {
             hashCode = hashCode * 59 + SizeMode.GetHashCode();
         }
         if (Line != null)
         {
             hashCode = hashCode * 59 + Line.GetHashCode();
         }
         if (Gradient != null)
         {
             hashCode = hashCode * 59 + Gradient.GetHashCode();
         }
         if (Color != null)
         {
             hashCode = hashCode * 59 + Color.GetHashCode();
         }
         if (ColorArray != null)
         {
             hashCode = hashCode * 59 + ColorArray.GetHashCode();
         }
         if (CAuto != null)
         {
             hashCode = hashCode * 59 + CAuto.GetHashCode();
         }
         if (CMin != null)
         {
             hashCode = hashCode * 59 + CMin.GetHashCode();
         }
         if (CMax != null)
         {
             hashCode = hashCode * 59 + CMax.GetHashCode();
         }
         if (CMid != null)
         {
             hashCode = hashCode * 59 + CMid.GetHashCode();
         }
         if (ColorScale != null)
         {
             hashCode = hashCode * 59 + ColorScale.GetHashCode();
         }
         if (AutoColorScale != null)
         {
             hashCode = hashCode * 59 + AutoColorScale.GetHashCode();
         }
         if (ReverseScale != null)
         {
             hashCode = hashCode * 59 + ReverseScale.GetHashCode();
         }
         if (ShowScale != null)
         {
             hashCode = hashCode * 59 + ShowScale.GetHashCode();
         }
         if (ColorBar != null)
         {
             hashCode = hashCode * 59 + ColorBar.GetHashCode();
         }
         if (ColorAxis != null)
         {
             hashCode = hashCode * 59 + ColorAxis.GetHashCode();
         }
         if (SymbolSrc != null)
         {
             hashCode = hashCode * 59 + SymbolSrc.GetHashCode();
         }
         if (OpacitySrc != null)
         {
             hashCode = hashCode * 59 + OpacitySrc.GetHashCode();
         }
         if (SizeSrc != null)
         {
             hashCode = hashCode * 59 + SizeSrc.GetHashCode();
         }
         if (ColorSrc != null)
         {
             hashCode = hashCode * 59 + ColorSrc.GetHashCode();
         }
         return(hashCode);
     }
 }
コード例 #2
0
        /// <inheritdoc />
        public bool Equals([AllowNull] Marker other)
        {
            if (other == null)
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Symbol == other.Symbol ||
                     Symbol != null &&
                     Symbol.Equals(other.Symbol)
                     ) &&
                 (
                     Equals(SymbolArray, other.SymbolArray) ||
                     SymbolArray != null && other.SymbolArray != null &&
                     SymbolArray.SequenceEqual(other.SymbolArray)
                 ) &&
                 (
                     Opacity == other.Opacity ||
                     Opacity != null &&
                     Opacity.Equals(other.Opacity)
                 ) &&
                 (
                     Equals(OpacityArray, other.OpacityArray) ||
                     OpacityArray != null && other.OpacityArray != null &&
                     OpacityArray.SequenceEqual(other.OpacityArray)
                 ) &&
                 (
                     MaxDisplayed == other.MaxDisplayed ||
                     MaxDisplayed != null &&
                     MaxDisplayed.Equals(other.MaxDisplayed)
                 ) &&
                 (
                     Size == other.Size ||
                     Size != null &&
                     Size.Equals(other.Size)
                 ) &&
                 (
                     Equals(SizeArray, other.SizeArray) ||
                     SizeArray != null && other.SizeArray != null &&
                     SizeArray.SequenceEqual(other.SizeArray)
                 ) &&
                 (
                     SizeRef == other.SizeRef ||
                     SizeRef != null &&
                     SizeRef.Equals(other.SizeRef)
                 ) &&
                 (
                     SizeMin == other.SizeMin ||
                     SizeMin != null &&
                     SizeMin.Equals(other.SizeMin)
                 ) &&
                 (
                     SizeMode == other.SizeMode ||
                     SizeMode != null &&
                     SizeMode.Equals(other.SizeMode)
                 ) &&
                 (
                     Line == other.Line ||
                     Line != null &&
                     Line.Equals(other.Line)
                 ) &&
                 (
                     Gradient == other.Gradient ||
                     Gradient != null &&
                     Gradient.Equals(other.Gradient)
                 ) &&
                 (
                     Color == other.Color ||
                     Color != null &&
                     Color.Equals(other.Color)
                 ) &&
                 (
                     Equals(ColorArray, other.ColorArray) ||
                     ColorArray != null && other.ColorArray != null &&
                     ColorArray.SequenceEqual(other.ColorArray)
                 ) &&
                 (
                     CAuto == other.CAuto ||
                     CAuto != null &&
                     CAuto.Equals(other.CAuto)
                 ) &&
                 (
                     CMin == other.CMin ||
                     CMin != null &&
                     CMin.Equals(other.CMin)
                 ) &&
                 (
                     CMax == other.CMax ||
                     CMax != null &&
                     CMax.Equals(other.CMax)
                 ) &&
                 (
                     CMid == other.CMid ||
                     CMid != null &&
                     CMid.Equals(other.CMid)
                 ) &&
                 (
                     ColorScale == other.ColorScale ||
                     ColorScale != null &&
                     ColorScale.Equals(other.ColorScale)
                 ) &&
                 (
                     AutoColorScale == other.AutoColorScale ||
                     AutoColorScale != null &&
                     AutoColorScale.Equals(other.AutoColorScale)
                 ) &&
                 (
                     ReverseScale == other.ReverseScale ||
                     ReverseScale != null &&
                     ReverseScale.Equals(other.ReverseScale)
                 ) &&
                 (
                     ShowScale == other.ShowScale ||
                     ShowScale != null &&
                     ShowScale.Equals(other.ShowScale)
                 ) &&
                 (
                     ColorBar == other.ColorBar ||
                     ColorBar != null &&
                     ColorBar.Equals(other.ColorBar)
                 ) &&
                 (
                     ColorAxis == other.ColorAxis ||
                     ColorAxis != null &&
                     ColorAxis.Equals(other.ColorAxis)
                 ) &&
                 (
                     SymbolSrc == other.SymbolSrc ||
                     SymbolSrc != null &&
                     SymbolSrc.Equals(other.SymbolSrc)
                 ) &&
                 (
                     OpacitySrc == other.OpacitySrc ||
                     OpacitySrc != null &&
                     OpacitySrc.Equals(other.OpacitySrc)
                 ) &&
                 (
                     SizeSrc == other.SizeSrc ||
                     SizeSrc != null &&
                     SizeSrc.Equals(other.SizeSrc)
                 ) &&
                 (
                     ColorSrc == other.ColorSrc ||
                     ColorSrc != null &&
                     ColorSrc.Equals(other.ColorSrc)
                 ));
        }