コード例 #1
0
 /// <summary>
 /// Determines whether a specified TimeValue is greater than another TimeValue instance
 /// </summary>
 /// <returns>A boolean indicating whether the first TimeValue is greater than the second</returns>
 public static bool IsGreaterThan(this TimeValue timeValue, TimeValue otherTimeValue)
 {
     if (timeValue.Unit == otherTimeValue.Unit)
     {
         return(timeValue.Duration > otherTimeValue.Duration);
     }
     else
     {
         return(timeValue.ToMilliseconds() > otherTimeValue.ToMilliseconds());
     }
 }