Exemplo n.º 1
0
        public override int GetHashCode()
        {
            int result = 0;

            if (BlankType.HasValue)
            {
                result += (int)BlankType.Value;
            }
            if (VotingMode.HasValue)
            {
                result += ((int)VotingMode.Value) << 2;
            }
            if (ScannerSerialNumber.HasValue)
            {
                result += (ScannerSerialNumber.Value % 16) << 5;
            }
            if (CandidateId != null)
            {
                result ^= CandidateId.GetHashCode();
            }
            if (BlankId != null)
            {
                result ^= BlankId.GetHashCode();
            }
            if (ElectionNum != null)
            {
                result ^= ElectionNum.GetHashCode();
            }
            return(result);
        }
Exemplo n.º 2
0
 public override int GetHashCode()
 {
     return(CandidateId.GetHashCode());
 }
Exemplo n.º 3
0
 public string WhatsYourId()
 {
     return(CandidateId.GetId());
 }