C# 클래스 Rolcore.DateTimeUtils

Utility methods for DateTime.
파일 보기 프로젝트 열기: Rollins/Rolcore

공개 메소드들

메소드 설명
GetLastDayOfWeekInMonth ( int year, MonthOfYear month, DayOfWeek dayOfWeek ) : System.DateTime

Gets the last occurrence of the specified DayOfWeek within the given month and year.

GetNthDayOfWeekInMonth ( int year, MonthOfYear month, DayOfWeek dayOfWeek, short dayOccurences ) : System.DateTime

Gets the "Nth" day of the month (for example, the 3rd Monday in January) as a DateTime.

HolidaysByYear ( int year ) : System.DateTime[]

Gets a list of DateTimes that are holidays in the given year.

메소드 상세

GetLastDayOfWeekInMonth() 공개 정적인 메소드

Gets the last occurrence of the specified DayOfWeek within the given month and year.
public static GetLastDayOfWeekInMonth ( int year, MonthOfYear month, DayOfWeek dayOfWeek ) : System.DateTime
year int The year for which to calculate the desired date.
month MonthOfYear The month for which to calculate the desired date.
dayOfWeek DayOfWeek The to calculate.
리턴 System.DateTime

GetNthDayOfWeekInMonth() 공개 정적인 메소드

Gets the "Nth" day of the month (for example, the 3rd Monday in January) as a DateTime.
public static GetNthDayOfWeekInMonth ( int year, MonthOfYear month, DayOfWeek dayOfWeek, short dayOccurences ) : System.DateTime
year int The year in which the date should be calculated.
month MonthOfYear The month (1 through 12) in which the date should be calculated.
dayOfWeek DayOfWeek The day of week to calculate in the given month and year.
dayOccurences short Which occurrence to calculate (1 through 5).
리턴 System.DateTime

HolidaysByYear() 공개 정적인 메소드

Gets a list of DateTimes that are holidays in the given year.
public static HolidaysByYear ( int year ) : System.DateTime[]
year int The year in which to calculate holidays for.
리턴 System.DateTime[]