class

Month

@Serializable { simple=true }
const class Month : Enum

Enum for twelve months of the year.

constructors fromStr

Return the Month instance for the specified name

fields jul

July

oct

October

apr

April

feb

February

jun

June

dec

December

may

May

vals

List of Month values indexed by ordinal

aug

August

nov

November

jan

January

mar

March

sep

September

methods toLocale

Return the month as a localized string according to the specified pattern

decrement

Return the month before this month

increment

Return the month after this month

localeAbbr

Get the abbreviated name for the current locale

numDays

Return the number of days in this month for the specified year

localeFull

Get the full name for the current locale

apr const static Month : apr

April

aug const static Month : aug

August

dec const static Month : dec

December

decrement @Operator
Month decrement()

Return the month before this month.

feb const static Month : feb

February

fromStr static new fromStr(Str name, Bool checked)

Return the Month instance for the specified name. If not a valid name and checked is false return null, otherwise throw ParseErr.

increment @Operator
Month increment()

Return the month after this month.

jan const static Month : jan

January

jul const static Month : jul

July

jun const static Month : jun

June

localeAbbr Str localeAbbr()

Get the abbreviated name for the current locale. Configured by the sys::<name>Abbr localized property.

localeFull Str localeFull()

Get the full name for the current locale. Configured by the sys::<name>Full localized property.

mar const static Month : mar

March

may const static Month : may

May

nov const static Month : nov

November

numDays Int numDays(Int year)

Return the number of days in this month for the specified year.

oct const static Month : oct

October

sep const static Month : sep

September

toLocale Str toLocale(Str? pattern, Locale locale)

Return the month as a localized string according to the specified pattern. The pattern rules are a subset of the DateTime.toLocale:

M      One/two digit month        6, 11
MM     Two digit month            06, 11
MMM    Three letter abbr month    Jun, Nov
MMMM   Full month name            June, November

If pattern is null it defaults to "MMM". Also see localeAbbr and localeFull.

vals const static Month[] : vals

List of Month values indexed by ordinal

Haxall 4.0.5 ∙ 24-Feb-2026 14:33 EST