-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | Compatibility package for time
--   
--   This packages tries to compat as much of <tt>time</tt> features as
--   possible.
--   
--   <i>TODO:</i>
--   
--   <ul>
--   <li>Difference type <tt>ParseTime</tt> and <tt>FormatTime</tt>
--   instances are missing.</li>
--   <li>Formatting varies depending on underlying <tt>time</tt>
--   version</li>
--   <li><tt>dayFractionToTimeOfDay</tt> on extreme values</li>
--   </ul>
@package time-compat
@version 1.9.2.2

module Data.Time.Format.Compat
class FormatTime t
formatTime :: FormatTime t => TimeLocale -> String -> t -> String

-- | Parses a time value given a format string.
--   
--   This variant from <tt>time-compat</tt> has always <a>MonadFail</a>
--   constraint.
--   
--   Look at <a>parseTimeM</a> for documentation.
parseTimeM :: (MonadFail m, ParseTime t) => Bool -> TimeLocale -> String -> String -> m t
parseTimeOrError :: ParseTime t => Bool -> TimeLocale -> String -> String -> t
readSTime :: ParseTime t => Bool -> TimeLocale -> String -> ReadS t
readPTime :: ParseTime t => Bool -> TimeLocale -> String -> ReadP t
parseTime :: ParseTime t => TimeLocale -> String -> String -> Maybe t
readTime :: ParseTime t => TimeLocale -> String -> String -> t
readsTime :: ParseTime t => TimeLocale -> String -> ReadS t
class ParseTime t
data TimeLocale
TimeLocale :: [(String, String)] -> [(String, String)] -> (String, String) -> String -> String -> String -> String -> [TimeZone] -> TimeLocale
[wDays] :: TimeLocale -> [(String, String)]
[months] :: TimeLocale -> [(String, String)]
[amPm] :: TimeLocale -> (String, String)
[dateTimeFmt] :: TimeLocale -> String
[dateFmt] :: TimeLocale -> String
[timeFmt] :: TimeLocale -> String
[time12Fmt] :: TimeLocale -> String
[knownTimeZones] :: TimeLocale -> [TimeZone]
defaultTimeLocale :: TimeLocale
iso8601DateFormat :: Maybe String -> String
rfc822DateFormat :: String

module Data.Time.Clock.System.Compat
systemEpochDay :: Day
data SystemTime
MkSystemTime :: {-# UNPACK #-} !Int64 -> {-# UNPACK #-} !Word32 -> SystemTime
[systemSeconds] :: SystemTime -> {-# UNPACK #-} !Int64
[systemNanoseconds] :: SystemTime -> {-# UNPACK #-} !Word32
truncateSystemTimeLeapSecond :: SystemTime -> SystemTime
getSystemTime :: IO SystemTime
systemToUTCTime :: SystemTime -> UTCTime
utcToSystemTime :: UTCTime -> SystemTime
systemToTAITime :: SystemTime -> AbsoluteTime

module Data.Time.Clock.POSIX.Compat
posixDayLength :: NominalDiffTime
type POSIXTime = NominalDiffTime
posixSecondsToUTCTime :: POSIXTime -> UTCTime
utcTimeToPOSIXSeconds :: UTCTime -> POSIXTime
getPOSIXTime :: IO POSIXTime
getCurrentTime :: IO UTCTime
systemToPOSIXTime :: SystemTime -> POSIXTime

module Data.Time.Clock.Compat
newtype UniversalTime
ModJulianDate :: Rational -> UniversalTime
[getModJulianDate] :: UniversalTime -> Rational
data DiffTime
secondsToDiffTime :: Integer -> DiffTime
picosecondsToDiffTime :: Integer -> DiffTime
diffTimeToPicoseconds :: DiffTime -> Integer
data UTCTime
UTCTime :: Day -> DiffTime -> UTCTime
[utctDay] :: UTCTime -> Day
[utctDayTime] :: UTCTime -> DiffTime
data NominalDiffTime

-- | Create a <a>NominalDiffTime</a> from a number of seconds.
secondsToNominalDiffTime :: Pico -> NominalDiffTime

-- | Get the seconds in a <a>NominalDiffTime</a>.
nominalDiffTimeToSeconds :: NominalDiffTime -> Pico
nominalDay :: NominalDiffTime
addUTCTime :: NominalDiffTime -> UTCTime -> UTCTime
diffUTCTime :: UTCTime -> UTCTime -> NominalDiffTime
getCurrentTime :: IO UTCTime
getTime_resolution :: DiffTime

module Data.Time.Calendar.WeekDate.Compat
toWeekDate :: Day -> (Integer, Int, Int)
fromWeekDate :: Integer -> Int -> Int -> Day
fromWeekDateValid :: Integer -> Int -> Int -> Maybe Day
showWeekDate :: Day -> String

module Data.Time.Calendar.OrdinalDate.Compat
toOrdinalDate :: Day -> (Integer, Int)
fromOrdinalDate :: Integer -> Int -> Day
fromOrdinalDateValid :: Integer -> Int -> Maybe Day
showOrdinalDate :: Day -> String
isLeapYear :: Integer -> Bool
mondayStartWeek :: Day -> (Int, Int)
sundayStartWeek :: Day -> (Int, Int)
fromMondayStartWeek :: Integer -> Int -> Int -> Day
fromMondayStartWeekValid :: Integer -> Int -> Int -> Maybe Day
fromSundayStartWeek :: Integer -> Int -> Int -> Day
fromSundayStartWeekValid :: Integer -> Int -> Int -> Maybe Day

module Data.Time.Calendar.MonthDay.Compat
monthAndDayToDayOfYear :: Bool -> Int -> Int -> Int
monthAndDayToDayOfYearValid :: Bool -> Int -> Int -> Maybe Int
dayOfYearToMonthAndDay :: Bool -> Int -> (Int, Int)
monthLength :: Bool -> Int -> Int

module Data.Time.Calendar.Easter.Compat
sundayAfter :: Day -> Day
orthodoxPaschalMoon :: Integer -> Day
orthodoxEaster :: Integer -> Day
gregorianPaschalMoon :: Integer -> Day
gregorianEaster :: Integer -> Day

module Data.Time.Calendar.Compat
newtype Day
ModifiedJulianDay :: Integer -> Day
[toModifiedJulianDay] :: Day -> Integer
addDays :: Integer -> Day -> Day
diffDays :: Day -> Day -> Integer
data CalendarDiffDays
CalendarDiffDays :: Integer -> Integer -> CalendarDiffDays
[cdMonths] :: CalendarDiffDays -> Integer
[cdDays] :: CalendarDiffDays -> Integer
calendarDay :: CalendarDiffDays
calendarWeek :: CalendarDiffDays
calendarMonth :: CalendarDiffDays
calendarYear :: CalendarDiffDays

-- | Scale by a factor. Note that <tt>scaleCalendarDiffDays (-1)</tt> will
--   not perfectly invert a duration, due to variable month lengths.
scaleCalendarDiffDays :: Integer -> CalendarDiffDays -> CalendarDiffDays
toGregorian :: Day -> (Integer, Int, Int)
fromGregorian :: Integer -> Int -> Int -> Day
fromGregorianValid :: Integer -> Int -> Int -> Maybe Day
showGregorian :: Day -> String
gregorianMonthLength :: Integer -> Int -> Int
addGregorianMonthsClip :: Integer -> Day -> Day
addGregorianMonthsRollOver :: Integer -> Day -> Day
addGregorianYearsClip :: Integer -> Day -> Day
addGregorianYearsRollOver :: Integer -> Day -> Day

-- | Add months (clipped to last day), then add days
addGregorianDurationClip :: CalendarDiffDays -> Day -> Day

-- | Add months (rolling over to next month), then add days
addGregorianDurationRollOver :: CalendarDiffDays -> Day -> Day

-- | Calendrical difference, with as many whole months as possible
diffGregorianDurationClip :: Day -> Day -> CalendarDiffDays

-- | Calendrical difference, with as many whole months as possible. Same as
--   <a>diffGregorianDurationClip</a> for positive durations.
diffGregorianDurationRollOver :: Day -> Day -> CalendarDiffDays
isLeapYear :: Integer -> Bool
data DayOfWeek
Monday :: DayOfWeek
Tuesday :: DayOfWeek
Wednesday :: DayOfWeek
Thursday :: DayOfWeek
Friday :: DayOfWeek
Saturday :: DayOfWeek
Sunday :: DayOfWeek
dayOfWeek :: Day -> DayOfWeek
instance GHC.Read.Read Data.Time.Calendar.Compat.DayOfWeek
instance GHC.Show.Show Data.Time.Calendar.Compat.DayOfWeek
instance GHC.Classes.Eq Data.Time.Calendar.Compat.DayOfWeek
instance Data.Data.Data Data.Time.Calendar.Compat.CalendarDiffDays
instance GHC.Classes.Eq Data.Time.Calendar.Compat.CalendarDiffDays
instance GHC.Enum.Enum Data.Time.Calendar.Compat.DayOfWeek
instance Data.Time.Format.FormatTime Data.Time.Calendar.Compat.DayOfWeek
instance GHC.Base.Semigroup Data.Time.Calendar.Compat.CalendarDiffDays
instance GHC.Base.Monoid Data.Time.Calendar.Compat.CalendarDiffDays
instance GHC.Show.Show Data.Time.Calendar.Compat.CalendarDiffDays

module Data.Time.LocalTime.Compat
data TimeZone
TimeZone :: Int -> Bool -> String -> TimeZone
[timeZoneMinutes] :: TimeZone -> Int
[timeZoneSummerOnly] :: TimeZone -> Bool
[timeZoneName] :: TimeZone -> String
timeZoneOffsetString :: TimeZone -> String
timeZoneOffsetString' :: Maybe Char -> TimeZone -> String
minutesToTimeZone :: Int -> TimeZone
hoursToTimeZone :: Int -> TimeZone
utc :: TimeZone
getTimeZone :: UTCTime -> IO TimeZone
getCurrentTimeZone :: IO TimeZone
data TimeOfDay
TimeOfDay :: Int -> Int -> Pico -> TimeOfDay
[todHour] :: TimeOfDay -> Int
[todMin] :: TimeOfDay -> Int
[todSec] :: TimeOfDay -> Pico
midnight :: TimeOfDay
midday :: TimeOfDay
makeTimeOfDayValid :: Int -> Int -> Pico -> Maybe TimeOfDay

-- | Convert a period of time into a count of days and a time of day since
--   midnight. The time of day will never have a leap second.
timeToDaysAndTimeOfDay :: NominalDiffTime -> (Integer, TimeOfDay)

-- | Convert a count of days and a time of day since midnight into a period
--   of time.
daysAndTimeOfDayToTime :: Integer -> TimeOfDay -> NominalDiffTime
utcToLocalTimeOfDay :: TimeZone -> TimeOfDay -> (Integer, TimeOfDay)
localToUTCTimeOfDay :: TimeZone -> TimeOfDay -> (Integer, TimeOfDay)
timeToTimeOfDay :: DiffTime -> TimeOfDay
timeOfDayToTime :: TimeOfDay -> DiffTime
dayFractionToTimeOfDay :: Rational -> TimeOfDay
timeOfDayToDayFraction :: TimeOfDay -> Rational
data CalendarDiffTime
CalendarDiffTime :: Integer -> NominalDiffTime -> CalendarDiffTime
[ctMonths] :: CalendarDiffTime -> Integer
[ctTime] :: CalendarDiffTime -> NominalDiffTime
calendarTimeDays :: CalendarDiffDays -> CalendarDiffTime
calendarTimeTime :: NominalDiffTime -> CalendarDiffTime

-- | Scale by a factor. Note that <tt>scaleCalendarDiffTime (-1)</tt> will
--   not perfectly invert a duration, due to variable month lengths.
scaleCalendarDiffTime :: Integer -> CalendarDiffTime -> CalendarDiffTime
data LocalTime
LocalTime :: Day -> TimeOfDay -> LocalTime
[localDay] :: LocalTime -> Day
[localTimeOfDay] :: LocalTime -> TimeOfDay

-- | addLocalTime a b = a + b
addLocalTime :: NominalDiffTime -> LocalTime -> LocalTime

-- | diffLocalTime a b = a - b
diffLocalTime :: LocalTime -> LocalTime -> NominalDiffTime
utcToLocalTime :: TimeZone -> UTCTime -> LocalTime
localTimeToUTC :: TimeZone -> LocalTime -> UTCTime
ut1ToLocalTime :: Rational -> UniversalTime -> LocalTime
localTimeToUT1 :: Rational -> LocalTime -> UniversalTime
data ZonedTime
ZonedTime :: LocalTime -> TimeZone -> ZonedTime
[zonedTimeToLocalTime] :: ZonedTime -> LocalTime
[zonedTimeZone] :: ZonedTime -> TimeZone
utcToZonedTime :: TimeZone -> UTCTime -> ZonedTime
zonedTimeToUTC :: ZonedTime -> UTCTime
getZonedTime :: IO ZonedTime
utcToLocalZonedTime :: UTCTime -> IO ZonedTime
instance Data.Data.Data Data.Time.LocalTime.Compat.CalendarDiffTime
instance GHC.Classes.Eq Data.Time.LocalTime.Compat.CalendarDiffTime
instance GHC.Base.Semigroup Data.Time.LocalTime.Compat.CalendarDiffTime
instance GHC.Base.Monoid Data.Time.LocalTime.Compat.CalendarDiffTime
instance GHC.Show.Show Data.Time.LocalTime.Compat.CalendarDiffTime

module Data.Time.Format.ISO8601.Compat

-- | A text format for a type
data Format t

-- | Show a value in the format, if representable
formatShowM :: Format t -> t -> Maybe String

-- | Show a value in the format, or error if unrepresentable
formatShow :: Format t -> t -> String

-- | Read a value in the format
formatReadP :: Format t -> ReadP t

-- | Parse a value in the format
formatParseM :: MonadFail m => Format t -> String -> m t
class ISO8601 t

-- | The most commonly used ISO 8601 format for this type.
iso8601Format :: ISO8601 t => Format t

-- | Show in the most commonly used ISO 8601 format.
iso8601Show :: ISO8601 t => t -> String

-- | Parse the most commonly used ISO 8601 format.
iso8601ParseM :: (MonadFail m, ISO8601 t) => String -> m t
data FormatExtension

-- | ISO 8601:2004(E) sec. 2.3.4. Use hyphens and colons.
ExtendedFormat :: FormatExtension

-- | ISO 8601:2004(E) sec. 2.3.3. Omit hyphens and colons. "The basic
--   format should be avoided in plain text."
BasicFormat :: FormatExtension

-- | Read a value in either extended or basic format
formatReadPExtension :: (FormatExtension -> Format t) -> ReadP t

-- | Parse a value in either extended or basic format
parseFormatExtension :: MonadFail m => (FormatExtension -> Format t) -> String -> m t

-- | ISO 8601:2004(E) sec. 4.1.2.2
calendarFormat :: FormatExtension -> Format Day

-- | ISO 8601:2004(E) sec. 4.1.2.3(a)
yearMonthFormat :: Format (Integer, Int)

-- | ISO 8601:2004(E) sec. 4.1.2.3(b)
yearFormat :: Format Integer

-- | ISO 8601:2004(E) sec. 4.1.2.3(c)
centuryFormat :: Format Integer

-- | ISO 8601:2004(E) sec. 4.1.2.4(a)
expandedCalendarFormat :: Int -> FormatExtension -> Format Day

-- | ISO 8601:2004(E) sec. 4.1.2.4(b)
expandedYearMonthFormat :: Int -> Format (Integer, Int)

-- | ISO 8601:2004(E) sec. 4.1.2.4(c)
expandedYearFormat :: Int -> Format Integer

-- | ISO 8601:2004(E) sec. 4.1.2.4(d)
expandedCenturyFormat :: Int -> Format Integer

-- | ISO 8601:2004(E) sec. 4.1.3.2
ordinalDateFormat :: FormatExtension -> Format Day

-- | ISO 8601:2004(E) sec. 4.1.3.3
expandedOrdinalDateFormat :: Int -> FormatExtension -> Format Day

-- | ISO 8601:2004(E) sec. 4.1.4.2
weekDateFormat :: FormatExtension -> Format Day

-- | ISO 8601:2004(E) sec. 4.1.4.3
yearWeekFormat :: FormatExtension -> Format (Integer, Int)

-- | ISO 8601:2004(E) sec. 4.1.4.2
expandedWeekDateFormat :: Int -> FormatExtension -> Format Day

-- | ISO 8601:2004(E) sec. 4.1.4.3
expandedYearWeekFormat :: Int -> FormatExtension -> Format (Integer, Int)

-- | ISO 8601:2004(E) sec. 4.2.2.2, 4.2.2.4(a)
timeOfDayFormat :: FormatExtension -> Format TimeOfDay

-- | ISO 8601:2004(E) sec. 4.2.2.3(a), 4.2.2.4(b)
hourMinuteFormat :: FormatExtension -> Format TimeOfDay

-- | ISO 8601:2004(E) sec. 4.2.2.3(b), 4.2.2.4(c)
hourFormat :: Format TimeOfDay

-- | ISO 8601:2004(E) sec. 4.2.2.5
withTimeDesignator :: Format t -> Format t

-- | ISO 8601:2004(E) sec. 4.2.4
withUTCDesignator :: Format t -> Format t

-- | ISO 8601:2004(E) sec. 4.2.5.1
timeOffsetFormat :: FormatExtension -> Format TimeZone

-- | ISO 8601:2004(E) sec. 4.2.5.2
timeOfDayAndOffsetFormat :: FormatExtension -> Format (TimeOfDay, TimeZone)

-- | ISO 8601:2004(E) sec. 4.3.2
localTimeFormat :: Format Day -> Format TimeOfDay -> Format LocalTime

-- | ISO 8601:2004(E) sec. 4.3.2
zonedTimeFormat :: Format Day -> Format TimeOfDay -> FormatExtension -> Format ZonedTime

-- | ISO 8601:2004(E) sec. 4.3.2
utcTimeFormat :: Format Day -> Format TimeOfDay -> Format UTCTime

-- | ISO 8601:2004(E) sec. 4.3.3
dayAndTimeFormat :: Format Day -> Format time -> Format (Day, time)

-- | ISO 8601:2004(E) sec. 4.3.3
timeAndOffsetFormat :: Format t -> FormatExtension -> Format (t, TimeZone)

-- | ISO 8601:2004(E) sec. 4.4.3.2
durationDaysFormat :: Format CalendarDiffDays

-- | ISO 8601:2004(E) sec. 4.4.3.2
durationTimeFormat :: Format CalendarDiffTime

-- | ISO 8601:2004(E) sec. 4.4.3.3
alternativeDurationDaysFormat :: FormatExtension -> Format CalendarDiffDays

-- | ISO 8601:2004(E) sec. 4.4.3.3
alternativeDurationTimeFormat :: FormatExtension -> Format CalendarDiffTime

-- | ISO 8601:2004(E) sec. 4.4.4.1
intervalFormat :: Format a -> Format b -> Format (a, b)

-- | ISO 8601:2004(E) sec. 4.5
recurringIntervalFormat :: Format a -> Format b -> Format (Int, a, b)
instance Data.Time.Format.ISO8601.Compat.ISO8601 Data.Time.Calendar.Days.Day
instance Data.Time.Format.ISO8601.Compat.ISO8601 Data.Time.LocalTime.Internal.TimeOfDay.TimeOfDay
instance Data.Time.Format.ISO8601.Compat.ISO8601 Data.Time.LocalTime.Internal.TimeZone.TimeZone
instance Data.Time.Format.ISO8601.Compat.ISO8601 Data.Time.LocalTime.Internal.LocalTime.LocalTime
instance Data.Time.Format.ISO8601.Compat.ISO8601 Data.Time.LocalTime.Internal.ZonedTime.ZonedTime
instance Data.Time.Format.ISO8601.Compat.ISO8601 Data.Time.Clock.Internal.UTCTime.UTCTime
instance Data.Time.Format.ISO8601.Compat.ISO8601 Data.Time.Calendar.Compat.CalendarDiffDays
instance Data.Time.Format.ISO8601.Compat.ISO8601 Data.Time.LocalTime.Compat.CalendarDiffTime
instance Data.Fixed.HasResolution Data.Time.Format.ISO8601.Compat.E16
instance Data.Fixed.HasResolution Data.Time.Format.ISO8601.Compat.E14

module Data.Time.Compat

module Data.Time.Clock.TAI.Compat
data AbsoluteTime
taiEpoch :: AbsoluteTime
addAbsoluteTime :: DiffTime -> AbsoluteTime -> AbsoluteTime
diffAbsoluteTime :: AbsoluteTime -> AbsoluteTime -> DiffTime
taiNominalDayStart :: Day -> AbsoluteTime
type LeapSecondMap = Day -> Maybe Int
utcDayLength :: LeapSecondMap -> Day -> Maybe DiffTime
utcToTAITime :: LeapSecondMap -> UTCTime -> Maybe AbsoluteTime
taiToUTCTime :: LeapSecondMap -> AbsoluteTime -> Maybe UTCTime
taiClock :: Maybe (DiffTime, IO AbsoluteTime)

module Data.Time.Calendar.Julian.Compat
toJulianYearAndDay :: Day -> (Integer, Int)
fromJulianYearAndDay :: Integer -> Int -> Day
fromJulianYearAndDayValid :: Integer -> Int -> Maybe Day
showJulianYearAndDay :: Day -> String
isJulianLeapYear :: Integer -> Bool
toJulian :: Day -> (Integer, Int, Int)
fromJulian :: Integer -> Int -> Int -> Day
fromJulianValid :: Integer -> Int -> Int -> Maybe Day
showJulian :: Day -> String
julianMonthLength :: Integer -> Int -> Int
addJulianMonthsClip :: Integer -> Day -> Day
addJulianMonthsRollOver :: Integer -> Day -> Day
addJulianYearsClip :: Integer -> Day -> Day
addJulianYearsRollOver :: Integer -> Day -> Day

-- | Add months (clipped to last day), then add days
addJulianDurationClip :: CalendarDiffDays -> Day -> Day

-- | Add months (rolling over to next month), then add days
addJulianDurationRollOver :: CalendarDiffDays -> Day -> Day

-- | Calendrical difference, with as many whole months as possible
diffJulianDurationClip :: Day -> Day -> CalendarDiffDays

-- | Calendrical difference, with as many whole months as possible. Same as
--   <a>diffJulianDurationClip</a> for positive durations.
diffJulianDurationRollOver :: Day -> Day -> CalendarDiffDays
