Documentation Index
Fetch the complete documentation index at: https://docs.canton.network/llms.txt
Use this file to discover all available pages before exploring further.
DA.Date
This module provides a set of functions to manipulate Date values. The bounds for Date are 0001-01-01T00:00:00.000000Z and 9999-12-31T23:59:59.999999Z.Module Snapshot
Lifecycle
Stable.
Notices
Status:
active
Introduced in: 3.4.9
Removed in: -
Warnings: 0
Deprecations: 0
Deprecated since: -Data Types
data DayOfWeek
Constructors:
Monday
Tuesday
Wednesday
Thursday
Friday
Saturday
Sunday
instance Eq DayOfWeekinstance Ord DayOfWeekinstance Bounded DayOfWeekinstance Enum DayOfWeekinstance Show DayOfWeek
data Month
The Month type represents a month in the Gregorian calendar.
Note that, while Month has an Enum instance, the toEnum and fromEnum
functions start counting at 0, i.e. toEnum 1 :: Month is Feb.
Constructors:
Jan
Feb
Mar
Apr
May
Jun
Jul
Aug
Sep
Oct
Nov
Dec
instance Eq Monthinstance Ord Monthinstance Bounded Monthinstance Enum Monthinstance Show Month
Functions
addDays
subtractDays
subtractDays d r is equivalent to addDays d (- r).
subDate
dayOfWeek
fromGregorian
Date from the triplet (year, month, days).
toGregorian
Date value into a (year, month, day) triple, according
to the Gregorian calendar.
date
Date value.
date y m d turns the year y, month m, and day d into a Date value.
Raises an error if d is outside the range 1 .. monthDayCount y m.
isLeapYear
True if the given year is a leap year.
fromMonth
Jan corresponds
to 1, Feb corresponds to 2, and so on.
monthDayCount
datetime
year, month, day, hours, minutes, seconds.
toDateUTC
Orphan Typeclass Instances
-
instance Eq DayOfWeek -
instance Ord DayOfWeek -
instance Show DayOfWeek -
instance Enum DayOfWeek -
instance Bounded DayOfWeek -
instance Eq Month -
instance Ord Month -
instance Show Month -
instance Enum Month -
instance Bounded Month -
instance Enum Date -
instance Bounded Date