HebrewCalendar.IsLeapMonth(Int32, Int32, Int32) メソッド

定義

指定した年の指定した年の指定した月が閏月かどうかを判断します。

public:
 override bool IsLeapMonth(int year, int month, int era);
public override bool IsLeapMonth(int year, int month, int era);
override this.IsLeapMonth : int * int * int -> bool
abstract member IsLeapMonth : int * int * int -> bool
override this.IsLeapMonth : int * int * int -> bool
Public Overrides Function IsLeapMonth (year As Integer, month As Integer, era As Integer) As Boolean

パラメーター

year
Int32

年を表す整数。

month
Int32

月を表す 1 ~ 13 の整数。

era
Int32

時代 (年号) を表す整数。 HebrewEra または HebrewCalendar.Eras[Calendar.CurrentEra] を指定します。

返品

true 指定した月が閏月の場合。それ以外の場合は false

例外

yearmonth、または era は、このカレンダーでサポートされている範囲外です。

次のコード例では、現在の時代 (年号) の 5 年間のすべての月の IsLeapMonth を呼び出します。

using System;
using System.Globalization;

public class SamplesHebrewCalendar  {

   public static void Main()  {

      // Creates and initializes a HebrewCalendar.
      HebrewCalendar myCal = new HebrewCalendar();

      // Checks all the months in five years in the current era.
      int iMonthsInYear;
      for ( int y = 5761; y <= 5765; y++ )  {
         Console.Write( "{0}:\t", y );
         iMonthsInYear = myCal.GetMonthsInYear( y, HebrewCalendar.CurrentEra );
         for ( int m = 1; m <= iMonthsInYear; m++ )
            Console.Write( "\t{0}", myCal.IsLeapMonth( y, m, HebrewCalendar.CurrentEra ) );
         Console.WriteLine();
      }
   }
}

/*
This code produces the following output.

5761:           False   False   False   False   False   False   False   False   False   False   False   False
5762:           False   False   False   False   False   False   False   False   False   False   False   False
5763:           False   False   False   False   False   False   True    False   False   False   False   False   False
5764:           False   False   False   False   False   False   False   False   False   False   False   False
5765:           False   False   False   False   False   False   True    False   False   False   False   False   False

*/
Imports System.Globalization

Public Class SamplesHebrewCalendar   
   
   Public Shared Sub Main()

      ' Creates and initializes a HebrewCalendar.
      Dim myCal As New HebrewCalendar()

      ' Checks all the months in five years in the current era.
      Dim iMonthsInYear As Integer
      Dim y As Integer
      For y = 5761 To 5765
         Console.Write("{0}:" + ControlChars.Tab, y)
         iMonthsInYear = myCal.GetMonthsInYear(y, HebrewCalendar.CurrentEra)
         Dim m As Integer
         For m = 1 To iMonthsInYear
            Console.Write(ControlChars.Tab + "{0}", myCal.IsLeapMonth(y, m, HebrewCalendar.CurrentEra))
         Next m
         Console.WriteLine()
      Next y

   End Sub

End Class


'This code produces the following output.
'
'5761:           False   False   False   False   False   False   False   False   False   False   False   False
'5762:           False   False   False   False   False   False   False   False   False   False   False   False
'5763:           False   False   False   False   False   False   True    False   False   False   False   False   False
'5764:           False   False   False   False   False   False   False   False   False   False   False   False
'5765:           False   False   False   False   False   False   True    False   False   False   False   False   False

注釈

HebrewCalendarクラスのこの実装では、ヘブライ語の年 5343 年から 5999 年 (グレゴリオ暦では 1583 年から 2239 年) のみが認識されます。

19 日までに均等に割り切れる年で終わる 19 年ごとのサイクルでは、3、6、8、11、14、17、および 19 年は閏年です。 一般的な年は、ユダヤ人の休日の配置に応じて、353から355日を持つことができます。 閏年は、383 日から 385 日までです。

閏月は、閏年でのみ発生する月全体です。 ヘブライ暦では、Adar Beit は唯一の閏月です。

適用対象

こちらもご覧ください