Пример #1
0
 public override int GetHashCode()
 {
     return(MaxYear.GetHashCode() >> 1 ^
            MinYear.GetHashCode() >> 2 ^
            MaxDay.GetHashCode() << 1 ^
            MinDay.GetHashCode() << 4 ^
            MaxHour.GetHashCode() >> 2 ^
            MinHour.GetHashCode() >> 1);
 }
 public static void CheckRange(this DayOfWeek dow)
 {
     if (!dow.InRange())
     {
         ExceptionHelper.ThrowArgumentException <ArgumentOutOfRangeException>("dow",
                                                                              "{0} has to be between {1} and {2}.",
                                                                              dow.ToString(),
                                                                              MinDay.ToString(),
                                                                              MaxDay.ToString());
     }
 }