EastAsianLunisolarCalendar.GetMonthsInYear(Int32, Int32) 方法

定义

计算指定纪元年份中的月数。Calculates the number of months in the specified year and era.

public:
 override int GetMonthsInYear(int year, int era);
public override int GetMonthsInYear (int year, int era);
override this.GetMonthsInYear : int * int -> int
Public Overrides Function GetMonthsInYear (year As Integer, era As Integer) As Integer

参数

year
Int32

一个整数,用于表示年份。An integer that represents the year.

era
Int32

一个整数,用于表示纪元。An integer that represents the era.

返回

指定纪元中指定年份的月数。The number of months in the specified year in the specified era. 返回值是 12 个月(在平年中)或 13 个月(在闰年中)。The return value is 12 months in a common year or 13 months in a leap year.

异常

yearera 超出了此日历支持的范围。year or era is outside the range supported by this calendar.

适用于