WowPacketParser.Misc.WowGuid.Equals C# (CSharp) Method

Equals() public method

public Equals ( WowGuid other ) : bool
other WowGuid
return bool
        public bool Equals(WowGuid other)
        {
            return other.Low == Low && other.High == High;
        }

Same methods

WowGuid::Equals ( object obj ) : bool

Usage Example

Example #1
0
        public void TestEquals()
        {
            var guid1 = new WowGuid(0xF130005C0500105F);
            var guid2 = new WowGuid(0x600000002B2D7C9);
            var guid25 = new WowGuid(0x600000002B2D7C9);
            var guid3 = new WowGuid(0);

            Assert.IsFalse(guid1.Equals(guid2));
            Assert.IsTrue(guid2.Equals(guid25));
            Assert.IsTrue(guid2.Equals((object) guid25));
            Assert.IsFalse(guid2.Equals(new object()));
            Assert.IsTrue(guid3.Equals(guid3));
        }