Пример #1
0
 public override string ToString()
 {
     if (IsHidden)
     {
         return("IL" + IlOffset.ToString("X4") + " (hidden)");
     }
     return("IL" + IlOffset.ToString("X4") + " (" +
            StartLine.ToString() + "-" + EndLine.ToString() + ") (" +
            StartCol.ToString() + "-" + EndCol.ToString() + ")");
 }
Пример #2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (ProtocolVersion != 0)
            {
                hash ^= ProtocolVersion.GetHashCode();
            }
            if (MessageType != 0)
            {
                hash ^= MessageType.GetHashCode();
            }
            if (Side != 0)
            {
                hash ^= Side.GetHashCode();
            }
            if (StartRow != 0)
            {
                hash ^= StartRow.GetHashCode();
            }
            if (StartCol != 0)
            {
                hash ^= StartCol.GetHashCode();
            }
            if (EndRow != 0)
            {
                hash ^= EndRow.GetHashCode();
            }
            if (EndCol != 0)
            {
                hash ^= EndCol.GetHashCode();
            }
            if (GameOutcome != 0)
            {
                hash ^= GameOutcome.GetHashCode();
            }
            return(hash);
        }