time-1.14: A time library
Safe HaskellSafe
LanguageHaskell2010

Data.Time.Calendar.Quarter

Description

Year quarters.

Synopsis

Documentation

data QuarterOfYear Source #

Quarters of each year. Each quarter corresponds to three months.

Constructors

Q1 
Q2 
Q3 
Q4 

Instances

Instances details
NFData QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Methods

rnf :: QuarterOfYear -> () Source #

Data QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Methods

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

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

toConstr :: QuarterOfYear -> Constr #

dataTypeOf :: QuarterOfYear -> DataType #

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

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

gmapT :: (forall b. Data b => b -> b) -> QuarterOfYear -> QuarterOfYear #

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

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

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

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

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

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

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

Bounded QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Enum QuarterOfYear Source #

maps Q1..Q4 to 1..4

Instance details

Defined in Data.Time.Calendar.Quarter

Generic QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Associated Types

type Rep QuarterOfYear 
Instance details

Defined in Data.Time.Calendar.Quarter

type Rep QuarterOfYear = D1 ('MetaData "QuarterOfYear" "Data.Time.Calendar.Quarter" "time-1.14-40b8" 'False) ((C1 ('MetaCons "Q1" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Q2" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Q3" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Q4" 'PrefixI 'False) (U1 :: Type -> Type)))
Ix QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Read QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Show QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Eq QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Ord QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Lift QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Methods

lift :: Quote m => QuarterOfYear -> m Exp #

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

type Rep QuarterOfYear Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

type Rep QuarterOfYear = D1 ('MetaData "QuarterOfYear" "Data.Time.Calendar.Quarter" "time-1.14-40b8" 'False) ((C1 ('MetaCons "Q1" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Q2" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Q3" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Q4" 'PrefixI 'False) (U1 :: Type -> Type)))

newtype Quarter Source #

An absolute count of year quarters. Number is equal to (year * 4) + (quarterOfYear - 1).

Constructors

MkQuarter Integer 

Instances

Instances details
NFData Quarter Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Methods

rnf :: Quarter -> () Source #

Data Quarter Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Methods

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

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

toConstr :: Quarter -> Constr #

dataTypeOf :: Quarter -> DataType #

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

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

gmapT :: (forall b. Data b => b -> b) -> Quarter -> Quarter #

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

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

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

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

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

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

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

Enum Quarter Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Generic Quarter Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Associated Types

type Rep Quarter 
Instance details

Defined in Data.Time.Calendar.Quarter

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

Methods

from :: Quarter -> Rep Quarter x #

to :: Rep Quarter x -> Quarter #

Ix Quarter Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Read Quarter Source #

Read as yyyy-Qn.

Instance details

Defined in Data.Time.Calendar.Quarter

Show Quarter Source #

Show as yyyy-Qn.

Instance details

Defined in Data.Time.Calendar.Quarter

Eq Quarter Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

Methods

(==) :: Quarter -> Quarter -> Bool #

(/=) :: Quarter -> Quarter -> Bool #

Ord Quarter Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

DayPeriod Quarter Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

type Rep Quarter Source # 
Instance details

Defined in Data.Time.Calendar.Quarter

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

pattern YearQuarter :: Year -> QuarterOfYear -> Quarter Source #

Bidirectional abstract constructor.

dayQuarter :: Day -> Quarter Source #

The Quarter this Day is in.

type DayOfQuarter = Int Source #

Day of quarter, in range 1 to 92.

pattern QuarterDay :: Quarter -> DayOfQuarter -> Day Source #

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

Since: time-1.12.1