Beispiel #1
0
 /// <summary>
 /// Returns a hash code for this instance.
 /// </summary>
 /// <returns>A 32-bit signed integer hash code.</returns>
 public override int GetHashCode()
 {
     if (HasTimeSpan)
     {
         return(_timeSpan.GetHashCode());
     }
     else
     {
         return(_durationType.GetHashCode() + 17);
     }
 }
Beispiel #2
0
 public override int GetHashCode()
 {
     return(durationType.GetHashCode() ^ TimeSpan.GetHashCode());
 }