HandCoded.Finance.Calendar.IsBusinessDay C# (CSharp) 메소드

IsBusinessDay() 공개 추상적인 메소드

Determines if the Date provided falls on a business day in this Calendar (e.g. not a holiday or weekend).
public abstract IsBusinessDay ( Date date ) : bool
date Date The to be tested.
리턴 bool
        public abstract bool IsBusinessDay(Date date);

Usage Example

예제 #1
0
 /// <summary>
 /// Adjusts a <see cref="Date"/> to the preceding business day if it falls
 /// on a holiday.
 /// </summary>
 /// <param name="calendar">The <see cref="Calendar"/> to be used.</param>
 /// <param name="date">The <see cref="Date"/> to adjust.</param>
 /// <returns>A (possibly) adjusted <see cref="Date"/> instance.</returns>
 private static Date Preceding(Calendar calendar, Date date)
 {
     while (!calendar.IsBusinessDay(date))
     {
         date = date.PlusDays(-1);
     }
     return(date);
 }
All Usage Examples Of HandCoded.Finance.Calendar::IsBusinessDay