W3cubDocs

/Haskell 9

Data.Time.Calendar.Month

Safe Haskell Safe
Language Haskell2010

Description

An absolute count of common calendar months.

newtype Month Source

An absolute count of common calendar months. Number is equal to (year * 12) + (monthOfYear - 1).

Constructors

MkMonth Integer
Instances
Instances details
NFData Month Source
Instance details

Defined in Data.Time.Calendar.Month

Methods

rnf :: Month -> () Source

Data Month Source
Instance details

Defined in Data.Time.Calendar.Month

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Month -> c Month

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Month

toConstr :: Month -> Constr

dataTypeOf :: Month -> DataType

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Month)

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Month)

gmapT :: (forall b. Data b => b -> b) -> Month -> Month

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Month -> r

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Month -> r

gmapQ :: (forall d. Data d => d -> u) -> Month -> [u]

gmapQi :: Int -> (forall d. Data d => d -> u) -> Month -> u

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Month -> m Month

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Month -> m Month

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Month -> m Month

Enum Month Source
Instance details

Defined in Data.Time.Calendar.Month

Generic Month Source
Instance details

Defined in Data.Time.Calendar.Month

Associated Types

type Rep Month
Instance details

Defined in Data.Time.Calendar.Month

type Rep Month = D1 ('MetaData "Month" "Data.Time.Calendar.Month" "time-1.14-40b8" 'True) (C1 ('MetaCons "MkMonth" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Integer)))

Methods

from :: Month -> Rep Month x

to :: Rep Month x -> Month

Ix Month Source
Instance details

Defined in Data.Time.Calendar.Month

Methods

range :: (Month, Month) -> [Month]

index :: (Month, Month) -> Month -> Int

unsafeIndex :: (Month, Month) -> Month -> Int

inRange :: (Month, Month) -> Month -> Bool

rangeSize :: (Month, Month) -> Int

unsafeRangeSize :: (Month, Month) -> Int

Read Month Source

Read as yyyy-mm.

Instance details

Defined in Data.Time.Calendar.Month

Show Month Source

Show as yyyy-mm.

Instance details

Defined in Data.Time.Calendar.Month

Methods

showsPrec :: Int -> Month -> ShowS

show :: Month -> String

showList :: [Month] -> ShowS

Eq Month Source
Instance details

Defined in Data.Time.Calendar.Month

Methods

(==) :: Month -> Month -> Bool

(/=) :: Month -> Month -> Bool

Ord Month Source
Instance details

Defined in Data.Time.Calendar.Month

Methods

compare :: Month -> Month -> Ordering

(<) :: Month -> Month -> Bool

(<=) :: Month -> Month -> Bool

(>) :: Month -> Month -> Bool

(>=) :: Month -> Month -> Bool

max :: Month -> Month -> Month

min :: Month -> Month -> Month

DayPeriod Month Source
Instance details

Defined in Data.Time.Calendar.Month

FormatTime Month Source
Instance details

Defined in Data.Time.Format.Format.Instances

ParseTime Month Source
Instance details

Defined in Data.Time.Format.Parse.Instances

Lift Month Source
Instance details

Defined in Data.Time.Calendar.Month

Methods

lift :: Quote m => Month -> m Exp

liftTyped :: forall (m :: Type -> Type). Quote m => Month -> Code m Month

type Rep Month Source
Instance details

Defined in Data.Time.Calendar.Month

type Rep Month = D1 ('MetaData "Month" "Data.Time.Calendar.Month" "time-1.14-40b8" 'True) (C1 ('MetaCons "MkMonth" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Integer)))

addMonths :: Integer -> Month -> Month Source

diffMonths :: Month -> Month -> Integer Source

pattern YearMonth :: Year -> MonthOfYear -> Month Source

Bidirectional abstract constructor. Invalid months of year will be clipped to the correct range.

fromYearMonthValid :: Year -> MonthOfYear -> Maybe Month Source

pattern MonthDay :: Month -> DayOfMonth -> Day Source

Bidirectional abstract constructor. Invalid days of month will be clipped to the correct range.

fromMonthDayValid :: Month -> DayOfMonth -> Maybe Day Source

© The University of Glasgow and others
Licensed under a BSD-style license (see top of the page).
https://downloads.haskell.org/~ghc/9.12.1/docs/libraries/time-1.14-40b8/Data-Time-Calendar-Month.html