fakedata-0.8.0: Library for producing fake data

Safe HaskellNone
LanguageHaskell2010

Faker.DateTime

Description

Since: 0.2.0

Synopsis

Documentation

utc :: Fake UTCTime Source #

Fake UTCTime between 17-11-1858 and the current time. Note that this function is not deterministic as the current time is not constant. If you want deterministic output, use utcBetween.

day :: Fake Day Source #

Fake Day between 17-11-1858 and the current day. Note that this function is not deterministic as the current time is not constant. If you want deterministic output, use dayBetween.

utcBetween :: UTCTime -> UTCTime -> Fake UTCTime Source #

Generates a random UTCTime in the range [from, to].

dayBetween :: Day -> Day -> Fake Day Source #

Generates a random Day in the range [from, to].

dayBetweenYears :: Integer -> Integer -> Fake Day Source #

Generates a random Day in the year range [from, to].

timeBetweenHours :: Int -> Int -> Fake DiffTime Source #

Generates a random DiffTime between hour range [from, to].

utcBetweenYears :: Integer -> Integer -> Fake UTCTime Source #

Generate a random UTCTime between year range [from, to].