Exemple #1
0
 public override int GetHashCode()
 {
     return(0.CalculateHashCode
            (
                handler.GetHashCode(),
                value.GetHashCode(),
                id.GetHashCode()
            ));
 }
Exemple #2
0
        public override int GetHashCode()
        {
            int polynom(int r, int x)
            {
                unchecked {
                    return((r << 5) + r ^ x);
                }
            };

            int h = 0;

            h = polynom(h, handler.GetHashCode());
            h = polynom(h, value.GetHashCode());
            h = polynom(h, id.GetHashCode());

            return(h);
        }