Esempio n. 1
0
                public override int GetHashCode()
                {
                    int result = ( int )(EntityId ^ (( long )(( ulong )EntityId >> 32)));

                    result = 31 * result + Added.GetHashCode();
                    result = 31 * result + Changed.GetHashCode();
                    result = 31 * result + Removed.GetHashCode();
                    return(result);
                }
Esempio n. 2
0
 public override int GetHashCode()
 {
     return(bones.GetHashCode()
            ^ infoNode0Index ^ infoNode1Index
            ^ infoNode2Index ^ infoNode3Index
            ^ infoNode4Index ^ infoNode5Index ^ infoNode6Index
            ^ infoNode7Index ^ infoNode8Index
            ^ infoNode9Index ^ infoNodeAIndex
            ^ poleVectorIndex
            ^ slotInfoIndex
            ^ slotOffsetIndex
            ^ rootIndex
            );
 }
Esempio n. 3
0
        public void TestEquals()
        {
            IntList list = new IntList();

            Assert.AreEqual(list, list);
            Assert.IsTrue(!list.Equals(null));
            IntList list2 = new IntList(200);

            Assert.IsTrue(list.Equals(list2)); //Assert.AreEqual(list, list2);
            Assert.IsTrue(list2.Equals(list)); //Assert.AreEqual(list2, list);
            Assert.AreEqual(list.GetHashCode(), list2.GetHashCode());
            list.Add(0);
            list.Add(1);
            list2.Add(1);
            list2.Add(0);
            Assert.IsTrue(!list.Equals(list2));
            list2.RemoveValue(1);
            list2.Add(1);
            Assert.IsTrue(list.Equals(list2)); //Assert.AreEqual(list, list2);
            Assert.IsTrue(list2.Equals(list)); //Assert.AreEqual(list2, list);
            list2.Add(2);
            Assert.IsTrue(!list.Equals(list2));
            Assert.IsTrue(!list2.Equals(list));
        }