EastAsianLunisolarCalendar 類別

定義

表示曆法,這個曆法會將時間分割成月、日、年和紀元,並根據太陽和月亮的循環週期來產生日期。Represents a calendar that divides time into months, days, years, and eras, and has dates that are based on cycles of the sun and the moon.

public ref class EastAsianLunisolarCalendar abstract : System::Globalization::Calendar
public abstract class EastAsianLunisolarCalendar : System.Globalization.Calendar
[System.Runtime.InteropServices.ComVisible(true)]
[System.Serializable]
public abstract class EastAsianLunisolarCalendar : System.Globalization.Calendar
type EastAsianLunisolarCalendar = class
    inherit Calendar
Public MustInherit Class EastAsianLunisolarCalendar
Inherits Calendar
繼承
EastAsianLunisolarCalendar
衍生
屬性

備註

EastAsianLunisolarCalendar 類別支援年份的甲子週期(每60年重複一次),以及陽曆年和農曆的月份。The EastAsianLunisolarCalendar class supports the sexagenary cycle of years (which repeats every 60 years) in addition to solar years and lunar months. 行事曆中的每個日光年度都會與甲子年相關聯(請參閱 GetSexagenaryYear)、著天體的詞幹(請參閱 GetCelestialStem)和地面分支(請參閱 GetTerrestrialBranch)。Each solar year in the calendar is associated with a Sexagenary Year (see GetSexagenaryYear), a Celestial Stem (see GetCelestialStem), and a Terrestrial Branch (see GetTerrestrialBranch).

注意

如需在 .NET Framework 中使用 EastAsianLunisolarCalendar 類別和其他行事曆類別的詳細資訊,請參閱使用行事For information about using the EastAsianLunisolarCalendar class and the other calendar classes in the .NET Framework, see Working with Calendars.

一年可以在一年中的任何月份之後有一個閏月,一個月可以有一個閏日。A year can have a leap month after any month of the year, and a month can have a leap day. 例如,GetMonth 方法會傳回一個正整數,這個整數表示與指定日期相關聯的月份。For example, the GetMonth method returns a positive integer that indicates the month associated with a specified date. 如果一年的第八到第九個月之間有閏月,則 GetMonth 方法會針對第八個月傳回8個,而在第八個月則傳回9個,而第九個月則會傳回10個月。If there is a leap month between the eighth and ninth months of the year, the GetMonth method returns 8 for the eighth month, 9 for the leap eighth month, and 10 for the ninth month.

每個 CultureInfo 都支援一組行事曆。Each CultureInfo supports a set of calendars. 目前,CultureInfo 類別所支援的任何文化特性都不會使用衍生自 EastAsianLunisolarCalendar 的任何陰陽曆類別。Currently, none of the lunisolar calendar classes that derive from EastAsianLunisolarCalendar is used by any of the cultures supported by the CultureInfo class. 因此,這個類別及其衍生自它的只能用來計算東亞日曆中的日期。Therefore, this class and those that derive from it can be used only to calculate dates in the East Asian lunisolar calendars. 這個類別支援數種「get」方法來描述陰陽曆所使用之詞彙中的 DateTime,以及從陰陽曆資料轉換成 DateTimeToDateTime 方法。This class supports several "get" methods to describe a DateTime in the terms used by lunisolar calendars, and the ToDateTime method to convert from lunisolar calendar data to a DateTime.

欄位

CurrentEra

表示目前曆法的目前紀元。Represents the current era of the current calendar. 此欄位的值為 0。The value of this field is 0.

(繼承來源 Calendar)

屬性

AlgorithmType

取得值,指出目前的月曆是以陽曆為主、以陰曆為主,還是同時包含兩種曆法。Gets a value indicating whether the current calendar is solar-based, lunar-based, or a combination of both.

DaysInYearBeforeMinSupportedYear

取得 MinSupportedDateTime 屬性指定之年的前一年的天數。Gets the number of days in the year that precedes the year that is specified by the MinSupportedDateTime property.

(繼承來源 Calendar)
Eras

當在衍生類別中覆寫時,取得目前曆法中的紀元清單。When overridden in a derived class, gets the list of eras in the current calendar.

(繼承來源 Calendar)
IsReadOnly

取得值,指出 Calendar 物件是否為唯讀。Gets a value indicating whether this Calendar object is read-only.

(繼承來源 Calendar)
MaxSupportedDateTime

取得受 Calendar 物件所支援的最晚日期和時間。Gets the latest date and time supported by this Calendar object.

(繼承來源 Calendar)
MinSupportedDateTime

取得受 Calendar 物件所支援的最早日期和時間。Gets the earliest date and time supported by this Calendar object.

(繼承來源 Calendar)
TwoDigitYearMax

取得或設定以二位數年份表示時,該 100 年範圍的最後一年。Gets or sets the last year of a 100-year range that can be represented by a 2-digit year.

方法

AddDays(DateTime, Int32)

傳回與指定 DateTime 相差指定日數的 DateTimeReturns a DateTime that is the specified number of days away from the specified DateTime.

(繼承來源 Calendar)
AddHours(DateTime, Int32)

傳回與指定 DateTime 相差指定時數的 DateTimeReturns a DateTime that is the specified number of hours away from the specified DateTime.

(繼承來源 Calendar)
AddMilliseconds(DateTime, Double)

傳回與指定 DateTime 相差指定毫秒數的 DateTimeReturns a DateTime that is the specified number of milliseconds away from the specified DateTime.

(繼承來源 Calendar)
AddMinutes(DateTime, Int32)

傳回與指定 DateTime 相差指定分鐘數的 DateTimeReturns a DateTime that is the specified number of minutes away from the specified DateTime.

(繼承來源 Calendar)
AddMonths(DateTime, Int32)

計算與指定日期相差指定月數的日期。Calculates the date that is the specified number of months away from the specified date.

AddSeconds(DateTime, Int32)

傳回與指定 DateTime 相差指定秒數的 DateTimeReturns a DateTime that is the specified number of seconds away from the specified DateTime.

(繼承來源 Calendar)
AddWeeks(DateTime, Int32)

傳回與指定 DateTime 相差指定週數的 DateTimeReturns a DateTime that is the specified number of weeks away from the specified DateTime.

(繼承來源 Calendar)
AddYears(DateTime, Int32)

計算與指定日期相差指定年份的日期。Calculates the date that is the specified number of years away from the specified date.

Clone()

建立目前 Calendar 物件複本的新物件。Creates a new object that is a copy of the current Calendar object.

(繼承來源 Calendar)
Equals(Object)

判斷指定的物件是否等於目前的物件。Determines whether the specified object is equal to the current object.

(繼承來源 Object)
GetCelestialStem(Int32)

計算以六十年 (60 年) 為週期中指定年份的天干。Calculates the celestial stem of the specified year in the sexagenary (60-year) cycle.

GetDayOfMonth(DateTime)

計算指定日期中月份的日期。Calculates the day of the month in the specified date.

GetDayOfWeek(DateTime)

計算指定日期中一週的日期。Calculates the day of the week in the specified date.

GetDayOfYear(DateTime)

計算指定日期中年份的日期。Calculates the day of the year in the specified date.

GetDaysInMonth(Int32, Int32)

傳回目前紀元之指定月份和年份中的天數。Returns the number of days in the specified month and year of the current era.

(繼承來源 Calendar)
GetDaysInMonth(Int32, Int32, Int32)

計算指定年份和紀元的指定月份中的天數。Calculates the number of days in the specified month of the specified year and era.

GetDaysInYear(Int32)

傳回目前紀元之指定年份中的天數。Returns the number of days in the specified year of the current era.

(繼承來源 Calendar)
GetDaysInYear(Int32, Int32)

計算指定年份和紀元中的天數。Calculates the number of days in the specified year and era.

GetEra(DateTime)

當在衍生類別中覆寫時,傳回指定 DateTime 的紀元。When overridden in a derived class, returns the era of the specified DateTime.

(繼承來源 Calendar)
GetHashCode()

作為預設雜湊函數。Serves as the default hash function.

(繼承來源 Object)
GetHour(DateTime)

傳回指定 DateTime 中的小時值。Returns the hours value in the specified DateTime.

(繼承來源 Calendar)
GetLeapMonth(Int32)

計算指定年份的閏月。Calculates the leap month for a specified year.

(繼承來源 Calendar)
GetLeapMonth(Int32, Int32)

計算指定年份和紀元的閏月。Calculates the leap month for the specified year and era.

GetMilliseconds(DateTime)

傳回指定 DateTime 中的毫秒值。Returns the milliseconds value in the specified DateTime.

(繼承來源 Calendar)
GetMinute(DateTime)

傳回指定 DateTime 中的分鐘值。Returns the minutes value in the specified DateTime.

(繼承來源 Calendar)
GetMonth(DateTime)

傳回指定日期中的月份。Returns the month in the specified date.

GetMonthsInYear(Int32)

傳回目前紀元的指定年份中的月數。Returns the number of months in the specified year in the current era.

(繼承來源 Calendar)
GetMonthsInYear(Int32, Int32)

計算指定年份和紀元中的月數。Calculates the number of months in the specified year and era.

GetSecond(DateTime)

傳回指定 DateTime 中的秒值。Returns the seconds value in the specified DateTime.

(繼承來源 Calendar)
GetSexagenaryYear(DateTime)

計算以六十年 (60 年) 為週期中對應至指定日期的年份。Calculates the year in the sexagenary (60-year) cycle that corresponds to the specified date.

GetTerrestrialBranch(Int32)

計算以六十年 (60 年) 為週期中指定年份的地支。Calculates the terrestrial branch of the specified year in the sexagenary (60-year) cycle.

GetType()

取得目前執行個體的 TypeGets the Type of the current instance.

(繼承來源 Object)
GetWeekOfYear(DateTime, CalendarWeekRule, DayOfWeek)

傳回年份中的週,其中包含指定之 DateTime 值中的日期。Returns the week of the year that includes the date in the specified DateTime value.

(繼承來源 Calendar)
GetYear(DateTime)

傳回指定日期中的年份。Returns the year in the specified date.

IsLeapDay(Int32, Int32, Int32)

判斷目前紀元中指定日期是否為閏日。Determines whether the specified date in the current era is a leap day.

(繼承來源 Calendar)
IsLeapDay(Int32, Int32, Int32, Int32)

判斷指定紀元中指定的日期是否為閏日。Determines whether the specified date in the specified era is a leap day.

IsLeapMonth(Int32, Int32)

判斷目前紀元的指定年份中指定的月份是否為閏月。Determines whether the specified month in the specified year in the current era is a leap month.

(繼承來源 Calendar)
IsLeapMonth(Int32, Int32, Int32)

判斷指定年份和紀元中的指定月份是否為閏月。Determines whether the specified month in the specified year and era is a leap month.

IsLeapYear(Int32)

判斷目前紀元中指定的年份是否為閏年。Determines whether the specified year in the current era is a leap year.

(繼承來源 Calendar)
IsLeapYear(Int32, Int32)

判斷指定紀元中指定的年份是否為閏年。Determines whether the specified year in the specified era is a leap year.

MemberwiseClone()

建立目前 Object 的淺層複本 (Shallow Copy)。Creates a shallow copy of the current Object.

(繼承來源 Object)
ToDateTime(Int32, Int32, Int32, Int32, Int32, Int32, Int32)

傳回設定為目前紀元中指定日期和時間的 DateTimeReturns a DateTime that is set to the specified date and time in the current era.

(繼承來源 Calendar)
ToDateTime(Int32, Int32, Int32, Int32, Int32, Int32, Int32, Int32)

傳回 DateTime 物件,其設定為指定日期、時間和紀元。Returns a DateTime that is set to the specified date, time, and era.

ToFourDigitYear(Int32)

將指定的年份轉換成 4 位數年份。Converts the specified year to a four-digit year.

ToString()

傳回代表目前物件的字串。Returns a string that represents the current object.

(繼承來源 Object)

適用於

另請參閱