public static Period Mul(Period periodToMultiply, int multiplier) { if (periodToMultiply == null) { throw new ArgumentNullException("periodToMultiply"); } return(periodToMultiply.Multiply(multiplier)); }
public static Period Negative(this Period thisPeriod) { return(thisPeriod.Multiply(-1)); }
/// <summary> /// Adds the period. /// </summary> /// <param name="date">The date.</param> /// <param name="interval">The interval.</param> /// <param name="numberOfIntervals">The number of intervals.</param> /// <returns></returns> private static DateTime AddPeriod(DateTime date, Period interval, int numberOfIntervals) { return(interval.Multiply(numberOfIntervals).Add(date)); }