/// <summary> /// Calculate the end date of the FRA which /// will replace the cash instrument /// </summary> /// <param name="calendar"></param> /// <param name="assetController"></param> /// <returns></returns> public DateTime CalculateFraEndTime(IBusinessCalendar calendar, IPriceableRateAssetController assetController)//, //string currency, string rollConvention) { var deposit = (PriceableDeposit)assetController; BusinessDayConventionEnum adjustment = deposit.BusinessDayAdjustments.businessDayConvention; return(DatePeriodHelper.AddPeriod(assetController.GetRiskMaturityDate(), "3M", calendar, adjustment.ToString(), null)); }
/// <summary> /// Calculate the start date of the FRA which /// will replace the cash instrument /// </summary> /// <param name="assetController"></param> /// <returns></returns> public DateTime CalculateFraStartTime(IPriceableRateAssetController assetController) { return(assetController.GetRiskMaturityDate()); }