Пример #1
0
        public static bool IsEqual(this SortedList <int, Point> @this, SortedList <int, Point> other)
        {
            if (!(@this != null &&
                  other != null &&
                  @this.Capacity == other.Capacity &&
                  CheckEquals(@this.Comparer, other.Comparer) &&
                  @this.Count == other.Count &&
                  @this.Keys.CheckSequenceEquals(other.Keys) &&
                  @this.Values.CheckSequenceEquals(other.Values)))
            {
                return(false);
            }

            return(@this.CheckSequenceEquals(other));
        }
Пример #2
0
        public static void IsEqual(this SortedList <int, Point> @this, SortedList <int, Point> other, bool isSamePlatform)
        {
            if (@this == null && other == null)
            {
                return;
            }

            Assert.NotNull(@this);
            Assert.NotNull(other);
            Assert.Equal(@this.Capacity, other.Capacity);
            CheckEquals(@this.Comparer, other.Comparer, isSamePlatform);
            Assert.Equal(@this.Count, other.Count);
            @this.Keys.CheckSequenceEquals(other.Keys, isSamePlatform);
            @this.Values.CheckSequenceEquals(other.Values, isSamePlatform);
            @this.CheckSequenceEquals(other, isSamePlatform);
        }
Пример #3
0
        public static bool IsEqual(this SortedList @this, SortedList other)
        {
            if (!(@this != null &&
                  other != null &&
                  @this.Capacity == other.Capacity &&
                  @this.Count == other.Count &&
                  @this.Keys.CheckSequenceEquals(other.Keys) &&
                  @this.Values.CheckSequenceEquals(other.Values) &&
                  @this.IsReadOnly == other.IsReadOnly &&
                  @this.IsFixedSize == other.IsFixedSize &&
                  @this.IsSynchronized == other.IsSynchronized))
            {
                return(false);
            }

            return(@this.CheckSequenceEquals(other));
        }
Пример #4
0
        public static void IsEqual(this SortedList @this, SortedList other, bool isSamePlatform)
        {
            if (@this == null && other == null)
            {
                return;
            }

            Assert.NotNull(@this);
            Assert.NotNull(other);
            Assert.Equal(@this.Capacity, other.Capacity);
            Assert.Equal(@this.Count, other.Count);
            @this.Keys.CheckSequenceEquals(other.Keys, isSamePlatform);
            @this.Values.CheckSequenceEquals(other.Values, isSamePlatform);
            Assert.Equal(@this.IsReadOnly, other.IsReadOnly);
            Assert.Equal(@this.IsFixedSize, other.IsFixedSize);
            Assert.Equal(@this.IsSynchronized, other.IsSynchronized);
            @this.CheckSequenceEquals(other, isSamePlatform);
        }